Skip to content

Repository files navigation

banner

the all-in-one wiki bot

Add to server

Setup

Requirements

Installation

  1. Clone the repository and enter its directory:

    git clone https://github.com/utgwiki/derik.git
    cd derik
  2. Install the dependencies:

    npm install
  3. Create your environment file from the example:

    cp .env.example .env
  4. Open .env and replace your_discord_token_here with the bot token from the Discord Developer Portal. The web server uses port 3000 by default; set PORT to a different value if needed.

  5. Start the bot:

    npm start

Configuration

Most bot behavior is configured in config.js. Restart the bot after making changes.

  • WIKIS — Define the wikis supported by the bot. Each entry contains the wiki name, MediaWiki API endpoint, article URL, message prefix, and emoji.
  • WIKI_MAP — Map Discord channel or category IDs to a wiki. This controls which wiki is used when a message does not include a wiki prefix.
  • STATUS_OPTIONS — Customize the bot’s rotating Discord status messages and activity types.
  • STATUS_INTERVAL_MS — Set how often the bot rotates its status. The default is five minutes.
  • COMMANDS — Enable or disable individual slash commands. Set a command to false to prevent it from being registered with Discord. Available commands are speedrun, contribs, wiki, parse, user, and random.
  • SPEEDRUN_EMOJI and CONTRIBSCORES_SCORE_EMOJI — Set the custom emoji IDs used by those features.

When adding a wiki, add its configuration to WIKIS and update WIKI_MAP or the relevant status messages as needed. Discord channel, category, and emoji IDs can be copied using Discord’s Developer Mode.

Web server and Instatus

bot/server.js starts a small web server so Instatus can check whether the bot is active. It listens on 0.0.0.0 and uses the PORT value from .env (or port 3000 when it is unset). The file is part of the bot’s normal startup through index.js; it can be removed if Instatus monitoring is not needed, provided the corresponding require("./bot/server") line is also removed from index.js.

About

discord wiki bot utilising components v2 & additional features; fork of conecorpwiki/wikiguy

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Contributors

Languages