tch1b0 / mogo Goto Github PK
View Code? Open in Web Editor NEWThis Discord bot automatically detects Links and shortens them
License: MIT License
This Discord bot automatically detects Links and shortens them
License: MIT License
Recently, discord added the /
command feature so bots don't conflict with each other.
It would be useful to implement that feature
All commands should be separated in the /commands
directory.
Send a PUT
request to https://ls.johannespour.de/
with this json body:
{
"short": "<short>",
"token": "<token>",
"link": "<link>"
}
to update the corrosponding link of the shortcut
Use something like switch
to execute a command
switch msg {
case "create":
l = Linker[msg[1]]
l = l.Create()
...
case "edit":
....
default:
help()
}
List (in an embed if possible) the commands the User can use.
command:
$help
This bot scans the messages sent for links and tries to make them shorter.
You can manually make a shortcut using $create <link> .
Send a DELETE
request to https://ls.johannespour.de
with this json body:
{
"short": "<short>",
"token": "<token>"
}
I have no clue why, but somehow the token
parameter is not in the response of the POST
https://ls.johannespour.de/create
request.
This isn't a mistake of the backend.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.