mirror of
https://github.com/aiogram/aiogram.git
synced 2025-12-09 01:15:31 +00:00
Upd proxy example.
This commit is contained in:
parent
573264b422
commit
c672faed0b
1 changed files with 2 additions and 1 deletions
|
|
@ -10,12 +10,13 @@ from aiogram.utils.markdown import bold, code, italic, text
|
|||
|
||||
# Configure bot here
|
||||
API_TOKEN = 'BOT TOKEN HERE'
|
||||
PROXY_URL = 'http://PROXY_URL'
|
||||
PROXY_URL = 'http://PROXY_URL' # Or 'socks5://...'
|
||||
|
||||
# If authentication is required in your proxy then uncomment next line and change login/password for it
|
||||
# PROXY_AUTH = aiohttp.BasicAuth(login='login', password='password')
|
||||
# And add `proxy_auth=PROXY_AUTH` argument in line 25, like this:
|
||||
# >>> bot = Bot(token=API_TOKEN, loop=loop, proxy=PROXY_URL, proxy_auth=PROXY_AUTH)
|
||||
# Also you can use Socks5 proxy but you need manually install aiosocksy package.
|
||||
|
||||
# Get my ip URL
|
||||
GET_IP_URL = 'http://bot.whatismyipaddress.com/'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue