mirror of
https://github.com/MarshalX/telegram-crawler.git
synced 2024-12-29 15:59:13 +01:00
Update content of files
This commit is contained in:
parent
e1647a797b
commit
95584142be
4 changed files with 314 additions and 78 deletions
|
@ -63,7 +63,7 @@
|
||||||
<li><a href="#attachment-menu">Attachment Menu</a></li>
|
<li><a href="#attachment-menu">Attachment Menu</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#payments"><strong>Integration</strong></a><ul>
|
<li><a href="#integration"><strong>Integration</strong></a><ul>
|
||||||
<li><a href="#web-apps">Web Apps</a></li>
|
<li><a href="#web-apps">Web Apps</a></li>
|
||||||
<li><a href="#payments">Payments</a></li>
|
<li><a href="#payments">Payments</a></li>
|
||||||
<li><a href="#web-login">Web Login</a></li>
|
<li><a href="#web-login">Web Login</a></li>
|
||||||
|
@ -88,7 +88,7 @@
|
||||||
<li><a href="#keyboards">Keyboards</a> that replace the user's keyboard with predefined answer options.</li>
|
<li><a href="#keyboards">Keyboards</a> that replace the user's keyboard with predefined answer options.</li>
|
||||||
<li><a href="#inline-keyboards">Buttons</a> that are shown next to messages from the bot.</li>
|
<li><a href="#inline-keyboards">Buttons</a> that are shown next to messages from the bot.</li>
|
||||||
</ul>
|
</ul>
|
||||||
<p>For even more flexibility, <a href="#web-apps">Web Apps</a> support 100% custom interfaces with Javascript. </p>
|
<p>For even more flexibility, <a href="#web-apps">Web Apps</a> support 100% custom interfaces with JavaScript. </p>
|
||||||
<div>
|
<div>
|
||||||
<a href="/file/464001858/11318/ahAJjwERIX8.164875/ce1372cbf73e3ea94e" target="_blank"><img src="/file/464001858/11318/ahAJjwERIX8.164875/ce1372cbf73e3ea94e" title="Inputs" class="dev_page_image" width=70% /></a>
|
<a href="/file/464001858/11318/ahAJjwERIX8.164875/ce1372cbf73e3ea94e" target="_blank"><img src="/file/464001858/11318/ahAJjwERIX8.164875/ce1372cbf73e3ea94e" title="Inputs" class="dev_page_image" width=70% /></a>
|
||||||
</div>
|
</div>
|
||||||
|
@ -121,14 +121,14 @@ width=44% /></a>
|
||||||
<p>We require <strong>all developers</strong> to support several <a href="#global-commands">Global Commands</a> to make sure Telegram bots offer a consistent and user-friendly experience.</p>
|
<p>We require <strong>all developers</strong> to support several <a href="#global-commands">Global Commands</a> to make sure Telegram bots offer a consistent and user-friendly experience.</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
<h5><a class="anchor" name="command-scopes" href="#command-scopes"><i class="anchor-icon"></i></a>Command Scopes</h5>
|
<h5><a class="anchor" name="command-scopes" href="#command-scopes"><i class="anchor-icon"></i></a>Command Scopes</h5>
|
||||||
<p>Your bot is able to <strong>show different commands</strong> to different users and groups – you can control this using <a href="/bots/api#botcommandscope">scopes</a>. For example, your bot could show additional commands to group admins or translate the list based on the user’s <a href="https://core.telegram.org/bots/api#user">language_code</a>.</p>
|
<p>Your bot is able to <strong>show different commands</strong> to different users and groups – you can control this using <a href="/bots/api#botcommandscope">scopes</a>. For example, your bot could show additional commands to group admins or translate the list based on the user’s <a href="/bots/api#user">language_code</a>.</p>
|
||||||
<blockquote>
|
<blockquote>
|
||||||
<p>Keep in mind that Bot API <a href="https://core.telegram.org/bots/api#update">updates</a> <strong>will not contain any information</strong> about the scope of a command sent by the user – in fact, they may contain commands that don’t exist at all in your bot. Your backend should <strong>always</strong> verify that received commands are valid and that the user was authorized to use them regardless of scope.</p>
|
<p>Keep in mind that Bot API <a href="/bots/api#update">updates</a> <strong>will not contain any information</strong> about the scope of a command sent by the user – in fact, they may contain commands that don’t exist at all in your bot. Your backend should <strong>always</strong> verify that received commands are valid and that the user was authorized to use them regardless of scope.</p>
|
||||||
<p>Bots with privacy mode enabled will only receive commands in groups under special conditions, <a href="#privacy-mode">see here</a>.</p>
|
<p>Bots with privacy mode enabled will only receive commands in groups under special conditions, <a href="#privacy-mode">see here</a>.</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
<h4><a class="anchor" name="keyboards" href="#keyboards"><i class="anchor-icon"></i></a>Keyboards</h4>
|
<h4><a class="anchor" name="keyboards" href="#keyboards"><i class="anchor-icon"></i></a>Keyboards</h4>
|
||||||
<p>Bots are able to interpret free text input from users, but offering <strong>specific suggestions</strong> is often more intuitive – this is where <strong>custom keyboards</strong> can be extremely useful.</p>
|
<p>Bots are able to interpret free text input from users, but offering <strong>specific suggestions</strong> is often more intuitive – this is where <strong>custom keyboards</strong> can be extremely useful.</p>
|
||||||
<p>Whenever your bot sends a message, it can <strong>display a special keyboard</strong> with predefined reply options (see <a href="api#replykeyboardmarkup">ReplyKeyboardMarkup</a>). Telegram apps that receive the message will display your keyboard to the user. Using any of the buttons will immediately send the respective text. This way you can drastically <strong>simplify</strong> and <strong>streamline</strong> user interaction with your bot.</p>
|
<p>Whenever your bot sends a message, it can <strong>display a special keyboard</strong> with predefined reply options (see <a href="/bots/api#replykeyboardmarkup">ReplyKeyboardMarkup</a>). Telegram apps that receive the message will display your keyboard to the user. Using any of the buttons will immediately send the respective text. This way you can drastically <strong>simplify</strong> and <strong>streamline</strong> user interaction with your bot.</p>
|
||||||
<div>
|
<div>
|
||||||
<a href="/file/464001950/1191a/2RwpmgU-swU.123554/b50478c124d5914c23" target="_blank"><img src="/file/464001950/1191a/2RwpmgU-swU.123554/b50478c124d5914c23" title="Keyboards" class="dev_page_image" width=44% /></a>
|
<a href="/file/464001950/1191a/2RwpmgU-swU.123554/b50478c124d5914c23" target="_blank"><img src="/file/464001950/1191a/2RwpmgU-swU.123554/b50478c124d5914c23" title="Keyboards" class="dev_page_image" width=44% /></a>
|
||||||
</div>
|
</div>
|
||||||
|
@ -144,7 +144,7 @@ width=44% /></a>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<blockquote>
|
<blockquote>
|
||||||
<p>To provide a <strong>better user experience</strong>, consider <a href="api#editmessagereplymarkup">editing your keyboard</a> when the user toggles a setting button or navigates to a new page – this is both <strong>faster</strong> and <strong>smoother</strong> than sending a whole new message and deleting the previous one.</p>
|
<p>To provide a <strong>better user experience</strong>, consider <a href="/bots/api#editmessagereplymarkup">editing your keyboard</a> when the user toggles a setting button or navigates to a new page – this is both <strong>faster</strong> and <strong>smoother</strong> than sending a whole new message and deleting the previous one.</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
<h4><a class="anchor" name="menu-button" href="#menu-button"><i class="anchor-icon"></i></a>Menu Button</h4>
|
<h4><a class="anchor" name="menu-button" href="#menu-button"><i class="anchor-icon"></i></a>Menu Button</h4>
|
||||||
<p>In all bot chats, a menu button appears near the message field. By default, tapping this button <strong>opens a menu</strong> that can hold some or all of a bot's commands, including a short description for each. Users can then <strong>select a command from the menu</strong> without needing to type it out.</p>
|
<p>In all bot chats, a menu button appears near the message field. By default, tapping this button <strong>opens a menu</strong> that can hold some or all of a bot's commands, including a short description for each. Users can then <strong>select a command from the menu</strong> without needing to type it out.</p>
|
||||||
|
@ -162,7 +162,7 @@ width=44% /></a>
|
||||||
<h4><a class="anchor" name="global-commands" href="#global-commands"><i class="anchor-icon"></i></a>Global Commands</h4>
|
<h4><a class="anchor" name="global-commands" href="#global-commands"><i class="anchor-icon"></i></a>Global Commands</h4>
|
||||||
<p>To make basic interactions more uniform, we ask all developers to support a few <strong>basic commands</strong>. Telegram apps will have interface shortcuts for these commands.</p>
|
<p>To make basic interactions more uniform, we ask all developers to support a few <strong>basic commands</strong>. Telegram apps will have interface shortcuts for these commands.</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li>/start - begins the interaction with the user, like sending an introductory message. This command can also be used to pass additional parameters to the bot (see <a href="deep-linking">Deep Linking</a>).</li>
|
<li>/start - begins the interaction with the user, like sending an introductory message. This command can also be used to pass additional parameters to the bot (see <a href="#deep-linking">Deep Linking</a>).</li>
|
||||||
<li>/help - returns a help message, like a short text about what your bot can do and a list of commands.</li>
|
<li>/help - returns a help message, like a short text about what your bot can do and a list of commands.</li>
|
||||||
<li>/settings - (if applicable) shows the bot's settings for this user and suggests commands to edit them.</li>
|
<li>/settings - (if applicable) shows the bot's settings for this user and suggests commands to edit them.</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
@ -178,7 +178,7 @@ width=44% /></a>
|
||||||
<h4><a class="anchor" name="inline-requests" href="#inline-requests"><i class="anchor-icon"></i></a>Inline Requests</h4>
|
<h4><a class="anchor" name="inline-requests" href="#inline-requests"><i class="anchor-icon"></i></a>Inline Requests</h4>
|
||||||
<p>Users can interact with your bot via <strong>inline queries</strong> straight from the message field <strong>in any chat</strong>. All they need to do is start a message with your bot's <em>@username</em> and enter a keyword.</p>
|
<p>Users can interact with your bot via <strong>inline queries</strong> straight from the message field <strong>in any chat</strong>. All they need to do is start a message with your bot's <em>@username</em> and enter a keyword.</p>
|
||||||
<p>Having received the query, your bot can return some results. As soon as the user selects one, it is sent to the <strong>relevant chat</strong>. This way, people can request and send content from your bot in any of their chats, groups or channels.</p>
|
<p>Having received the query, your bot can return some results. As soon as the user selects one, it is sent to the <strong>relevant chat</strong>. This way, people can request and send content from your bot in any of their chats, groups or channels.</p>
|
||||||
<p>Remember that inline functionality has to be enabled via <a href="https://t.me/botfather">@BotFather</a>, or your bot will not receive inline <a href="api#update">Updates</a>.</p>
|
<p>Remember that inline functionality has to be enabled via <a href="https://t.me/botfather">@BotFather</a>, or your bot will not receive inline <a href="/bots/api#update">Updates</a>.</p>
|
||||||
<div>
|
<div>
|
||||||
<a href="/file/464001466/10e4a/r4FKyQ7gw5g.134366/f2606a53d683374703" target="_blank"><img src="/file/464001466/10e4a/r4FKyQ7gw5g.134366/f2606a53d683374703" title="Inline Mode" class="dev_page_image" width=51%/></a>
|
<a href="/file/464001466/10e4a/r4FKyQ7gw5g.134366/f2606a53d683374703" target="_blank"><img src="/file/464001466/10e4a/r4FKyQ7gw5g.134366/f2606a53d683374703" title="Inline Mode" class="dev_page_image" width=51%/></a>
|
||||||
</div>
|
</div>
|
||||||
|
@ -241,14 +241,14 @@ width=44% /></a>
|
||||||
<p>Here is a <strong>quick start guide</strong> to implement payments:</p>
|
<p>Here is a <strong>quick start guide</strong> to implement payments:</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li>Pick a <a href="payments#supported-payment-providers">provider</a> and obtain the <a href="payments#getting-a-token">proper token</a> as well as a <strong>test token</strong> from the "<strong>Stripe TEST MODE</strong>" provider.</li>
|
<li>Pick a <a href="payments#supported-payment-providers">provider</a> and obtain the <a href="payments#getting-a-token">proper token</a> as well as a <strong>test token</strong> from the "<strong>Stripe TEST MODE</strong>" provider.</li>
|
||||||
<li>Implement payments via the <a href="api#payments">appropriate API methods</a>.</li>
|
<li>Implement payments via the <a href="/bots/api#payments">appropriate API methods</a>.</li>
|
||||||
<li>Test your implementation by using your <strong>test token</strong> along with a <a href="https://stripe.com/docs/testing#cards">test credit card</a>.</li>
|
<li>Test your implementation by using your <strong>test token</strong> along with a <a href="https://stripe.com/docs/testing#cards">test credit card</a>.</li>
|
||||||
</ul>
|
</ul>
|
||||||
<p>Then, to issue an <strong>invoice</strong> and process the order flow:</p>
|
<p>Then, to issue an <strong>invoice</strong> and process the order flow:</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="api#sendinvoice">Send an invoice</a> to the user for the goods or services you are offering.</li>
|
<li><a href="/bots/api#sendinvoice">Send an invoice</a> to the user for the goods or services you are offering.</li>
|
||||||
<li>Validate the order and accept the checkout via <a href="api#answerprecheckoutquery">answerPreCheckoutQuery</a>.</li>
|
<li>Validate the order and accept the checkout via <a href="/bots/api#answerprecheckoutquery">answerPreCheckoutQuery</a>.</li>
|
||||||
<li>Confirm the payment by checking for a <a href="api#successfulpayment">successful payment service message</a>.</li>
|
<li>Confirm the payment by checking for a <a href="/bots/api#successfulpayment">successful payment service message</a>.</li>
|
||||||
<li>Ship the goods or provide the services.</li>
|
<li>Ship the goods or provide the services.</li>
|
||||||
</ul>
|
</ul>
|
||||||
<p>A full and exhaustive guide, including live checklist, parameters and in-depth method descriptions is available <a href="bots/payments">here</a>. We <strong>strongly recommend</strong> that you read the full guide before going live.</p>
|
<p>A full and exhaustive guide, including live checklist, parameters and in-depth method descriptions is available <a href="bots/payments">here</a>. We <strong>strongly recommend</strong> that you read the full guide before going live.</p>
|
||||||
|
@ -278,24 +278,24 @@ width=44% /></a>
|
||||||
<p>Make sure to review our <a href="/widgets/login#checking-authorization">guide</a> on authenticating the received data as well as our <a href="https://gist.github.com/anonymous/6516521b1fb3b464534fbc30ea3573c2">sample code</a>.</p>
|
<p>Make sure to review our <a href="/widgets/login#checking-authorization">guide</a> on authenticating the received data as well as our <a href="https://gist.github.com/anonymous/6516521b1fb3b464534fbc30ea3573c2">sample code</a>.</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
<h3><a class="anchor" name="html5-games" href="#html5-games"><i class="anchor-icon"></i></a>HTML5 Games</h3>
|
<h3><a class="anchor" name="html5-games" href="#html5-games"><i class="anchor-icon"></i></a>HTML5 Games</h3>
|
||||||
<p>Bots can serve as <strong>standalone gaming platforms</strong> – with our <a href="api#games">HTML5 Gaming API</a> you can develop multiplayer or single-player games and let your users have fun comparing <strong>ranks</strong>, <strong>scores</strong> and much more.</p>
|
<p>Bots can serve as <strong>standalone gaming platforms</strong> – with our <a href="/bots/api#games">HTML5 Gaming API</a> you can develop multiplayer or single-player games and let your users have fun comparing <strong>ranks</strong>, <strong>scores</strong> and much more.</p>
|
||||||
<p>To get started, follow these simple steps:</p>
|
<p>To get started, follow these simple steps:</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li>Send the <code>/newgame</code> command to <a href="https://t.me/botfather">@BotFather</a></li>
|
<li>Send the <code>/newgame</code> command to <a href="https://t.me/botfather">@BotFather</a></li>
|
||||||
<li>Provide a <strong>description text</strong>, an <strong>image</strong> or an <strong>optional gif</strong> to showcase its gameplay</li>
|
<li>Provide a <strong>description text</strong>, an <strong>image</strong> or an <strong>optional gif</strong> to showcase its gameplay</li>
|
||||||
<li>Send the game to users via the <a href="api#sendgame">sendGame</a> method or via an <a href="api#inlinequeryresultgame">inline query</a></li>
|
<li>Send the game to users via the <a href="/bots/api#sendgame">sendGame</a> method or via an <a href="/bots/api#inlinequeryresultgame">inline query</a></li>
|
||||||
<li>When someone wants to play, you'll receive the appropriate <code>game_short_name</code> in a <a href="api#callbackquery">CallbackQuery</a></li>
|
<li>When someone wants to play, you'll receive the appropriate <code>game_short_name</code> in a <a href="/bots/api#callbackquery">CallbackQuery</a></li>
|
||||||
<li>To launch the game, provide the <strong>HTML5 Game URL</strong> as the <code>url</code> param of <a href="api#answercallbackquery">answerCallbackQuery</a></li>
|
<li>To launch the game, provide the <strong>HTML5 Game URL</strong> as the <code>url</code> param of <a href="/bots/api#answercallbackquery">answerCallbackQuery</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
<p>Then, to handle <strong>highscores</strong>:</p>
|
<p>Then, to handle <strong>highscores</strong>:</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li>Use <a href="api#setgamescore">setGameScore</a> to post high scores in the chat with the game</li>
|
<li>Use <a href="/bots/api#setgamescore">setGameScore</a> to post high scores in the chat with the game</li>
|
||||||
<li>Use <a href="api#getgamehighscores">getGameHighScores</a> to get in-game high score tables</li>
|
<li>Use <a href="/bots/api#getgamehighscores">getGameHighScores</a> to get in-game high score tables</li>
|
||||||
</ul>
|
</ul>
|
||||||
<p>You can also <strong>embed a share button</strong> within your game, play around with <strong>custom inline buttons</strong>, <strong>URL parameters</strong> and much more. To get a better idea, make sure to check out:</p>
|
<p>You can also <strong>embed a share button</strong> within your game, play around with <strong>custom inline buttons</strong>, <strong>URL parameters</strong> and much more. To get a better idea, make sure to check out:</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="games">HTML5 Games Manual</a></li>
|
<li><a href="/bots/games">HTML5 Games Manual</a></li>
|
||||||
<li><a href="api#games">HTML5 Games Bot API Docs</a></li>
|
<li><a href="/bots/api#games">HTML5 Games Bot API Docs</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
<div>
|
<div>
|
||||||
<a href="/file/464001558/11b92/y_Fu9QQWtj0.141959/dc9db48f66800bf271" target="_blank"><img src="/file/464001558/11b92/y_Fu9QQWtj0.141959/dc9db48f66800bf271" title="Games" width=50% class="dev_page_image" /></a>
|
<a href="/file/464001558/11b92/y_Fu9QQWtj0.141959/dc9db48f66800bf271" target="_blank"><img src="/file/464001558/11b92/y_Fu9QQWtj0.141959/dc9db48f66800bf271" title="Games" width=50% class="dev_page_image" /></a>
|
||||||
|
@ -305,24 +305,24 @@ width=44% /></a>
|
||||||
<p>Check out <a href="https://t.me/gamebot">@GameBot</a> and <a href="https://t.me/gamee">@gamee</a> for examples of what you can do using our Gaming Platform.</p>
|
<p>Check out <a href="https://t.me/gamebot">@GameBot</a> and <a href="https://t.me/gamee">@gamee</a> for examples of what you can do using our Gaming Platform.</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
<h3><a class="anchor" name="stickers" href="#stickers"><i class="anchor-icon"></i></a>Stickers</h3>
|
<h3><a class="anchor" name="stickers" href="#stickers"><i class="anchor-icon"></i></a>Stickers</h3>
|
||||||
<p><a href="https://core.telegram.org/stickers">Stickers</a> are a distinctive Telegram feature used by millions of users to share artwork every day. Stickers take many forms – ranging from <strong>basic images</strong> to smooth <strong>vector animations</strong> and high-detail <strong>.WEBM videos</strong>.</p>
|
<p><a href="/stickers">Stickers</a> are a distinctive Telegram feature used by millions of users to share artwork every day. Stickers take many forms – ranging from <strong>basic images</strong> to smooth <strong>vector animations</strong> and high-detail <strong>.WEBM videos</strong>.</p>
|
||||||
<p>All these formats are supported by our <a href="api#stickers">Bot API</a>, which allows bots to <strong>create</strong>, <strong>edit</strong>, <strong>delete</strong> and <strong>share</strong> new sticker packs on the fly. Telegram's <a href="https://core.telegram.org/import-stickers">Import API</a> lets users <strong>migrate packs</strong> from other platforms and sticker apps.</p>
|
<p>All these formats are supported by our <a href="/bots/api#stickers">Bot API</a>, which allows bots to <strong>create</strong>, <strong>edit</strong>, <strong>delete</strong> and <strong>share</strong> new sticker packs on the fly. Telegram's <a href="/import-stickers">Import API</a> lets users <strong>migrate packs</strong> from other platforms and sticker apps.</p>
|
||||||
<p>To create a <strong>new sticker pack</strong>, follow these simple steps:</p>
|
<p>To create a <strong>new sticker pack</strong>, follow these simple steps:</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li><strong>Upload</strong> a new sticker file via <a href="api#uploadstickerfile">uploadStickerFile</a>. Repeat for all the stickers in the set. You will use the returned <a href="api#file">files</a> in the next step, so keep them around.</li>
|
<li><strong>Upload</strong> a new sticker file via <a href="/bots/api#uploadstickerfile">uploadStickerFile</a>. Repeat for all the stickers in the set. You will use the returned <a href="/bots/api#file">files</a> in the next step, so keep them around.</li>
|
||||||
<li><strong>Create</strong> a new sticker pack via <a href="api#createnewstickerset">createStickerSet</a>. Attach the <a href="api#file">files</a> you collected in <strong>step 1</strong> and remember to only specify <strong>one</strong> of the three avaiable fields – <code>png_sticker</code>, <code>tgs_sticker</code> and <code>webm_sticker</code> – depending on which sticker format you uploaded.</li>
|
<li><strong>Create</strong> a new sticker pack via <a href="/bots/api#createnewstickerset">createStickerSet</a>. Attach the <a href="/bots/api#file">files</a> you collected in <strong>step 1</strong> and remember to only specify <strong>one</strong> of the three avaiable fields – <code>png_sticker</code>, <code>tgs_sticker</code> and <code>webm_sticker</code> – depending on which sticker format you uploaded.</li>
|
||||||
<li><strong>Complete</strong> the pack by adding each remaining sticker in sequence via <a href="api#addstickertoset">addStickerToSet</a>.</li>
|
<li><strong>Complete</strong> the pack by adding each remaining sticker in sequence via <a href="/bots/api#addstickertoset">addStickerToSet</a>.</li>
|
||||||
</ul>
|
</ul>
|
||||||
<blockquote>
|
<blockquote>
|
||||||
<p>Once you're done, don't forget to check out our <a href="api#stickers">remaining sticker methods</a> to find out how to <a href="api#setstickersetthumb">edit</a>, <a href="api#deletestickerfromset">delete</a> and even <a href="api#setstickerpositioninset">reorder</a> your pack.<br>Note that these methods will only work on packs <strong>created by the bot that is calling them</strong>.</p>
|
<p>Once you're done, don't forget to check out our <a href="/bots/api#stickers">remaining sticker methods</a> to find out how to <a href="/bots/api#setstickersetthumb">edit</a>, <a href="/bots/api#deletestickerfromset">delete</a> and even <a href="/bots/api#setstickerpositioninset">reorder</a> your pack.<br>Note that these methods will only work on packs <strong>created by the bot that is calling them</strong>.</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
<h3><a class="anchor" name="language-support" href="#language-support"><i class="anchor-icon"></i></a>Language Support</h3>
|
<h3><a class="anchor" name="language-support" href="#language-support"><i class="anchor-icon"></i></a>Language Support</h3>
|
||||||
<p>Bots can tailor their interfaces to <strong>support multiple languages</strong> – updating inputs and information on the fly. A user’s in-app <a href="/bots/api#user">language_code</a> is included in every relevant <a href="api#Update">update</a> as an <a href="https://en.wikipedia.org/wiki/IETF_language_tag">IETF language tag</a>, allowing bots to adapt accordingly. </p>
|
<p>Bots can tailor their interfaces to <strong>support multiple languages</strong> – updating inputs and information on the fly. A user’s in-app <a href="/bots/api#user">language_code</a> is included in every relevant <a href="/bots/api#Update">update</a> as an <a href="https://en.wikipedia.org/wiki/IETF_language_tag">IETF language tag</a>, allowing bots to adapt accordingly. </p>
|
||||||
<p>We recommend that you follow our guidelines to provide <strong>the best user experience</strong>.</p>
|
<p>We recommend that you follow our guidelines to provide <strong>the best user experience</strong>.</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li>Your interfaces, texts and <a href="api#answerinlinequery">inline results</a> should adapt seamlessly to the <em>language_code</em>, without user intervention.</li>
|
<li>Your interfaces, texts and <a href="/bots/api#answerinlinequery">inline results</a> should adapt seamlessly to the <em>language_code</em>, without user intervention.</li>
|
||||||
<li>Connected <a href="/bots/webapps">WebApps</a> will receive the user's <em>language_code</em> – your HTML page should account for it.</li>
|
<li>Connected <a href="/bots/webapps">WebApps</a> will receive the user's <em>language_code</em> – your HTML page should account for it.</li>
|
||||||
<li><a href="html5-games">HTML5 Games</a> can obtain language information if you specify it as a <a href="games#using-url-parameters">URL parameter</a>. You can generate this parameter from the <em>language_code</em> field in the <a href="api#User">User</a> object served with the initial game <a href="api#callbackquery">CallbackQuery</a>.</li>
|
<li><a href="/bots/html5-games">HTML5 Games</a> can obtain language information if you specify it as a <a href="/bots/games#using-url-parameters">URL parameter</a>. You can generate this parameter from the <em>language_code</em> field in the <a href="/bots/api#User">User</a> object served with the initial game <a href="/bots/api#callbackquery">CallbackQuery</a>.</li>
|
||||||
<li>Command lists can also be specified for individual languages – more on this <a href="#commands">here</a>.</li>
|
<li>Command lists can also be specified for individual languages – more on this <a href="#commands">here</a>.</li>
|
||||||
</ul>
|
</ul>
|
||||||
<div class="blog_video_player_wrap" style="max-width: 400px; margin: 20px auto 20px;">
|
<div class="blog_video_player_wrap" style="max-width: 400px; margin: 20px auto 20px;">
|
||||||
|
@ -341,7 +341,7 @@ width=44% /></a>
|
||||||
<ul>
|
<ul>
|
||||||
<li>Commands explicitly meant for them (e.g., <code>/command@this_bot</code>).</li>
|
<li>Commands explicitly meant for them (e.g., <code>/command@this_bot</code>).</li>
|
||||||
<li>General commands (e.g. <code>/start</code>) if the bot was the last bot to send a message to the group.</li>
|
<li>General commands (e.g. <code>/start</code>) if the bot was the last bot to send a message to the group.</li>
|
||||||
<li>Inline messages sent <a href="api#inline-mode">via</a> the bot.</li>
|
<li>Inline messages sent <a href="/bots/api#inline-mode">via</a> the bot.</li>
|
||||||
<li>Replies to any messages implicitly or explicitly meant for this bot.</li>
|
<li>Replies to any messages implicitly or explicitly meant for this bot.</li>
|
||||||
</ul>
|
</ul>
|
||||||
<p>All bots will also receive, <strong>regardless of privacy mode</strong>:</p>
|
<p>All bots will also receive, <strong>regardless of privacy mode</strong>:</p>
|
||||||
|
@ -378,18 +378,18 @@ width=44% /></a>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
<blockquote>
|
<blockquote>
|
||||||
<p>To provide a good user experience, please respond to all messages that are sent to your bot. Respond to message updates by calling send… methods (e.g. <a href="api#sendmessage">sendMessage</a>).</p>
|
<p>To provide a good user experience, please respond to all messages that are sent to your bot. Respond to message updates by calling send… methods (e.g. <a href="/bots/api#sendmessage">sendMessage</a>).</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
<ul>
|
<ul>
|
||||||
<li><strong>Too few answers to inline queries</strong>. Conversion rate: <strong>{value}</strong> - Your bot is not replying to all inline queries that are being sent to it, calculated in the same way as above. Respond to <code>inline_query</code> updates by calling <a href="api#answerInlineQuery">answerInlineQuery</a>.</li>
|
<li><strong>Too few answers to inline queries</strong>. Conversion rate: <strong>{value}</strong> - Your bot is not replying to all inline queries that are being sent to it, calculated in the same way as above. Respond to <code>inline_query</code> updates by calling <a href="/bots/api#answerInlineQuery">answerInlineQuery</a>.</li>
|
||||||
</ul>
|
</ul>
|
||||||
<ul>
|
<ul>
|
||||||
<li><strong>Too few answers to callback queries</strong>. Conversion rate: <strong>{value}</strong></li>
|
<li><strong>Too few answers to callback queries</strong>. Conversion rate: <strong>{value}</strong></li>
|
||||||
<li><strong>Too few answers to callback game queries</strong>. Conversion rate: <strong>{value}</strong> - Your bot is not replying to all callback queries that are being sent to it (with or without games), calculated in the same way as above. Respond to <code>callback_query</code> updates by calling <a href="api#answerCallbackQuery">answerCallbackQuery</a>.</li>
|
<li><strong>Too few answers to callback game queries</strong>. Conversion rate: <strong>{value}</strong> - Your bot is not replying to all callback queries that are being sent to it (with or without games), calculated in the same way as above. Respond to <code>callback_query</code> updates by calling <a href="/bots/api#answerCallbackQuery">answerCallbackQuery</a>.</li>
|
||||||
</ul>
|
</ul>
|
||||||
<h4><a class="anchor" name="local-bot-api" href="#local-bot-api"><i class="anchor-icon"></i></a>Local Bot API</h4>
|
<h4><a class="anchor" name="local-bot-api" href="#local-bot-api"><i class="anchor-icon"></i></a>Local Bot API</h4>
|
||||||
<p>You can host and work with <strong>your own instance</strong> of our open-source <a href="api">Bot API</a>.<br>The <strong>source code</strong> is available <a href="https://github.com/tdlib/telegram-bot-api">here</a>, along with a quick <a href="https://github.com/tdlib/telegram-bot-api#installation">installation guide</a>.</p>
|
<p>You can host and work with <strong>your own instance</strong> of our open-source <a href="/bots/api">Bot API</a>.<br>The <strong>source code</strong> is available <a href="https://github.com/tdlib/telegram-bot-api">here</a>, along with a quick <a href="https://github.com/tdlib/telegram-bot-api#installation">installation guide</a>.</p>
|
||||||
<p>After <strong>installing the server</strong>, remember to use the <a href="api#logout">logOut</a> method before <strong>redirecting requests</strong> to your new local API URL.</p>
|
<p>After <strong>installing the server</strong>, remember to use the <a href="/bots/api#logout">logOut</a> method before <strong>redirecting requests</strong> to your new local API URL.</p>
|
||||||
<blockquote>
|
<blockquote>
|
||||||
<p>Your local instance runs on port <code>8081</code> by default and will only accept HTTP requests, so a TLS termination proxy has to be used to handle remote HTTPS requests.</p>
|
<p>Your local instance runs on port <code>8081</code> by default and will only accept HTTP requests, so a TLS termination proxy has to be used to handle remote HTTPS requests.</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
|
@ -407,7 +407,7 @@ width=44% /></a>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr>
|
<tr>
|
||||||
<td><a href="api#making-requests">Official</a></td>
|
<td><a href="/bots/api#making-requests">Official</a></td>
|
||||||
<td>20MB</td>
|
<td>20MB</td>
|
||||||
<td>50MB</td>
|
<td>50MB</td>
|
||||||
<td>HTTPS</td>
|
<td>HTTPS</td>
|
||||||
|
@ -415,7 +415,7 @@ width=44% /></a>
|
||||||
<td>1-100</td>
|
<td>1-100</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td><a href="api#using-a-local-bot-api-server">Local</a></td>
|
<td><a href="/bots/api#using-a-local-bot-api-server">Local</a></td>
|
||||||
<td>Unlimited</td>
|
<td>Unlimited</td>
|
||||||
<td>2000MB</td>
|
<td>2000MB</td>
|
||||||
<td>HTTP</td>
|
<td>HTTP</td>
|
||||||
|
@ -499,9 +499,9 @@ width=44% /></a>
|
||||||
<p>Please note that it may take a few minutes for changes to take effect.</p>
|
<p>Please note that it may take a few minutes for changes to take effect.</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
<hr>
|
<hr>
|
||||||
<p>With this information, you are ready to proceed to our <a href="api">Full API Reference for Developers</a>.</p>
|
<p>With this information, you are ready to proceed to our <a href="/bots/api">Full API Reference for Developers</a>.</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li>If you have any questions, check out our <a href="faq">Bot FAQ</a>.</li>
|
<li>If you have any questions, check out our <a href="/bots/faq">Bot FAQ</a>.</li>
|
||||||
<li>If you're experiencing issues with our API, please contact <a href="https://t.me/botsupport">@BotSupport</a> on Telegram.</li>
|
<li>If you're experiencing issues with our API, please contact <a href="https://t.me/botsupport">@BotSupport</a> on Telegram.</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
|
118
data/web/blogfork.telegram.org/bots/html5-games.html
Normal file
118
data/web/blogfork.telegram.org/bots/html5-games.html
Normal file
|
@ -0,0 +1,118 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html class="">
|
||||||
|
<head>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<title>Page not found</title>
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<meta property="description" content="">
|
||||||
|
<meta property="og:title" content="Page not found">
|
||||||
|
<meta property="og:image" content="">
|
||||||
|
<meta property="og:description" content="">
|
||||||
|
<link rel="icon" type="image/svg+xml" href="/img/website_icon.svg?4">
|
||||||
|
<link rel="apple-touch-icon" sizes="180x180" href="/img/apple-touch-icon.png">
|
||||||
|
<link rel="icon" type="image/png" sizes="32x32" href="/img/favicon-32x32.png">
|
||||||
|
<link rel="icon" type="image/png" sizes="16x16" href="/img/favicon-16x16.png">
|
||||||
|
<link rel="alternate icon" href="/img/favicon.ico" type="image/x-icon" />
|
||||||
|
<link href="/css/bootstrap.min.css?3" rel="stylesheet">
|
||||||
|
|
||||||
|
<link href="/css/telegram.css?232" rel="stylesheet" media="screen">
|
||||||
|
<style>
|
||||||
|
</style>
|
||||||
|
</head>
|
||||||
|
<body class="preload">
|
||||||
|
<div class="dev_page_wrap">
|
||||||
|
<div class="dev_page_head navbar navbar-static-top navbar-tg">
|
||||||
|
<div class="navbar-inner">
|
||||||
|
<div class="container clearfix">
|
||||||
|
<ul class="nav navbar-nav navbar-right hidden-xs"><li class="navbar-twitter"><a href="https://twitter.com/telegram" target="_blank" data-track="Follow/Twitter" onclick="trackDlClick(this, event)"><i class="icon icon-twitter"></i><span> Twitter</span></a></li></ul>
|
||||||
|
<ul class="nav navbar-nav">
|
||||||
|
<li><a href="//telegram.org/">Home</a></li>
|
||||||
|
<li class="hidden-xs"><a href="//telegram.org/faq">FAQ</a></li>
|
||||||
|
<li class="hidden-xs"><a href="//telegram.org/apps">Apps</a></li>
|
||||||
|
<li class=""><a href="/api">API</a></li>
|
||||||
|
<li class=""><a href="/mtproto">Protocol</a></li>
|
||||||
|
<li class=""><a href="/schema">Schema</a></li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="container clearfix">
|
||||||
|
<div class="dev_page">
|
||||||
|
<div id="dev_page_content_wrap" class=" ">
|
||||||
|
<div class="dev_page_bread_crumbs"></div>
|
||||||
|
<h1 id="dev_page_title">Page not found</h1>
|
||||||
|
|
||||||
|
<div id="dev_page_content">The page has not been saved</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="footer_wrap">
|
||||||
|
<div class="footer_columns_wrap footer_desktop">
|
||||||
|
<div class="footer_column footer_column_telegram">
|
||||||
|
<h5>Telegram</h5>
|
||||||
|
<div class="footer_telegram_description"></div>
|
||||||
|
Telegram is a cloud-based mobile and desktop messaging app with a focus on security and speed.
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="footer_column">
|
||||||
|
<h5><a href="//telegram.org/faq">About</a></h5>
|
||||||
|
<ul>
|
||||||
|
<li><a href="//telegram.org/faq">FAQ</a></li>
|
||||||
|
<li><a href="//telegram.org/privacy">Privacy</a></li>
|
||||||
|
<li><a href="//telegram.org/press">Press</a></li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
<div class="footer_column">
|
||||||
|
<h5><a href="//telegram.org/apps#mobile-apps">Mobile Apps</a></h5>
|
||||||
|
<ul>
|
||||||
|
<li><a href="//telegram.org/dl/ios">iPhone/iPad</a></li>
|
||||||
|
<li><a href="//telegram.org/android">Android</a></li>
|
||||||
|
<li><a href="//telegram.org/dl/web">Mobile Web</a></li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
<div class="footer_column">
|
||||||
|
<h5><a href="//telegram.org/apps#desktop-apps">Desktop Apps</a></h5>
|
||||||
|
<ul>
|
||||||
|
<li><a href="//desktop.telegram.org/">PC/Mac/Linux</a></li>
|
||||||
|
<li><a href="//macos.telegram.org/">macOS</a></li>
|
||||||
|
<li><a href="//telegram.org/dl/web">Web-browser</a></li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
<div class="footer_column footer_column_platform">
|
||||||
|
<h5><a href="/">Platform</a></h5>
|
||||||
|
<ul>
|
||||||
|
<li><a href="/api">API</a></li>
|
||||||
|
<li><a href="//translations.telegram.org/">Translations</a></li>
|
||||||
|
<li><a href="//instantview.telegram.org/">Instant View</a></li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="footer_columns_wrap footer_mobile">
|
||||||
|
<div class="footer_column">
|
||||||
|
<h5><a href="//telegram.org/faq">About</a></h5>
|
||||||
|
</div>
|
||||||
|
<div class="footer_column">
|
||||||
|
<h5><a href="//telegram.org/blog">Blog</a></h5>
|
||||||
|
</div>
|
||||||
|
<div class="footer_column">
|
||||||
|
<h5><a href="//telegram.org/apps">Apps</a></h5>
|
||||||
|
</div>
|
||||||
|
<div class="footer_column">
|
||||||
|
<h5><a href="/">Platform</a></h5>
|
||||||
|
</div>
|
||||||
|
<div class="footer_column">
|
||||||
|
<h5><a href="https://twitter.com/telegram" target="_blank" data-track="Follow/Twitter" onclick="trackDlClick(this, event)">Twitter</a></h5>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<script src="/js/main.js?46"></script>
|
||||||
|
|
||||||
|
<script>backToTopInit("Go up");
|
||||||
|
removePreloadInit();
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
|
|
|
@ -63,7 +63,7 @@
|
||||||
<li><a href="#attachment-menu">Attachment Menu</a></li>
|
<li><a href="#attachment-menu">Attachment Menu</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</li>
|
</li>
|
||||||
<li><a href="#payments"><strong>Integration</strong></a><ul>
|
<li><a href="#integration"><strong>Integration</strong></a><ul>
|
||||||
<li><a href="#web-apps">Web Apps</a></li>
|
<li><a href="#web-apps">Web Apps</a></li>
|
||||||
<li><a href="#payments">Payments</a></li>
|
<li><a href="#payments">Payments</a></li>
|
||||||
<li><a href="#web-login">Web Login</a></li>
|
<li><a href="#web-login">Web Login</a></li>
|
||||||
|
@ -88,7 +88,7 @@
|
||||||
<li><a href="#keyboards">Keyboards</a> that replace the user's keyboard with predefined answer options.</li>
|
<li><a href="#keyboards">Keyboards</a> that replace the user's keyboard with predefined answer options.</li>
|
||||||
<li><a href="#inline-keyboards">Buttons</a> that are shown next to messages from the bot.</li>
|
<li><a href="#inline-keyboards">Buttons</a> that are shown next to messages from the bot.</li>
|
||||||
</ul>
|
</ul>
|
||||||
<p>For even more flexibility, <a href="#web-apps">Web Apps</a> support 100% custom interfaces with Javascript. </p>
|
<p>For even more flexibility, <a href="#web-apps">Web Apps</a> support 100% custom interfaces with JavaScript. </p>
|
||||||
<div>
|
<div>
|
||||||
<a href="/file/464001858/11318/ahAJjwERIX8.164875/ce1372cbf73e3ea94e" target="_blank"><img src="/file/464001858/11318/ahAJjwERIX8.164875/ce1372cbf73e3ea94e" title="Inputs" class="dev_page_image" width=70% /></a>
|
<a href="/file/464001858/11318/ahAJjwERIX8.164875/ce1372cbf73e3ea94e" target="_blank"><img src="/file/464001858/11318/ahAJjwERIX8.164875/ce1372cbf73e3ea94e" title="Inputs" class="dev_page_image" width=70% /></a>
|
||||||
</div>
|
</div>
|
||||||
|
@ -121,14 +121,14 @@ width=44% /></a>
|
||||||
<p>We require <strong>all developers</strong> to support several <a href="#global-commands">Global Commands</a> to make sure Telegram bots offer a consistent and user-friendly experience.</p>
|
<p>We require <strong>all developers</strong> to support several <a href="#global-commands">Global Commands</a> to make sure Telegram bots offer a consistent and user-friendly experience.</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
<h5><a class="anchor" name="command-scopes" href="#command-scopes"><i class="anchor-icon"></i></a>Command Scopes</h5>
|
<h5><a class="anchor" name="command-scopes" href="#command-scopes"><i class="anchor-icon"></i></a>Command Scopes</h5>
|
||||||
<p>Your bot is able to <strong>show different commands</strong> to different users and groups – you can control this using <a href="/bots/api#botcommandscope">scopes</a>. For example, your bot could show additional commands to group admins or translate the list based on the user’s <a href="https://core.telegram.org/bots/api#user">language_code</a>.</p>
|
<p>Your bot is able to <strong>show different commands</strong> to different users and groups – you can control this using <a href="/bots/api#botcommandscope">scopes</a>. For example, your bot could show additional commands to group admins or translate the list based on the user’s <a href="/bots/api#user">language_code</a>.</p>
|
||||||
<blockquote>
|
<blockquote>
|
||||||
<p>Keep in mind that Bot API <a href="https://core.telegram.org/bots/api#update">updates</a> <strong>will not contain any information</strong> about the scope of a command sent by the user – in fact, they may contain commands that don’t exist at all in your bot. Your backend should <strong>always</strong> verify that received commands are valid and that the user was authorized to use them regardless of scope.</p>
|
<p>Keep in mind that Bot API <a href="/bots/api#update">updates</a> <strong>will not contain any information</strong> about the scope of a command sent by the user – in fact, they may contain commands that don’t exist at all in your bot. Your backend should <strong>always</strong> verify that received commands are valid and that the user was authorized to use them regardless of scope.</p>
|
||||||
<p>Bots with privacy mode enabled will only receive commands in groups under special conditions, <a href="#privacy-mode">see here</a>.</p>
|
<p>Bots with privacy mode enabled will only receive commands in groups under special conditions, <a href="#privacy-mode">see here</a>.</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
<h4><a class="anchor" name="keyboards" href="#keyboards"><i class="anchor-icon"></i></a>Keyboards</h4>
|
<h4><a class="anchor" name="keyboards" href="#keyboards"><i class="anchor-icon"></i></a>Keyboards</h4>
|
||||||
<p>Bots are able to interpret free text input from users, but offering <strong>specific suggestions</strong> is often more intuitive – this is where <strong>custom keyboards</strong> can be extremely useful.</p>
|
<p>Bots are able to interpret free text input from users, but offering <strong>specific suggestions</strong> is often more intuitive – this is where <strong>custom keyboards</strong> can be extremely useful.</p>
|
||||||
<p>Whenever your bot sends a message, it can <strong>display a special keyboard</strong> with predefined reply options (see <a href="api#replykeyboardmarkup">ReplyKeyboardMarkup</a>). Telegram apps that receive the message will display your keyboard to the user. Using any of the buttons will immediately send the respective text. This way you can drastically <strong>simplify</strong> and <strong>streamline</strong> user interaction with your bot.</p>
|
<p>Whenever your bot sends a message, it can <strong>display a special keyboard</strong> with predefined reply options (see <a href="/bots/api#replykeyboardmarkup">ReplyKeyboardMarkup</a>). Telegram apps that receive the message will display your keyboard to the user. Using any of the buttons will immediately send the respective text. This way you can drastically <strong>simplify</strong> and <strong>streamline</strong> user interaction with your bot.</p>
|
||||||
<div>
|
<div>
|
||||||
<a href="/file/464001950/1191a/2RwpmgU-swU.123554/b50478c124d5914c23" target="_blank"><img src="/file/464001950/1191a/2RwpmgU-swU.123554/b50478c124d5914c23" title="Keyboards" class="dev_page_image" width=44% /></a>
|
<a href="/file/464001950/1191a/2RwpmgU-swU.123554/b50478c124d5914c23" target="_blank"><img src="/file/464001950/1191a/2RwpmgU-swU.123554/b50478c124d5914c23" title="Keyboards" class="dev_page_image" width=44% /></a>
|
||||||
</div>
|
</div>
|
||||||
|
@ -144,7 +144,7 @@ width=44% /></a>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<blockquote>
|
<blockquote>
|
||||||
<p>To provide a <strong>better user experience</strong>, consider <a href="api#editmessagereplymarkup">editing your keyboard</a> when the user toggles a setting button or navigates to a new page – this is both <strong>faster</strong> and <strong>smoother</strong> than sending a whole new message and deleting the previous one.</p>
|
<p>To provide a <strong>better user experience</strong>, consider <a href="/bots/api#editmessagereplymarkup">editing your keyboard</a> when the user toggles a setting button or navigates to a new page – this is both <strong>faster</strong> and <strong>smoother</strong> than sending a whole new message and deleting the previous one.</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
<h4><a class="anchor" name="menu-button" href="#menu-button"><i class="anchor-icon"></i></a>Menu Button</h4>
|
<h4><a class="anchor" name="menu-button" href="#menu-button"><i class="anchor-icon"></i></a>Menu Button</h4>
|
||||||
<p>In all bot chats, a menu button appears near the message field. By default, tapping this button <strong>opens a menu</strong> that can hold some or all of a bot's commands, including a short description for each. Users can then <strong>select a command from the menu</strong> without needing to type it out.</p>
|
<p>In all bot chats, a menu button appears near the message field. By default, tapping this button <strong>opens a menu</strong> that can hold some or all of a bot's commands, including a short description for each. Users can then <strong>select a command from the menu</strong> without needing to type it out.</p>
|
||||||
|
@ -162,7 +162,7 @@ width=44% /></a>
|
||||||
<h4><a class="anchor" name="global-commands" href="#global-commands"><i class="anchor-icon"></i></a>Global Commands</h4>
|
<h4><a class="anchor" name="global-commands" href="#global-commands"><i class="anchor-icon"></i></a>Global Commands</h4>
|
||||||
<p>To make basic interactions more uniform, we ask all developers to support a few <strong>basic commands</strong>. Telegram apps will have interface shortcuts for these commands.</p>
|
<p>To make basic interactions more uniform, we ask all developers to support a few <strong>basic commands</strong>. Telegram apps will have interface shortcuts for these commands.</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li>/start - begins the interaction with the user, like sending an introductory message. This command can also be used to pass additional parameters to the bot (see <a href="deep-linking">Deep Linking</a>).</li>
|
<li>/start - begins the interaction with the user, like sending an introductory message. This command can also be used to pass additional parameters to the bot (see <a href="#deep-linking">Deep Linking</a>).</li>
|
||||||
<li>/help - returns a help message, like a short text about what your bot can do and a list of commands.</li>
|
<li>/help - returns a help message, like a short text about what your bot can do and a list of commands.</li>
|
||||||
<li>/settings - (if applicable) shows the bot's settings for this user and suggests commands to edit them.</li>
|
<li>/settings - (if applicable) shows the bot's settings for this user and suggests commands to edit them.</li>
|
||||||
</ul>
|
</ul>
|
||||||
|
@ -178,7 +178,7 @@ width=44% /></a>
|
||||||
<h4><a class="anchor" name="inline-requests" href="#inline-requests"><i class="anchor-icon"></i></a>Inline Requests</h4>
|
<h4><a class="anchor" name="inline-requests" href="#inline-requests"><i class="anchor-icon"></i></a>Inline Requests</h4>
|
||||||
<p>Users can interact with your bot via <strong>inline queries</strong> straight from the message field <strong>in any chat</strong>. All they need to do is start a message with your bot's <em>@username</em> and enter a keyword.</p>
|
<p>Users can interact with your bot via <strong>inline queries</strong> straight from the message field <strong>in any chat</strong>. All they need to do is start a message with your bot's <em>@username</em> and enter a keyword.</p>
|
||||||
<p>Having received the query, your bot can return some results. As soon as the user selects one, it is sent to the <strong>relevant chat</strong>. This way, people can request and send content from your bot in any of their chats, groups or channels.</p>
|
<p>Having received the query, your bot can return some results. As soon as the user selects one, it is sent to the <strong>relevant chat</strong>. This way, people can request and send content from your bot in any of their chats, groups or channels.</p>
|
||||||
<p>Remember that inline functionality has to be enabled via <a href="https://t.me/botfather">@BotFather</a>, or your bot will not receive inline <a href="api#update">Updates</a>.</p>
|
<p>Remember that inline functionality has to be enabled via <a href="https://t.me/botfather">@BotFather</a>, or your bot will not receive inline <a href="/bots/api#update">Updates</a>.</p>
|
||||||
<div>
|
<div>
|
||||||
<a href="/file/464001466/10e4a/r4FKyQ7gw5g.134366/f2606a53d683374703" target="_blank"><img src="/file/464001466/10e4a/r4FKyQ7gw5g.134366/f2606a53d683374703" title="Inline Mode" class="dev_page_image" width=51%/></a>
|
<a href="/file/464001466/10e4a/r4FKyQ7gw5g.134366/f2606a53d683374703" target="_blank"><img src="/file/464001466/10e4a/r4FKyQ7gw5g.134366/f2606a53d683374703" title="Inline Mode" class="dev_page_image" width=51%/></a>
|
||||||
</div>
|
</div>
|
||||||
|
@ -241,14 +241,14 @@ width=44% /></a>
|
||||||
<p>Here is a <strong>quick start guide</strong> to implement payments:</p>
|
<p>Here is a <strong>quick start guide</strong> to implement payments:</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li>Pick a <a href="payments#supported-payment-providers">provider</a> and obtain the <a href="payments#getting-a-token">proper token</a> as well as a <strong>test token</strong> from the "<strong>Stripe TEST MODE</strong>" provider.</li>
|
<li>Pick a <a href="payments#supported-payment-providers">provider</a> and obtain the <a href="payments#getting-a-token">proper token</a> as well as a <strong>test token</strong> from the "<strong>Stripe TEST MODE</strong>" provider.</li>
|
||||||
<li>Implement payments via the <a href="api#payments">appropriate API methods</a>.</li>
|
<li>Implement payments via the <a href="/bots/api#payments">appropriate API methods</a>.</li>
|
||||||
<li>Test your implementation by using your <strong>test token</strong> along with a <a href="https://stripe.com/docs/testing#cards">test credit card</a>.</li>
|
<li>Test your implementation by using your <strong>test token</strong> along with a <a href="https://stripe.com/docs/testing#cards">test credit card</a>.</li>
|
||||||
</ul>
|
</ul>
|
||||||
<p>Then, to issue an <strong>invoice</strong> and process the order flow:</p>
|
<p>Then, to issue an <strong>invoice</strong> and process the order flow:</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="api#sendinvoice">Send an invoice</a> to the user for the goods or services you are offering.</li>
|
<li><a href="/bots/api#sendinvoice">Send an invoice</a> to the user for the goods or services you are offering.</li>
|
||||||
<li>Validate the order and accept the checkout via <a href="api#answerprecheckoutquery">answerPreCheckoutQuery</a>.</li>
|
<li>Validate the order and accept the checkout via <a href="/bots/api#answerprecheckoutquery">answerPreCheckoutQuery</a>.</li>
|
||||||
<li>Confirm the payment by checking for a <a href="api#successfulpayment">successful payment service message</a>.</li>
|
<li>Confirm the payment by checking for a <a href="/bots/api#successfulpayment">successful payment service message</a>.</li>
|
||||||
<li>Ship the goods or provide the services.</li>
|
<li>Ship the goods or provide the services.</li>
|
||||||
</ul>
|
</ul>
|
||||||
<p>A full and exhaustive guide, including live checklist, parameters and in-depth method descriptions is available <a href="bots/payments">here</a>. We <strong>strongly recommend</strong> that you read the full guide before going live.</p>
|
<p>A full and exhaustive guide, including live checklist, parameters and in-depth method descriptions is available <a href="bots/payments">here</a>. We <strong>strongly recommend</strong> that you read the full guide before going live.</p>
|
||||||
|
@ -278,24 +278,24 @@ width=44% /></a>
|
||||||
<p>Make sure to review our <a href="/widgets/login#checking-authorization">guide</a> on authenticating the received data as well as our <a href="https://gist.github.com/anonymous/6516521b1fb3b464534fbc30ea3573c2">sample code</a>.</p>
|
<p>Make sure to review our <a href="/widgets/login#checking-authorization">guide</a> on authenticating the received data as well as our <a href="https://gist.github.com/anonymous/6516521b1fb3b464534fbc30ea3573c2">sample code</a>.</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
<h3><a class="anchor" name="html5-games" href="#html5-games"><i class="anchor-icon"></i></a>HTML5 Games</h3>
|
<h3><a class="anchor" name="html5-games" href="#html5-games"><i class="anchor-icon"></i></a>HTML5 Games</h3>
|
||||||
<p>Bots can serve as <strong>standalone gaming platforms</strong> – with our <a href="api#games">HTML5 Gaming API</a> you can develop multiplayer or single-player games and let your users have fun comparing <strong>ranks</strong>, <strong>scores</strong> and much more.</p>
|
<p>Bots can serve as <strong>standalone gaming platforms</strong> – with our <a href="/bots/api#games">HTML5 Gaming API</a> you can develop multiplayer or single-player games and let your users have fun comparing <strong>ranks</strong>, <strong>scores</strong> and much more.</p>
|
||||||
<p>To get started, follow these simple steps:</p>
|
<p>To get started, follow these simple steps:</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li>Send the <code>/newgame</code> command to <a href="https://t.me/botfather">@BotFather</a></li>
|
<li>Send the <code>/newgame</code> command to <a href="https://t.me/botfather">@BotFather</a></li>
|
||||||
<li>Provide a <strong>description text</strong>, an <strong>image</strong> or an <strong>optional gif</strong> to showcase its gameplay</li>
|
<li>Provide a <strong>description text</strong>, an <strong>image</strong> or an <strong>optional gif</strong> to showcase its gameplay</li>
|
||||||
<li>Send the game to users via the <a href="api#sendgame">sendGame</a> method or via an <a href="api#inlinequeryresultgame">inline query</a></li>
|
<li>Send the game to users via the <a href="/bots/api#sendgame">sendGame</a> method or via an <a href="/bots/api#inlinequeryresultgame">inline query</a></li>
|
||||||
<li>When someone wants to play, you'll receive the appropriate <code>game_short_name</code> in a <a href="api#callbackquery">CallbackQuery</a></li>
|
<li>When someone wants to play, you'll receive the appropriate <code>game_short_name</code> in a <a href="/bots/api#callbackquery">CallbackQuery</a></li>
|
||||||
<li>To launch the game, provide the <strong>HTML5 Game URL</strong> as the <code>url</code> param of <a href="api#answercallbackquery">answerCallbackQuery</a></li>
|
<li>To launch the game, provide the <strong>HTML5 Game URL</strong> as the <code>url</code> param of <a href="/bots/api#answercallbackquery">answerCallbackQuery</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
<p>Then, to handle <strong>highscores</strong>:</p>
|
<p>Then, to handle <strong>highscores</strong>:</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li>Use <a href="api#setgamescore">setGameScore</a> to post high scores in the chat with the game</li>
|
<li>Use <a href="/bots/api#setgamescore">setGameScore</a> to post high scores in the chat with the game</li>
|
||||||
<li>Use <a href="api#getgamehighscores">getGameHighScores</a> to get in-game high score tables</li>
|
<li>Use <a href="/bots/api#getgamehighscores">getGameHighScores</a> to get in-game high score tables</li>
|
||||||
</ul>
|
</ul>
|
||||||
<p>You can also <strong>embed a share button</strong> within your game, play around with <strong>custom inline buttons</strong>, <strong>URL parameters</strong> and much more. To get a better idea, make sure to check out:</p>
|
<p>You can also <strong>embed a share button</strong> within your game, play around with <strong>custom inline buttons</strong>, <strong>URL parameters</strong> and much more. To get a better idea, make sure to check out:</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="games">HTML5 Games Manual</a></li>
|
<li><a href="/bots/games">HTML5 Games Manual</a></li>
|
||||||
<li><a href="api#games">HTML5 Games Bot API Docs</a></li>
|
<li><a href="/bots/api#games">HTML5 Games Bot API Docs</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
<div>
|
<div>
|
||||||
<a href="/file/464001558/11b92/y_Fu9QQWtj0.141959/dc9db48f66800bf271" target="_blank"><img src="/file/464001558/11b92/y_Fu9QQWtj0.141959/dc9db48f66800bf271" title="Games" width=50% class="dev_page_image" /></a>
|
<a href="/file/464001558/11b92/y_Fu9QQWtj0.141959/dc9db48f66800bf271" target="_blank"><img src="/file/464001558/11b92/y_Fu9QQWtj0.141959/dc9db48f66800bf271" title="Games" width=50% class="dev_page_image" /></a>
|
||||||
|
@ -305,24 +305,24 @@ width=44% /></a>
|
||||||
<p>Check out <a href="https://t.me/gamebot">@GameBot</a> and <a href="https://t.me/gamee">@gamee</a> for examples of what you can do using our Gaming Platform.</p>
|
<p>Check out <a href="https://t.me/gamebot">@GameBot</a> and <a href="https://t.me/gamee">@gamee</a> for examples of what you can do using our Gaming Platform.</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
<h3><a class="anchor" name="stickers" href="#stickers"><i class="anchor-icon"></i></a>Stickers</h3>
|
<h3><a class="anchor" name="stickers" href="#stickers"><i class="anchor-icon"></i></a>Stickers</h3>
|
||||||
<p><a href="https://core.telegram.org/stickers">Stickers</a> are a distinctive Telegram feature used by millions of users to share artwork every day. Stickers take many forms – ranging from <strong>basic images</strong> to smooth <strong>vector animations</strong> and high-detail <strong>.WEBM videos</strong>.</p>
|
<p><a href="/stickers">Stickers</a> are a distinctive Telegram feature used by millions of users to share artwork every day. Stickers take many forms – ranging from <strong>basic images</strong> to smooth <strong>vector animations</strong> and high-detail <strong>.WEBM videos</strong>.</p>
|
||||||
<p>All these formats are supported by our <a href="api#stickers">Bot API</a>, which allows bots to <strong>create</strong>, <strong>edit</strong>, <strong>delete</strong> and <strong>share</strong> new sticker packs on the fly. Telegram's <a href="https://core.telegram.org/import-stickers">Import API</a> lets users <strong>migrate packs</strong> from other platforms and sticker apps.</p>
|
<p>All these formats are supported by our <a href="/bots/api#stickers">Bot API</a>, which allows bots to <strong>create</strong>, <strong>edit</strong>, <strong>delete</strong> and <strong>share</strong> new sticker packs on the fly. Telegram's <a href="/import-stickers">Import API</a> lets users <strong>migrate packs</strong> from other platforms and sticker apps.</p>
|
||||||
<p>To create a <strong>new sticker pack</strong>, follow these simple steps:</p>
|
<p>To create a <strong>new sticker pack</strong>, follow these simple steps:</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li><strong>Upload</strong> a new sticker file via <a href="api#uploadstickerfile">uploadStickerFile</a>. Repeat for all the stickers in the set. You will use the returned <a href="api#file">files</a> in the next step, so keep them around.</li>
|
<li><strong>Upload</strong> a new sticker file via <a href="/bots/api#uploadstickerfile">uploadStickerFile</a>. Repeat for all the stickers in the set. You will use the returned <a href="/bots/api#file">files</a> in the next step, so keep them around.</li>
|
||||||
<li><strong>Create</strong> a new sticker pack via <a href="api#createnewstickerset">createStickerSet</a>. Attach the <a href="api#file">files</a> you collected in <strong>step 1</strong> and remember to only specify <strong>one</strong> of the three avaiable fields – <code>png_sticker</code>, <code>tgs_sticker</code> and <code>webm_sticker</code> – depending on which sticker format you uploaded.</li>
|
<li><strong>Create</strong> a new sticker pack via <a href="/bots/api#createnewstickerset">createStickerSet</a>. Attach the <a href="/bots/api#file">files</a> you collected in <strong>step 1</strong> and remember to only specify <strong>one</strong> of the three avaiable fields – <code>png_sticker</code>, <code>tgs_sticker</code> and <code>webm_sticker</code> – depending on which sticker format you uploaded.</li>
|
||||||
<li><strong>Complete</strong> the pack by adding each remaining sticker in sequence via <a href="api#addstickertoset">addStickerToSet</a>.</li>
|
<li><strong>Complete</strong> the pack by adding each remaining sticker in sequence via <a href="/bots/api#addstickertoset">addStickerToSet</a>.</li>
|
||||||
</ul>
|
</ul>
|
||||||
<blockquote>
|
<blockquote>
|
||||||
<p>Once you're done, don't forget to check out our <a href="api#stickers">remaining sticker methods</a> to find out how to <a href="api#setstickersetthumb">edit</a>, <a href="api#deletestickerfromset">delete</a> and even <a href="api#setstickerpositioninset">reorder</a> your pack.<br>Note that these methods will only work on packs <strong>created by the bot that is calling them</strong>.</p>
|
<p>Once you're done, don't forget to check out our <a href="/bots/api#stickers">remaining sticker methods</a> to find out how to <a href="/bots/api#setstickersetthumb">edit</a>, <a href="/bots/api#deletestickerfromset">delete</a> and even <a href="/bots/api#setstickerpositioninset">reorder</a> your pack.<br>Note that these methods will only work on packs <strong>created by the bot that is calling them</strong>.</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
<h3><a class="anchor" name="language-support" href="#language-support"><i class="anchor-icon"></i></a>Language Support</h3>
|
<h3><a class="anchor" name="language-support" href="#language-support"><i class="anchor-icon"></i></a>Language Support</h3>
|
||||||
<p>Bots can tailor their interfaces to <strong>support multiple languages</strong> – updating inputs and information on the fly. A user’s in-app <a href="/bots/api#user">language_code</a> is included in every relevant <a href="api#Update">update</a> as an <a href="https://en.wikipedia.org/wiki/IETF_language_tag">IETF language tag</a>, allowing bots to adapt accordingly. </p>
|
<p>Bots can tailor their interfaces to <strong>support multiple languages</strong> – updating inputs and information on the fly. A user’s in-app <a href="/bots/api#user">language_code</a> is included in every relevant <a href="/bots/api#Update">update</a> as an <a href="https://en.wikipedia.org/wiki/IETF_language_tag">IETF language tag</a>, allowing bots to adapt accordingly. </p>
|
||||||
<p>We recommend that you follow our guidelines to provide <strong>the best user experience</strong>.</p>
|
<p>We recommend that you follow our guidelines to provide <strong>the best user experience</strong>.</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li>Your interfaces, texts and <a href="api#answerinlinequery">inline results</a> should adapt seamlessly to the <em>language_code</em>, without user intervention.</li>
|
<li>Your interfaces, texts and <a href="/bots/api#answerinlinequery">inline results</a> should adapt seamlessly to the <em>language_code</em>, without user intervention.</li>
|
||||||
<li>Connected <a href="/bots/webapps">WebApps</a> will receive the user's <em>language_code</em> – your HTML page should account for it.</li>
|
<li>Connected <a href="/bots/webapps">WebApps</a> will receive the user's <em>language_code</em> – your HTML page should account for it.</li>
|
||||||
<li><a href="html5-games">HTML5 Games</a> can obtain language information if you specify it as a <a href="games#using-url-parameters">URL parameter</a>. You can generate this parameter from the <em>language_code</em> field in the <a href="api#User">User</a> object served with the initial game <a href="api#callbackquery">CallbackQuery</a>.</li>
|
<li><a href="/bots/html5-games">HTML5 Games</a> can obtain language information if you specify it as a <a href="/bots/games#using-url-parameters">URL parameter</a>. You can generate this parameter from the <em>language_code</em> field in the <a href="/bots/api#User">User</a> object served with the initial game <a href="/bots/api#callbackquery">CallbackQuery</a>.</li>
|
||||||
<li>Command lists can also be specified for individual languages – more on this <a href="#commands">here</a>.</li>
|
<li>Command lists can also be specified for individual languages – more on this <a href="#commands">here</a>.</li>
|
||||||
</ul>
|
</ul>
|
||||||
<div class="blog_video_player_wrap" style="max-width: 400px; margin: 20px auto 20px;">
|
<div class="blog_video_player_wrap" style="max-width: 400px; margin: 20px auto 20px;">
|
||||||
|
@ -341,7 +341,7 @@ width=44% /></a>
|
||||||
<ul>
|
<ul>
|
||||||
<li>Commands explicitly meant for them (e.g., <code>/command@this_bot</code>).</li>
|
<li>Commands explicitly meant for them (e.g., <code>/command@this_bot</code>).</li>
|
||||||
<li>General commands (e.g. <code>/start</code>) if the bot was the last bot to send a message to the group.</li>
|
<li>General commands (e.g. <code>/start</code>) if the bot was the last bot to send a message to the group.</li>
|
||||||
<li>Inline messages sent <a href="api#inline-mode">via</a> the bot.</li>
|
<li>Inline messages sent <a href="/bots/api#inline-mode">via</a> the bot.</li>
|
||||||
<li>Replies to any messages implicitly or explicitly meant for this bot.</li>
|
<li>Replies to any messages implicitly or explicitly meant for this bot.</li>
|
||||||
</ul>
|
</ul>
|
||||||
<p>All bots will also receive, <strong>regardless of privacy mode</strong>:</p>
|
<p>All bots will also receive, <strong>regardless of privacy mode</strong>:</p>
|
||||||
|
@ -378,18 +378,18 @@ width=44% /></a>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
<blockquote>
|
<blockquote>
|
||||||
<p>To provide a good user experience, please respond to all messages that are sent to your bot. Respond to message updates by calling send… methods (e.g. <a href="api#sendmessage">sendMessage</a>).</p>
|
<p>To provide a good user experience, please respond to all messages that are sent to your bot. Respond to message updates by calling send… methods (e.g. <a href="/bots/api#sendmessage">sendMessage</a>).</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
<ul>
|
<ul>
|
||||||
<li><strong>Too few answers to inline queries</strong>. Conversion rate: <strong>{value}</strong> - Your bot is not replying to all inline queries that are being sent to it, calculated in the same way as above. Respond to <code>inline_query</code> updates by calling <a href="api#answerInlineQuery">answerInlineQuery</a>.</li>
|
<li><strong>Too few answers to inline queries</strong>. Conversion rate: <strong>{value}</strong> - Your bot is not replying to all inline queries that are being sent to it, calculated in the same way as above. Respond to <code>inline_query</code> updates by calling <a href="/bots/api#answerInlineQuery">answerInlineQuery</a>.</li>
|
||||||
</ul>
|
</ul>
|
||||||
<ul>
|
<ul>
|
||||||
<li><strong>Too few answers to callback queries</strong>. Conversion rate: <strong>{value}</strong></li>
|
<li><strong>Too few answers to callback queries</strong>. Conversion rate: <strong>{value}</strong></li>
|
||||||
<li><strong>Too few answers to callback game queries</strong>. Conversion rate: <strong>{value}</strong> - Your bot is not replying to all callback queries that are being sent to it (with or without games), calculated in the same way as above. Respond to <code>callback_query</code> updates by calling <a href="api#answerCallbackQuery">answerCallbackQuery</a>.</li>
|
<li><strong>Too few answers to callback game queries</strong>. Conversion rate: <strong>{value}</strong> - Your bot is not replying to all callback queries that are being sent to it (with or without games), calculated in the same way as above. Respond to <code>callback_query</code> updates by calling <a href="/bots/api#answerCallbackQuery">answerCallbackQuery</a>.</li>
|
||||||
</ul>
|
</ul>
|
||||||
<h4><a class="anchor" name="local-bot-api" href="#local-bot-api"><i class="anchor-icon"></i></a>Local Bot API</h4>
|
<h4><a class="anchor" name="local-bot-api" href="#local-bot-api"><i class="anchor-icon"></i></a>Local Bot API</h4>
|
||||||
<p>You can host and work with <strong>your own instance</strong> of our open-source <a href="api">Bot API</a>.<br>The <strong>source code</strong> is available <a href="https://github.com/tdlib/telegram-bot-api">here</a>, along with a quick <a href="https://github.com/tdlib/telegram-bot-api#installation">installation guide</a>.</p>
|
<p>You can host and work with <strong>your own instance</strong> of our open-source <a href="/bots/api">Bot API</a>.<br>The <strong>source code</strong> is available <a href="https://github.com/tdlib/telegram-bot-api">here</a>, along with a quick <a href="https://github.com/tdlib/telegram-bot-api#installation">installation guide</a>.</p>
|
||||||
<p>After <strong>installing the server</strong>, remember to use the <a href="api#logout">logOut</a> method before <strong>redirecting requests</strong> to your new local API URL.</p>
|
<p>After <strong>installing the server</strong>, remember to use the <a href="/bots/api#logout">logOut</a> method before <strong>redirecting requests</strong> to your new local API URL.</p>
|
||||||
<blockquote>
|
<blockquote>
|
||||||
<p>Your local instance runs on port <code>8081</code> by default and will only accept HTTP requests, so a TLS termination proxy has to be used to handle remote HTTPS requests.</p>
|
<p>Your local instance runs on port <code>8081</code> by default and will only accept HTTP requests, so a TLS termination proxy has to be used to handle remote HTTPS requests.</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
|
@ -407,7 +407,7 @@ width=44% /></a>
|
||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
<tr>
|
<tr>
|
||||||
<td><a href="api#making-requests">Official</a></td>
|
<td><a href="/bots/api#making-requests">Official</a></td>
|
||||||
<td>20MB</td>
|
<td>20MB</td>
|
||||||
<td>50MB</td>
|
<td>50MB</td>
|
||||||
<td>HTTPS</td>
|
<td>HTTPS</td>
|
||||||
|
@ -415,7 +415,7 @@ width=44% /></a>
|
||||||
<td>1-100</td>
|
<td>1-100</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td><a href="api#using-a-local-bot-api-server">Local</a></td>
|
<td><a href="/bots/api#using-a-local-bot-api-server">Local</a></td>
|
||||||
<td>Unlimited</td>
|
<td>Unlimited</td>
|
||||||
<td>2000MB</td>
|
<td>2000MB</td>
|
||||||
<td>HTTP</td>
|
<td>HTTP</td>
|
||||||
|
@ -499,9 +499,9 @@ width=44% /></a>
|
||||||
<p>Please note that it may take a few minutes for changes to take effect.</p>
|
<p>Please note that it may take a few minutes for changes to take effect.</p>
|
||||||
</blockquote>
|
</blockquote>
|
||||||
<hr>
|
<hr>
|
||||||
<p>With this information, you are ready to proceed to our <a href="api">Full API Reference for Developers</a>.</p>
|
<p>With this information, you are ready to proceed to our <a href="/bots/api">Full API Reference for Developers</a>.</p>
|
||||||
<ul>
|
<ul>
|
||||||
<li>If you have any questions, check out our <a href="faq">Bot FAQ</a>.</li>
|
<li>If you have any questions, check out our <a href="/bots/faq">Bot FAQ</a>.</li>
|
||||||
<li>If you're experiencing issues with our API, please contact <a href="https://t.me/botsupport">@BotSupport</a> on Telegram.</li>
|
<li>If you're experiencing issues with our API, please contact <a href="https://t.me/botsupport">@BotSupport</a> on Telegram.</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
|
118
data/web/core.telegram.org/bots/html5-games.html
Normal file
118
data/web/core.telegram.org/bots/html5-games.html
Normal file
|
@ -0,0 +1,118 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html class="">
|
||||||
|
<head>
|
||||||
|
<meta charset="utf-8">
|
||||||
|
<title>Page not found</title>
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||||
|
<meta property="description" content="">
|
||||||
|
<meta property="og:title" content="Page not found">
|
||||||
|
<meta property="og:image" content="">
|
||||||
|
<meta property="og:description" content="">
|
||||||
|
<link rel="icon" type="image/svg+xml" href="/img/website_icon.svg?4">
|
||||||
|
<link rel="apple-touch-icon" sizes="180x180" href="/img/apple-touch-icon.png">
|
||||||
|
<link rel="icon" type="image/png" sizes="32x32" href="/img/favicon-32x32.png">
|
||||||
|
<link rel="icon" type="image/png" sizes="16x16" href="/img/favicon-16x16.png">
|
||||||
|
<link rel="alternate icon" href="/img/favicon.ico" type="image/x-icon" />
|
||||||
|
<link href="/css/bootstrap.min.css?3" rel="stylesheet">
|
||||||
|
|
||||||
|
<link href="/css/telegram.css?232" rel="stylesheet" media="screen">
|
||||||
|
<style>
|
||||||
|
</style>
|
||||||
|
</head>
|
||||||
|
<body class="preload">
|
||||||
|
<div class="dev_page_wrap">
|
||||||
|
<div class="dev_page_head navbar navbar-static-top navbar-tg">
|
||||||
|
<div class="navbar-inner">
|
||||||
|
<div class="container clearfix">
|
||||||
|
<ul class="nav navbar-nav navbar-right hidden-xs"><li class="navbar-twitter"><a href="https://twitter.com/telegram" target="_blank" data-track="Follow/Twitter" onclick="trackDlClick(this, event)"><i class="icon icon-twitter"></i><span> Twitter</span></a></li></ul>
|
||||||
|
<ul class="nav navbar-nav">
|
||||||
|
<li><a href="//telegram.org/">Home</a></li>
|
||||||
|
<li class="hidden-xs"><a href="//telegram.org/faq">FAQ</a></li>
|
||||||
|
<li class="hidden-xs"><a href="//telegram.org/apps">Apps</a></li>
|
||||||
|
<li class=""><a href="/api">API</a></li>
|
||||||
|
<li class=""><a href="/mtproto">Protocol</a></li>
|
||||||
|
<li class=""><a href="/schema">Schema</a></li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="container clearfix">
|
||||||
|
<div class="dev_page">
|
||||||
|
<div id="dev_page_content_wrap" class=" ">
|
||||||
|
<div class="dev_page_bread_crumbs"></div>
|
||||||
|
<h1 id="dev_page_title">Page not found</h1>
|
||||||
|
|
||||||
|
<div id="dev_page_content">The page has not been saved</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="footer_wrap">
|
||||||
|
<div class="footer_columns_wrap footer_desktop">
|
||||||
|
<div class="footer_column footer_column_telegram">
|
||||||
|
<h5>Telegram</h5>
|
||||||
|
<div class="footer_telegram_description"></div>
|
||||||
|
Telegram is a cloud-based mobile and desktop messaging app with a focus on security and speed.
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="footer_column">
|
||||||
|
<h5><a href="//telegram.org/faq">About</a></h5>
|
||||||
|
<ul>
|
||||||
|
<li><a href="//telegram.org/faq">FAQ</a></li>
|
||||||
|
<li><a href="//telegram.org/privacy">Privacy</a></li>
|
||||||
|
<li><a href="//telegram.org/press">Press</a></li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
<div class="footer_column">
|
||||||
|
<h5><a href="//telegram.org/apps#mobile-apps">Mobile Apps</a></h5>
|
||||||
|
<ul>
|
||||||
|
<li><a href="//telegram.org/dl/ios">iPhone/iPad</a></li>
|
||||||
|
<li><a href="//telegram.org/android">Android</a></li>
|
||||||
|
<li><a href="//telegram.org/dl/web">Mobile Web</a></li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
<div class="footer_column">
|
||||||
|
<h5><a href="//telegram.org/apps#desktop-apps">Desktop Apps</a></h5>
|
||||||
|
<ul>
|
||||||
|
<li><a href="//desktop.telegram.org/">PC/Mac/Linux</a></li>
|
||||||
|
<li><a href="//macos.telegram.org/">macOS</a></li>
|
||||||
|
<li><a href="//telegram.org/dl/web">Web-browser</a></li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
<div class="footer_column footer_column_platform">
|
||||||
|
<h5><a href="/">Platform</a></h5>
|
||||||
|
<ul>
|
||||||
|
<li><a href="/api">API</a></li>
|
||||||
|
<li><a href="//translations.telegram.org/">Translations</a></li>
|
||||||
|
<li><a href="//instantview.telegram.org/">Instant View</a></li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="footer_columns_wrap footer_mobile">
|
||||||
|
<div class="footer_column">
|
||||||
|
<h5><a href="//telegram.org/faq">About</a></h5>
|
||||||
|
</div>
|
||||||
|
<div class="footer_column">
|
||||||
|
<h5><a href="//telegram.org/blog">Blog</a></h5>
|
||||||
|
</div>
|
||||||
|
<div class="footer_column">
|
||||||
|
<h5><a href="//telegram.org/apps">Apps</a></h5>
|
||||||
|
</div>
|
||||||
|
<div class="footer_column">
|
||||||
|
<h5><a href="/">Platform</a></h5>
|
||||||
|
</div>
|
||||||
|
<div class="footer_column">
|
||||||
|
<h5><a href="https://twitter.com/telegram" target="_blank" data-track="Follow/Twitter" onclick="trackDlClick(this, event)">Twitter</a></h5>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<script src="/js/main.js?46"></script>
|
||||||
|
|
||||||
|
<script>backToTopInit("Go up");
|
||||||
|
removePreloadInit();
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
|
|
Loading…
Reference in a new issue