Skip to content
This repository has been archived by the owner on Sep 14, 2023. It is now read-only.

Making requests when getting updates #9

Open
9px opened this issue Sep 5, 2015 · 2 comments
Open

Making requests when getting updates #9

9px opened this issue Sep 5, 2015 · 2 comments

Comments

@9px
Copy link

9px commented Sep 5, 2015

hi. telegram recently add an ability to perform a request to the telegram Bot API while sending an answer to the webhook.
can you do a simple implement of this feature in your bot?

@eljojo
Copy link
Owner

eljojo commented Sep 14, 2015

Hi, I haven't read about this.
I'll try to get some time this week to read about this!

Any PRs are welcome :)

@solyarisoftware
Copy link

I agree with @9px request, a webhook example could help, maybe a very simple sinatra example

BTW, generally speaking, the HTTP long polling seems to me a not great solution in terms of resources efficency; maybe a SSE (Server Sent Events) could be better... anyway the choice is between HTTP long polling ( https://core.telegram.org/bots/api#getting-updates ) vs HTTP webhooks ( https://core.telegram.org/bots/api#setwebhook ). This last case fit maybe better for a bot that could manage a very high troughtput (messages/sec). Telegram Bot API webhooks settings iare not too clear in documentation at my first glance...

Thanks @eljojo for your work, I'll do a PR if I'll be able...!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants