PhantomBot

applications
Report Issue

PhantomBot is an actively developed open source interactive Twitch bot with a vibrant community that provides entertainment and moderation for your channel, allowing you to focus on what matters the most to you - your game and your viewers.

Contributors:
README

PhantomBot

Website GitHub PhantomBot is an actively developed open source interactive Twitch bot with a vibrant community that provides entertainment and moderation for your channel, allowing you to focus on what matters the most to you - your game and your viewers.

Server Ports

1 port is required to run PhantomBot.

Port default
Web UI (HTTP Server) 25000
Docker Images (2)
Name Image
Java 16 [DEPRECATED] ghcr.io/ptero-eggs/yolks:java_16
Java 19 ghcr.io/ptero-eggs/yolks:java_19
Startup Command
java --add-opens java.base/java.lang=ALL-UNNAMED -Djava.security.policy=config/security -Dinteractive -Xms1m -Dfile.encoding=UTF-8 -jar PhantomBot.jar
Variables (8)

Version

latest = Latest Stable master = latest Github 3.9.0.7 = Latest known working with Java 16

Environment:
RELEASE_VERSION
Default:
latest
User Viewable:
User Editable:
Rules:
required|string|max:9

Twitch Channel Name

Enter the Twitch channel name where the bot will connect to

Environment:
CHANNEL_NAME
Default:
None
User Viewable:
User Editable:
Rules:
required|string|max:26

Channel Owner

Environment:
CHANNEL_OWNER
Default:
None
User Viewable:
User Editable:
Rules:
required|string|max:26

Bot Twitch Username

Please enter the bot's Twitch username

Environment:
BOT_TWITCH_USERNAME
Default:
None
User Viewable:
User Editable:
Rules:
required|string|max:26

Webpanel Username

Please enter a custom username for the web panel

Environment:
WEBPANEL_USERNAME
Default:
None
User Viewable:
User Editable:
Rules:
required|string|max:64

Webpanel Password

Please enter a custom password for the web panel

Environment:
WEBPANEL_PASSWORD
Default:
None
User Viewable:
User Editable:
Rules:
required|string|max:2000

Youtube API Key

https://phantombot.dev/guides/#guide=content/integrations/youtubesetup

Environment:
YOUTUBE_API_KEY
Default:
None
User Viewable:
User Editable:
Rules:
max:128

Discord Bot Token

https://phantombot.dev/guides/#guide=content/integrations/discordintegrationsetup

Environment:
DISCORD_BOT_TOKEN
Default:
None
User Viewable:
User Editable:
Rules:
max:128
Installation Script
Container: ghcr.io/ptero-eggs/installers:debian
Entrypoint: bash
#!/bin/bash
# PhantomBot Installation Script
#
# Server Files: /mnt/server
apt update
apt -y --no-install-recommends install curl wget ca-certificates unzip

cd /tmp

# Fetching latest github release
if [ -z "${RELEASE_VERSION}" ] || [ "${RELEASE_VERSION}" == "master" ]; then
        echo -e "Using latest Github Master version"
        DOWNLOAD_URL=https://raw.githubusercontent.com/PhantomBot/nightly-build/master/PhantomBot-nightly-lin.zip
else
    if [ -z "${RELEASE_VERSION}" ] || [ "${RELEASE_VERSION}" == "latest" ]; then
        echo -e "Using latest release version"
        RELEASE_VERSION=$(curl -s "https://api.github.com/repos/PhantomBot/PhantomBot/releases/latest" | grep -e '"tag_name"' | sed -E 's/.*"([^"]+)".*/\1/' | sed 's/^.//')
    fi
    DOWNLOAD_URL=https://github.com/PhantomBot/PhantomBot/releases/download/v${RELEASE_VERSION}/PhantomBot-${RELEASE_VERSION}-lin.zip
    echo -e "${DOWNLOAD_URL}"
fi

# Download files
cd /mnt/server
wget ${DOWNLOAD_URL} -O PhantomBot.zip

# Unzip files and delete the archive
unzip -o PhantomBot.zip
rm PhantomBot.zip

# Move unzipped files into the server folder and delete the folder 
cp -f -r ./PhantomBot-*/* /mnt/server/
rm -rf PhantomBot-*/

# Creating default config
if [ ! -f /mnt/server/config/botlogin.txt ]; then
    echo -e "Creating config/botlogin.txt"
    cat << EOF > /mnt/server/config/botlogin.txt
    #PhantomBot Configuration File
    #
    # Here is a list wiht all config values:
    # https://community.phantom.bot/t/settings-for-botlogin-txt/78
    #
    apioauth=
    baseport=
    channel=
    oauth=
    owner=
    panelpassword=
    paneluser=
    user=
    youtubekey=
    discord_token=
EOF
fi
echo "install finished"