{"id":25803539,"url":"https://github.com/lixelv/simple-aiogram-webhook","last_synced_at":"2025-02-27T17:56:18.412Z","repository":{"id":166872861,"uuid":"642431091","full_name":"lixelv/simple-aiogram-webhook","owner":"lixelv","description":"This is an example of a simple echo bot using webhooks technology.","archived":false,"fork":false,"pushed_at":"2023-07-08T16:54:10.000Z","size":8675,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-23T20:52:06.235Z","etag":null,"topics":["aiogram","asincio","ngrok","python","telegram","webhook","webhooks"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lixelv.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-05-18T14:49:31.000Z","updated_at":"2025-02-09T01:30:41.000Z","dependencies_parsed_at":null,"dependency_job_id":"ec9f9a09-638b-406b-be5d-4200b82cdf0d","html_url":"https://github.com/lixelv/simple-aiogram-webhook","commit_stats":null,"previous_names":["lixelv/simple_aiogram_webhook","lixelv/simple-aiogram-webhook"],"tags_count":0,"template":true,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lixelv%2Fsimple-aiogram-webhook","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lixelv%2Fsimple-aiogram-webhook/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lixelv%2Fsimple-aiogram-webhook/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lixelv%2Fsimple-aiogram-webhook/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lixelv","download_url":"https://codeload.github.com/lixelv/simple-aiogram-webhook/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241041031,"owners_count":19898973,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["aiogram","asincio","ngrok","python","telegram","webhook","webhooks"],"created_at":"2025-02-27T17:56:17.799Z","updated_at":"2025-02-27T17:56:18.404Z","avatar_url":"https://github.com/lixelv.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# INSTALLATION\n## NGROK\n\nTo work with this bot, and generally to work with webhooks on [aiogram](https://github.com/aiogram), \nwe need to download [ngrok](https://ngrok.com/) for your PC or VPS. After that, open __Windows PowerShell__ \nand navigate to the folder with the installed file (Type in __Windows PowerShell__: \n```\nset-location 'path to folder'\n```\n). \nObtain the [authtoken](https://dashboard.ngrok.com/get-started/your-authtoken) from the website, then run the following command:\n```\nchmod +x ngrok\n./ngrok authtoken (your_token). \n```\nAfter entering the authentication code, we need to start ngrok by running the following command:\n```\n./ngrok http (port)\n ```\nYou can choose any port you like, but for the bot to work, I used port __8080__. \nThen a window with the running __ngrok__ will appear. Copy the first URL after the __Forwarding__ line, \nit should look something like this: __https://6ec8-78-37-108-80.ngrok-free.app__. You need to paste this URL \nwhen you start the bot (I set it up in the __webhook_polling__ method).\nIf you want to run this bot, replace the parameter __YOUR_TELEGRAM_API_TOKEN__ with your __API token__, \nwhich you can obtain from the [BotFather bot](https://t.me/BotFather), and change the parameter __YOUR_USER_ID__ \nto your __user_id__. However, this is optional. If you don't want to receive a message about the start and stop of the bot, \nsimply do not enter the __admin_list__ parameter in the last line of code. \nHere is a link to the bot for getting your __user_id__ in Telegram: [username_to_id_bot](https://t.me/username_to_id_bot). \nLaunch and try it out.\n\n## LIBRARIES\nTo install libraries which I am using in my repository, just run this command \n\n```\npip install путь_до_файла/requests.txt\n```\n\n## .ENV\nIn my repository you can see file .env, there I am storing my telegram token, \nlink and my telegram id. Just replace these parameters on yours.\n\n\n# WEBHOOK_POLLING\nIf you are creating your own __aiogram bot__, instead of the line __executor.start_polling(dp, skip_updates=True)__, \nuse the line __webhook_pooling(dp, port, link)__ these 3 parameters are mandatory, the rest are optional.\nHere is a list of additional parameters:\n- __admin_list__: Pass a list of your bot admins or a list with a single element - your __id__.\n- __startup_message__ and __shutdown_message__: Specify what you want to send to the __admin_list__ when the bot starts and stops.\n### If you have any issues or questions, contact [simeonlimon](https://t.me/simeonlimon).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flixelv%2Fsimple-aiogram-webhook","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flixelv%2Fsimple-aiogram-webhook","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flixelv%2Fsimple-aiogram-webhook/lists"}