diff --git a/docs/develop/dapps/telegram-apps/app-examples.mdx b/docs/develop/dapps/telegram-apps/app-examples.mdx index 89fb5ea132..88e50c732f 100644 --- a/docs/develop/dapps/telegram-apps/app-examples.mdx +++ b/docs/develop/dapps/telegram-apps/app-examples.mdx @@ -288,32 +288,9 @@ And now we need to create Telegram Bot so we can launch Telegram Web App within ### Setting Up a Bot for the App -Follow these steps to set up a new Telegram bot: +To connect your Web App to the Telegram, you need to create a bot and set up a web app for it. Follow these steps to set up a new Telegram bot: -#### 1. Start a Chat with BotFather - -- Open the Telegram app or web version. -- Search for `@BotFather` in the search bar or follow the link [https://t.me/BotFather](https://t.me/BotFather). -- Start a chat with BotFather by clicking on the `START` button. - -#### 2. Create a New Bot - -- Send `/newbot` command to BotFather. -- BotFather will ask you to choose a name for your bot. This is a display name and can contain spaces. -- Next, you'll be asked to choose a username for your bot. This must end in `bot` (e.g., `sample_bot`) and be unique. - -#### 3. Set Up Bot Web App - -- Send `/mybots` command to BotFather. -- Choose your bot from the list and the **Bot settings** option -- Choose **Menu button** option -- Choose **Edit menu button URL** option and send URL to your Telegram Web App, for example link from GitHub Pages deploy. - -#### 4. Accessing the Bot - -- You can now search for your bot using its username in Telegram's search bar. -- Press the button next to attach picker to launch your Telegram Web App in meseenger -- You’re awesome! + ### Hints diff --git a/docs/develop/dapps/telegram-apps/step-by-step-guide.mdx b/docs/develop/dapps/telegram-apps/step-by-step-guide.mdx index c6e69d194d..e0aa14083f 100644 --- a/docs/develop/dapps/telegram-apps/step-by-step-guide.mdx +++ b/docs/develop/dapps/telegram-apps/step-by-step-guide.mdx @@ -11,7 +11,7 @@ Telegram Web Apps are web applications that run inside the Telegram messenger. T ``` -2. Once the script is connected, a **[window.Telegram.WebApp](https://core.telegram.org/bots/webapps#initializing-web-apps)** object become available. You can read more about creating Web App utilising [`telegram-web-app.js`](https://core.telegram.org/bots/webapps#initializing-web-apps) here. +2. Once the script is connected, a **[window.Telegram.WebApp](https://core.telegram.org/bots/webapps#initializing-web-apps)** object become available. You can read more about creating Web App utilising [`telegram-web-app.js`](https://docs.ton.org/develop/dapps/telegram-apps/app-examples#basic-twa-example) here. 3. The modern way to connect SDK is npm package for Telegram Web Apps SDK: @@ -19,7 +19,7 @@ Telegram Web Apps are web applications that run inside the Telegram messenger. T npm i @twa-dev/sdk ``` -You can find guide for [`@twa-dev/sdk`](https://docs.twa.dev/docs/libraries/twa-js-sdk/about) here. +You can find guide for [`@twa-dev/sdk`](https://docs.ton.org/develop/dapps/telegram-apps/app-examples#modern-twa-example ) here. 5. When your Web App is ready and deployed to the web server, follow to the next step.