How astromni/discord-stylebot works
AutoPlate is a small event-driven Discord bot: it reads a bot token and fixed style settings, connects directly to Discord’s Gateway, and applies the configured nameplate to itself after a guild-create event. The runtime and its distinct protocol, event, and REST responsibilities all live in index.js; the graph separates them to show the workflow. The source excerpt supports these calls and transfers; setup and style options are documented in the README.
Main entry points: index.js Gateway connection · config.json Bot token
Components 10
Configuration
- Bot token
config.json - Style settings
index.js
Bot runtime
- Gateway connection
index.js - Identify and heartbeat
index.js - Gateway event handler
index.js - Join delay
index.js - Nameplate update
index.js
Discord services
- Discord Gateway
- Discord API
Other components
- Bot operator
Connections 10
- Bot operator → Bot token: sets token
README.md - Bot token → Gateway connection: provides credentials
index.js - Style settings → Nameplate update: configures update
index.js - Gateway connection → Discord Gateway: opens WebSocket
index.js - Discord Gateway → Gateway event handler: delivers events
index.js - Gateway connection → Identify and heartbeat: handles opcodes
index.js - Identify and heartbeat → Discord Gateway: identifies and heartbeats
index.js - Gateway event handler → Join delay: schedules on join
index.js - Join delay → Nameplate update: invokes after delay
index.js - Nameplate update → Discord API: PATCHes member
index.js