This repository has been archived by the owner on Aug 14, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 148
support socks proxy #40
Comments
I have not looked into http/socks for the Telegram bot. I'm not sure the upstream library supports this. github.com/tucnak/telebot Maybe you can open an issue with them and link to this issue? |
u can use http_proxy/https_proxy env variable to user proxy. |
socks proxy dialer, err := proxy.SOCKS5("tcp", "host:port", &proxy.Auth{User: "anon", Password:"anon"}, proxy.Direct)
if err != nil {
t.Fatal("Error creating dialer, aborting.")
}
httpTransport := &http.Transport{}
httpClient := &http.Client{Transport: httpTransport}
httpTransport.Dial = dialer.Dial
bot, err := NewBot(Settings{Token: token, Client:httpClient}) |
Dear Matthias Loibl, |
@obsessionsys please feel free to submit a PR to add the functionality |
@obsessionsys please just use env variable |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hello
Is there support for http/socks proxy for telegram, which keys to use?
If not, could you implement it?
thx
The text was updated successfully, but these errors were encountered: