mirror of
https://github.com/miloszowi/everyone-mention-telegram-bot.git
synced 2025-10-10 17:16:03 +00:00
Group name length validation increased, updated contents, readme, changelog
This commit is contained in:
@@ -6,38 +6,36 @@ not_left = '{} did not join group `{}` before'
|
||||
mention_failed = 'There are no users to mention'
|
||||
no_groups = 'There are no groups for this chat'
|
||||
|
||||
|
||||
# html python-telegram-bot specific
|
||||
start_text = """
|
||||
Hello!
|
||||
@everyone_mention_bot here.
|
||||
|
||||
<b>Description</b>:
|
||||
I <b>do not</b> have access to your messages!
|
||||
I am here to help you with multiple user mentions.
|
||||
|
||||
Using <code>Inline Mode</code> is recommended because <a href="https://core.telegram.org/bots/faq#what-messages-will-my-bot-get">policy of bots with privacy mode enabled</a> says that command trigger is sent (without mentioning the bot) only to the last mentioned bot. So if you do have multiple bots in current chat, I might not receive your command!
|
||||
<b>Usage</b>:
|
||||
Users that joined the group by <code>/join</code> command, can be mentioned after calling <code>/everyone</code> command.
|
||||
|
||||
<b>Commands</b>:
|
||||
<pre>/join {group-name}</pre>
|
||||
Joins (or creates if group did not exist before) group.
|
||||
|
||||
<pre>/leave {group-name}</pre>
|
||||
Leaves (or deletes if no other users are left) the group
|
||||
|
||||
<pre>/everyone {group-name}</pre>
|
||||
Mentions everyone that joined the group.
|
||||
|
||||
<pre>/groups</pre>
|
||||
Show all created groups in this chat.
|
||||
|
||||
<pre>/start</pre>
|
||||
Show start & help text
|
||||
|
||||
Available commands:
|
||||
<b>Please note</b>
|
||||
<code>{group-name}</code> is not required, <code>default</code> if not given.
|
||||
|
||||
<b>Join</b>
|
||||
Joins (or creates if group did not exist before) group.
|
||||
<pre>/join {group-name}</pre>
|
||||
|
||||
<b>Leave</b>
|
||||
Leaves (or deletes if no other users are left) the group
|
||||
<pre>/leave {group-name}</pre>
|
||||
|
||||
<b>Everyone</b>
|
||||
Mentions everyone that joined the group.
|
||||
<pre>/everyone {group-name}</pre>
|
||||
|
||||
<b>Groups</b>
|
||||
Show all created groups in this chat.
|
||||
<pre>/groups</pre>
|
||||
|
||||
<b>Start</b>
|
||||
Show start & help text
|
||||
<pre>/start</pre>
|
||||
|
||||
Reach out to <a href="https://t.me/miloszowi">Creator</a> in case of any issues/questions regarding my usage.
|
||||
If your chat does have multiple bots <b>I might not receive your command</b> according to <a href="https://core.telegram.org/bots/faq#what-messages-will-my-bot-get">policy of bots with privacy mode enabled</a> - use <code>Inline Mode</code> to avoid this.
|
||||
"""
|
||||
|
@@ -4,7 +4,7 @@ from exception.invalidArgumentException import InvalidArgumentException
|
||||
|
||||
|
||||
class GroupNameValidator:
|
||||
MAX_GROUP_NAME_LENGTH: int = 20
|
||||
MAX_GROUP_NAME_LENGTH: int = 40
|
||||
|
||||
@staticmethod
|
||||
def validate(group: str) -> None:
|
||||
|
Reference in New Issue
Block a user