Skip to content

Latest commit

 

History

History
37 lines (20 loc) · 2.91 KB

part3.md

File metadata and controls

37 lines (20 loc) · 2.91 KB

Part3. Telegram Bot

  1. Open BotFather and follow the instructions to create a new bot and get a token.

  2. Set the current value of the token variable using the bot token from (1)

  3. Check the API requests:

    • The bot info (method getMe)

      Run In Postman

    • Method getUpdates to get user_id and chat_id

      Run In Postman

  4. After this you need to set the current value of the chat_id variable using the chat_id from the response of the getUpdates request.

  5. Check the rest of API requests:

    • Send message with sendMessage

      Run In Postman

    • Send a photo from the bot

      Run In Postman

    • Send pdf with the same method sendPhoto

      Run In Postman

    • Send docx instead of pdf

      Run In Postman

    • Get user profile photos with getUserProfilePhotos

      Run In Postman