Skip to content

Carbowix/Cleve

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Cleve

A basic discord chatbot created with Discord.js v14 & powered by Brainshop.ai

license mit node.js discord.js cleve version
Discord server

Installation & Setup

  • Node.js v16.9+ is required to download.
  • Download & extract the files either by git clone https://github.com/Carbowix/Cleve.git or by simply downloading
  • Open your command prompt and be sure you are on the right root directory by using cd command.
  • Once you are sure, proceed with npm install or yarn install command to install latest packages.

Creating a brainshop.ai account bot

  • Register an account at brainshop.ai
  • Once registered and logged-in, Press create a brain -> root brain
  • Enter your custom bot name and make sure details match the following:

Note: Don't edit "url"

Adding discord bot details:

  • Create a discord bot application.
  • Once finished, edit src/misc/config.json file at the "bot_token" parameter to insert your BOT_TOKEN.
  • .env.example file is also available in src folder if you want to use it for any hosting platform. Just insert your BOT_TOKEN and you are good to go.

Once you are done, run npm run start or yarn run start on the command prompt and it should be ready to talk!.

[CLEVE] Loaded 3 commands
[CLEVE] Ready to chat!
  • Mention it, and start talking!

Available Features

  • Slash commands that helps you ease your bot management
  • Set/Remove default chat text channels for the bot. (Supports multiple channels)

  • Ping command to ensure bot is ready to knock on your door.
  • No mention feature so that bot can talk without being mentioned. (Check here for more details)
  • Direct messages chatting is now available through configuration. (Check here for more details)

Issues

If you have any issues feel free to create one in the issues section. Make sure that your issue wasn't listed in the closed issues before creating an issue.

Frequently Asked Questions (FAQ)

How to enable No mention feature

Head to src/misc/config.json and edit "noMention" value to true

  • IMPORANT: In-order for this feature to work, you will have to enable MessageContent Privileged Intent in your discord bot application. Otherwise it will produce and error like the following:

How to enable Direct Messages feature

Head to src/misc/config.json and edit "directMessage" value to true

Bot not replying / API error

It most likely either you failed to to follow the installation instructions correctly or Brainshop.ai API is down

Invalid Token even when loaded though .env file

It is most likely the .env file is either still named .env.example which you should change to .env or the file is not in the src folder. Otherwise your bot token is actually invalid.

Unexpected Token 'S' at position 0

If you are getting that error, it is most likely you are using replit as your hosting environment and unfortunately the API of brainshop does not support it and considers it as spam request. Your likely solution to find another hosting platform.

Credits

  • Thanks BrainshopAI for providing free/fast clever bot API