Better connections is a simple API for Better Connections Bot
- Hyakanime
- Deezer
- Monkeytype
- Clone the repository
git clone https://github.com/oriionn/better-connections-api.git
- Go to the project directory
cd better-connections-api
- Install dependencies
npm install
- Copy the .env.example file and rename it to .env
cp .env.example .env
- Edit the .env file and fill in the required fields
PORT=3000
AESKEY=zsc5MV834CLAwm6Gj47FrE23pM4buzVi7296AZ3p383M3uZVCHMYd9dWauUccEJ9Y2j8qiUikk2DG8mVB58593K524acY7qC8DivGQbknzWf3Nd227udK2UUpK9yL58w
APIKEY=gVn6vTDz4sfNR2t99Kspm8i9sd436dy4ee5M7Q3Y73Nkz7jvhzTRy226R8433cE3naydjGUsSMN5P6X2hR8cWZ336X75BnUYdQsVpzGuM99zE6F84Am7h3J8yFNSQ2TU
DB_PATH=./db.json
DEEZER_APPID=
DEEZER_SECRET=
DEEZER_REDIRECT_URI=http://localhost:3000/connections/deezer
- Copy db.json.example file and rename it to db.json
cp db.json.example db.json
- Run the server
npm start
{
"status": 200,
"message": "API is running"
}
Parameters | Type | Description |
---|---|---|
id |
number |
Discord User Id |
key |
string |
API Key |
{
"status": 200,
"message": "zsc5MV834CLAwm6Gj47FrE23pM4buzVi7296AZ3p383M3uZVCHMYd9dWauUccEJ9Y2j8qiUikk2DG8mVB58593K524acY7qC8DivGQbknzWf3Nd227udK2UUpK9yL58w"
}
Parameters | Type | Description |
---|---|---|
id |
number |
Discord User's Id |
{
"status": 200,
"message": { "hyakanime": { "username": "user", "link": "https://hyakanime.fr/profile/user" } }
}
Parameters | Type | Description |
---|---|---|
token |
string |
Better connections's user's key |
PS: Other parameters can be required depending on the connection |
{
"status": 200,
"message": "OK"
}
PS: Response depending on the connection
Parameters | Type | Description |
---|---|---|
token |
string |
Better connections's user's token |
{
"status": 200,
"message": "OK"
}
- Deezer
{
"status": 200,
"message": "(Oauth Link)"
}