Subscription (join) check - Multi
Subscription (join) checking: a well-known tool that makes bot users stay aware of the events taking place in groups and channels, as well as protects bots from cheating of other robots. If the user is not subscribed to the specified channel or group, he will not get access to the bot's functionality. In @MenuBuilderBot, a subscription can be used to both, check new users and protect menu elements.
Multi-subscription check (as opposed to Basic Subscription Check) implies the ability to check the subscription for any number of groups or channels.
Multi-subscription, being a separate, completely independent functionality, nevertheless is the second (optional) subscription mode. It was decided to leave the Basic Subscription Verification mode as the default one, despite the fact that Multi-subscription technically can also check ONE group. There are several reasons for such decision. Firstly, it allows you to keep the existing acquisition mechanism, which makes it possible to add a one-time subscription verification through the "one purchase for lifetime" model, allowing you to verify the subscription in your project without incurring additional costs. Secondly, to preserve the possibility of simplified configuration of ONE group for those who DOESN'T need to check multiple addresses.
❖ How to enable multi-subscription check option
Before you can use the Multi-Subscription verification abilities, you must enable Subscription Check.
Enable "Subscription Сheck" if you haven't enabled it before.
Subscription Check.
To connect, go in your bot:
☞ 🔐Admin | 🧩Extensions | 📂Protection
Enabling of Multi-subscription mode occurs in:☞ 🔐Admin | 🚻Subscription Check
This section will appear only after activating the Subscription Check itself.
Switch to Mode: Multi-subscription
By default being in the Basic Subscription mode and pressing on this button you will switch to the Multi-subscription mode.
IMPORTANT: The Multi-subscription mode is a SEPARATE mode - its operating has nothing to do with the Basic Subscription Check in its functionality aspect. This mode SUBSTITUTES the settings of Basic mode - NONE of the settings configured in Basic Mode will work in Multi Mode. Your bot, at a time, can only stay in ONE of these modes. If you accelerated the Basic subscription check using additional plugins (Weekly and Daily checks), then their work time will continue to go on - regardless of the selected mode. Don't activate accelerator plugins or don't use multi-subscription. We don't see any reason to further complicate this function.
❖ Common settings of Multi-subscription check
Adding a bot to a groups and channels
In order for the bot to check the user's subscription, you need to add your bot to the group or channel that you want to check the subscription to.
How to do this is described in the guide "How to set up a bot for working in groups".
Make sure that:
1. Your bot is correctly added to all necessary groups and channels, does not leave them spontaneously.
2. The bot s an Admin in those groups.
3. And in the section:🔐 Admin | 🧫 Channels & Groups | My Groups
All the necessary groups and channels appeared.
4. You set names to all groups.
5. All group are turned On.
After that return to this guide.
❖ Turning on Multi-subscription (to the whole bot)
Selecting groups for Multi-subscription
Select Groups/Channels
Press: "Select Groups / Channels"
List of groups and channels configured and enabled by us earlier in:🔐 Admin | 🧫 Channels and Groups | My Groups
will be presented as inline buttons.
Specify the channels and groups, which subscription you want to check, by clicking on the corresponding button. The selected groups will be marked with the respective symbol.
The name of the group will not be displayed on the button if you did not specify it while adding the group to the bot. To make it easier for you to identify the relevant groups, go to:🔐 Admin | 🧫 Channels and Groups | My Groups
and give the groups a "Name" that matches their purpose.
Creating messages for the user
The process of adding messages in buttons:
Message to Subscribe
Message if the user is NOT Subscribed
the same as described in the Basic Subscription manual.
Enabling multi-subscription check
Enabling checking for the entire bot occurs in:☞ 🔐Admin | 🚻 Subscription Check
Checking
This option enables verification of the subscription to the ENTIRE BOT. If you only need to check individual buttons, then this setting should be left OFF.
Multi-subscription verification has four modes.
Modes:Off ⏹️
- the function is disabled.🆕 New Ref.
- enabled only for new users who came by Ref. Link.🆕 New All
- enabled for all new users.🆕 All
- enabled for all users and verification occurs at the specified frequency.
When you turn on the "All" mode, an ADDITIONAL BUTTON APPEARS in the settings to select the frequency of the check: "Once" - by default, you can also select "Once a week" and "Once a day".
The current setting is indicated on the button itself, the modes will switch in a circle.
IMPORTANT: The Multi-Subscription Verification feature consumes Tokens of Functions. The payment model is described in a separate section below.
IMPORTANT: Verification will NOT be enabled if no group has been specified for verification. If the bot gives an error when trying to enable verification - most likely the groups are not set - carefully read the messages of the bot.
❖ Basic subscription mode
Switching to the Basic subscription mode occurs in :☞ 🔐Admin | 🚻 Subscription Check
Switch to Mode: Basic Subscription
Being in the Multi-subscription mode and pressing this button you will switch to the Basic Subscription mode.
The data of the settings for both modes when they are switched - will be preserved. That is, if you have set up a Subscription check in both of the modes, than accidental mode switching will not delete any of the settings.
At the time of transition from one mode to another - until the new mode is fully configured, your bot may appear without subscription protection. If the presence of protection is important for you, then while switching from Multi mode to Basic, if you have not configured Basic mode before, you may turn on the "Maintenance Mode" in bot.
Read more about setting up and operating the Basic subscription mode in the manual.
❖ Checking an individual user by ID
This feature is described in the Basic Subscription manual .
❖ Enabling Multi-subscription (on the button)
If you don't wanna block the entire bot, but only part of it, you can set the subscription check to any button.
Multi-subscription for buttons is enabled through button's settings:
• Go to your bot:
☞ Buttons Editor.
• Select a button by pressing it.
• Press the inline button with an asterisk ( * ) in the button's data message to access its Settings.
• Click "Subscription (Join)" to go to the Subscription settings for that button.
The process is described in details in the Basic Subscription manual , there is no point of repeating it here.
The settings on the button are similar to the settings in the section:☞ 🔐Admin | 🚻 Subscription Check
where the subscription "For the whole bot" is configured.
Here you will also need to specify:
1. Groups to check (they may differ from those specified "For the whole bot")
2. The period (frequency) of checking the subscription.
3. Message about the need to subscribe.
4. Message in case the user is not subscribed (error message).
If the list of groups that has to be checked on the button, matches the list of groups to be checked "For the whole bot", then the messages "Asking user to subscribe" and "If the user is not subscribed" are optional. If you didn't set them, they will be taken from the "For the whole bot" settings.
5. Click "Checking" - to enable validation for this button.
The current setting is indicated on the button, the modes will switch in a circle.
❖ Multi-subscription payment model
Payment for the Multi-Subscription Checking functionality is carried out in Tokens of Functions and occurs only upon the fact of each individual verification. Both, Monthly (renewable) tokens and Additional tokens are used.
After the end of the Monthly (renewable) Tokens of Functions - Additional Tokens will be used to pay for the Multi-Subscription Checking.
IMPORTANT: If ALL Tokens of Functions (Renewable and Additional) have run out, then all checks where there are groups from the Multi-subscription list will not pass. Users will receive a system failure message instead of the configured or default validation failure message, prompting them to contact the bot's administrator. The administrator himself will receive messages about such unsuccessful attempts, BUT not more often than once in every 5-10 minutes (similar errors will be issued if you remove the bot, the group subscription to which you actually configured to check).
If you need, acquire Additional Tokens of Functions:
Tokens of Functions.
To get, go in your bot:☞ 🔐Admin | 🧩Extensions | 📂Actions
Rules for checking a group subscription and deduction of tokens
For those of you who doesn't want to dig into details - briefly about the subscription verification logic.
Checks are designed so that they are carried out as rarely as possible, and if needed, the check is done in the least costly way (saving Tokens of Functions), using session's data, databases, and only with a clear time expiration, turn to the most costly method - the actual verification of the user in the group.
A more detailed description of the logic is provided below.
For reference. Based on the results of a successful user verification of the group, the verification result is saved in Database
. If there is an entry in the Database, the next check for a group will not be earlier than the Check Period configured for this group. Moreover, for the current user's Session
, a successful check (by Database or by actual Group
) is remembered and in the current Session it is no longer checked in either one of them.
When a user performs an action that requires a subscription verification (starting a bot as a new user, pressing a button with explicitly configured verification, pressing any button when Basic group is set in the "Always" mode), checks are performed in the following sequence:
1. Checking in the current Session
. If the group has already been verified for this Session - Tokens are NOT deducted.
2. Checking in Database
. 1
Token of Functions will be deducted. If the group has already been verified and the verification period has not yet expired, then the verification ends here. The result remains in the current Session, next times during the Session there will be no more checks in the Database.
3. Checking in Group
. 4
Tokens of Functions more will be deducted (5 in total). If the user is in a group, the result is saved to the Database and during the specified period there will be no more checks in the Group. Also, the result remains in the current Session.
❖ Typical subscription verification errors
The Subscription is not verified for the bot's admins.
If you (as Admin or Owner) need to test - test it from additional accounts.
• • •
Checking of old users.
If you have just set up a Start checking (new referral, new user) and want to check on an account that is ALREADY a bot's user - nothing will come of it: he is already a bot's user. You can check this user by switching the check of the Basic group to the "All" mode or by using additional group (from Multi-Subscription list).
• • •
The bot is not an admin.
For any checks (and in general for any work of a bot in a group), the bot must be added to this group as group's administrator.
• • •
The group set for subscription check was deleted.
Be careful when deleting groups if you configured subscription checks on them. Buttons (or the bot itself) that checks subscription to groups that have been removed from the bot, will generate errors. It will be impossible to pass the check - until the corresponding button (or the whole bot check) is configured properly.