Skip to content

@bight-ts/plugin-devtools

import {
createDevtoolsPlugin,
type DevtoolsPluginOptions,
} from "@bight-ts/plugin-devtools";

Registers an in-Discord diagnostics command with three subcommands: status, events, and reports.

PropertyTypeDefaultDescription
commandNamestring"bight-devtools"Name of the registered slash command
devOnlybooleantrueBlock the command in production environments
preconditionsstring[]Preconditions applied to the devtools command
recentEventLimitnumber10Max events shown in the /events subcommand
logStartupSnapshotbooleantrue in developmentLog a diagnostics snapshot after login
includeCommandbooleantrueWhether to register the slash command at all
enabledbooleantrueToggle the entire plugin
namestring"devtools"Plugin name for diagnostics
loggerScopestring"devtools"Logger scope
SubcommandDescription
statusRuntime summary: bot tag, command/handler counts, loaded plugins
eventsRecent diagnostic events (denials, errors, task results)
reportsStructured snapshot from all registered diagnostic sources