A simple Discord bot built with Discord.js and TypeScript. This bot is currently under development, and new features are coming soon. Stay tuned!
- Ping Command: Responds with "Pong!".
- Hello Command: Responds with a greeting message.
- Weather Command: Fetches and displays the weather for a specified city.
- Convert Command: Converts a value from one currency to another.
- Echo Command: Repeats the message provided by the user.
- Coinflip Command: Flips a coin and returns the result.
- Poll Command: Creates a simple poll.
- Serverinfo Command: Displays information about the server.
- Discord.js: Powerful library for interacting with the Discord API.
- TypeScript: Strongly typed programming language for building robust applications.
To run the project locally, follow these steps:
-
Clone the repository:
git clone https://github.com/MatheusCampagnolo/discord-bot-ts.git cd discord-bot-ts
-
Install dependencies:
npm install
-
Create a
.env
file and add your Discord bot token and client ID, make sure to also add the API's token:DISCORD_TOKEN=your-discord-token CLIENT_ID=your-client-id GUILD_ID=your-guild-id EXCHANGE_RATE_API_KEY=your-exchange-rate-api-token
-
Deploy commands:
npm run deploy-commands
-
Run the bot:
npm start
The bot should be running and connected to your Discord server.
/src
├── /commands # Command files
├── /utils # Utility functions
├── index.ts # Main entry file for the bot
├── deploy-commands.ts # Script to deploy slash commands
.env # Environment variables
.gitignore # Git ignore file to exclude unnecessary files
package.json # Project configuration and dependencies
tsconfig.json # TypeScript configuration file
README.md # This README file
This project is licensed under the MIT License - see the LICENSE file for details.
This bot is currently under development. New features and improvements are being added regularly. Stay tuned for updates!