-
Notifications
You must be signed in to change notification settings - Fork 162
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WIP: Extend SpamWatch integration #117
Comments
The first suggestion is good, I find the second one rather pointless.
|
Okay. I'll note about that as this issue is an Work-in-Progress. Once this issue is finalized, then we can clear the stuff out, @SitiSchu. |
Having a command for the API documentation still doesn't make sense |
About the Issue
Integrating it with SpamWatch on joins is good, but can we extend SpamWatch on the following suggestions:
XXYYZZAABBCC
when triggered the/user
./spamwatch
command).First Suggestion: Manually checking status of a user when admins triggered
/user
When an admin triggers the
/user
command for userXXYYZZAABBCC
, the server/machine where the bot is hosted should contact the SpamWatch API (defaults toapi.spamwat.ch
if undefined inconfig.js
/config.json
) for the status of the user if he/she is banned.When checking for the ban status using this method, use the defined API token in the config as
SPAMWATCH_API_TOKEN
.Second Suggestion: Adding new way of interacting the API without extra lines of code
This suggestion will add a new command for that,
/spamwatch
. The usage of that command describes below as it says. See the SpamWatch API docs for details./spamwatch banlist
spamwatch banlist
/spamwatch query
<uid or username>
user <uid, username or reply>
as shortcut/spamwatch query 777000
/spamwatch about
<token>
/spamwatch about
/spamwatch docs
Legends:
< >
= Required[ ]
= optionalNotes
XXYYZZAABBCC
represents a Telegram user's unique ID, generated after signup per user.The API token should be there in the config file instead of manually sending it to the bot.SPAMWATCH_API_TOKEN
represents a valid, working SpamWatch API token.--force
flag is used and send the response as a JSON file.The text was updated successfully, but these errors were encountered: