Skip to content

starts a bot that announces all current streamers of a set category in the channel the category was added.

Notifications You must be signed in to change notification settings

mauer01/discordtwitchbot

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

37 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

DiscordTwitchBot

A simple Java-based Discord bot integrated with Twitch functionality. This bot utilizes the JDA (Java Discord API) for interacting with Discord and connects to Twitch for additional features.

Invite Link: https://discord.com/oauth2/authorize?client_id=1170492845006802944&permissions=18432&integration_type=0&scope=bot

Features

  • Responds to Discord messages with custom reactions.
  • Monitors Twitch streams using provided credentials.
  • Configurable status and activity for the bot.

Prerequisites

Tools and Libraries:

  • Java Development Kit (JDK): Ensure you have JDK 8 or higher installed.
  • Maven: Build and manage your project dependencies.
  • JDA: Discord Java library for bot development.
  • dotenv: Library for managing environment variables.

Accounts and Credentials:

  1. Discord Bot Token
  2. Twitch Application Credentials

Installation

  1. Clone the repository:

    git clone <repository-url>
    cd DiscordTwitchBot
  2. Install dependencies using Maven:

    mvn clean install
  3. Set up environment variables:

    • Create a .env file in the root of the project.
    • Add the following keys:
      DISCORD_TOKEN=your_discord_token
      DISCORD_STATUS=your_bot_status
      TWITCH_CLIENT_ID=your_twitch_client_id
      TWITCH_CLIENT_SECRET=your_twitch_client_secret

Usage

  1. Run the bot:

    mvn exec:java -Dexec.mainClass="main.DiscordTwitchBot"
  2. The bot will:

    • Appear online in Discord with the configured status.
    • Start responding to messages as defined in NachrichtenReaktion.
    • Interact with Twitch using the MyTwitch class (ensure proper implementation).

Project Structure

  • main/
    • DiscordTwitchBot: Main entry point for the application.
    • NachrichtenReaktion: Handles Discord message reactions.
    • Categories: Manages dynamic bot behavior and parameters.
    • MyTwitch: Interacts with Twitch API (implementation required).

Contributing

  1. Fork the repository.
  2. Create your feature branch (git checkout -b feature/your-feature).
  3. Commit your changes (git commit -m 'Add your feature').
  4. Push to the branch (git push origin feature/your-feature).
  5. Open a Pull Request.

Acknowledgments

  • JDA for the powerful Discord API.
  • dotenv for environment variable management.
  • Twitch API for stream data and interaction.

About

starts a bot that announces all current streamers of a set category in the channel the category was added.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •  

Languages