Skip to content

Conversation

@rahiel
Copy link
Contributor

@rahiel rahiel commented Jul 9, 2016

A module with constants of the Telegram network. The constants are tested, so we'll now when Telegram will change them...

@jh0ker
Copy link
Member

jh0ker commented Jul 11, 2016

Further suggestions

Message limits:

  • MAX_MESSAGES_PER_SECOND = 30
  • MAX_MESSAGES_PER_SECOND_PER_CHAT = 1
  • MAX_MESSAGES_PER_MINUTE_PER_GROUP = 20

File sizes

  • MAX_FILESIZE_UPLOAD = 50000000 (50MB)
  • MAX_FILESIZE_DOWNLOAD = 20000000 (20MB)
  • There may be a special limit (size or length) for voice messages, I'll check that out

Others:

  • SUPPORTED_WEBHOOK_PORTS = [443, 80, 88, 8443]

Edit: Testing these could be difficult

@MWeesenaar
Copy link
Contributor

Looks good to me!
Tests run and are green.

@rahiel
Copy link
Contributor Author

rahiel commented Jul 14, 2016

MAX_MESSAGES_PER_SECOND_PER_CHAT = 1

From where was this? My bot can send me 30 messages per second.

@jh0ker
Copy link
Member

jh0ker commented Jul 14, 2016

@rahiel from the bot FAQ:

When sending messages inside a particular chat, avoid sending more than one message per second. We may allow short bursts that go over this limit, but eventually you'll begin receiving 429 errors.

@rahiel rahiel merged commit ef334f2 into master Jul 14, 2016
rahiel added a commit that referenced this pull request Jul 14, 2016
@rahiel rahiel removed the 📋 pending-reply work status: pending-reply label Jul 14, 2016
@rahiel rahiel deleted the constants branch July 14, 2016 20:02
@github-actions github-actions bot locked and limited conversation to collaborators Aug 24, 2020
@Bibo-Joshi Bibo-Joshi added 🔌 enhancement pr description: enhancement and removed enhancement labels Nov 3, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

🔌 enhancement pr description: enhancement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants