Skip to main content

Introduction

ForgeLoop is a maintenance-first scaffolder for discord.js bots. It generates a working TypeScript or JavaScript project, keeps a project manifest on disk (forgeloop.config.mjs), and ships commands to add/remove handlers, validate project health, inspect commands, and deploy application command definitions to Discord.

What you get

  • Interactive or scripted init — pick language, preset, package manager, optional Prisma database, lint/format stack, Git, Docker, and GitHub Actions CI.
  • Three presetsbasic (inline bot), modular (handler folders + sync on startup), advanced (core runtime modules under src/core).
  • Generatorsadd supports slash commands, context menus, events, modals, buttons, and select menus for modular/advanced projects.
  • Removalremove deletes generated command/event/interaction handlers.
  • Health checksdoctor runs grouped diagnostics (files, env, dependencies, command load checks) with optional --json and --strict.
  • Application command toolingcommands list inspects local payload names, commands diff compares local vs remote state, and commands deploy syncs with Discord.

Two ways to run the same CLI

The npm package create-forgeloop exposes two binaries:

BinaryTypical use
create-forgeloopnpm create forgeloop@latest, pnpm create forgeloop, etc. Bare arguments are treated as init (e.g. project name).
forgeloopInside a generated project: npx forgeloop …, pnpm forgeloop …, yarn forgeloop …

If the first argument to create-forgeloop is already a known command (init, add, commands, remove, doctor, info, docs, help), it is passed through unchanged.

What ForgeLoop is not

  • Not a hosted bot platform — you run Node and own deployment.
  • Not a replacement for discord.js docs — it standardizes structure and boilerplate, not Discord API teaching.

Next steps

  1. Install — Node version and package managers.
  2. Quickstart — scaffold and run in a few commands.
  3. Concepts — manifest, presets, and when generators apply.