Start, stop and restart
The dashboard buttons were real controls, not decoration. Clicking one sent the matching power signal through the Pterodactyl API.
ARCHIVED CONTRIBUTION · LAST TOUCHED FEB 2026
This was an existing Go bot codebase I worked on and extended. The idea was simple: game-server admins already live in Discord, so the useful Pterodactyl controls and status information should be there too.
The main reason I built on it
This was probably the part I spent the most time on. I did not just want Discord to mirror the Pterodactyl status page. The useful bit was being able to handle normal server admin stuff without opening the panel at all.
The interactive dashboard posted one card per server. From there you could start, stop, restart or refresh a server with buttons. Slash commands handled console commands and backups, and server-name autocomplete meant you did not have to remember IDs.
The dashboard buttons were real controls, not decoration. Clicking one sent the matching power signal through the Pterodactyl API.
/pt send could pass a console command straight to the selected server, which was handy for saves or admin commands.
/pt backup created a Pterodactyl backup without needing to open the panel first.
Under the hood
The actual control row in the bot looked roughly like this. Each button carried the action and server ID in its custom ID, then the interaction handler passed that through to the Pterodactyl power endpoint.
discordgo.Button{
Label: "Start",
Style: discordgo.SuccessButton,
CustomID: fmt.Sprintf("ptbot:power:start:%s:%s", ctx, id),
},
discordgo.Button{
Label: "Stop",
Style: discordgo.DangerButton,
CustomID: fmt.Sprintf("ptbot:power:stop:%s:%s", ctx, id),
},
discordgo.Button{
Label: "Restart",
Style: discordgo.PrimaryButton,
CustomID: fmt.Sprintf("ptbot:power:restart:%s:%s", ctx, id),
}
The same project also exposed /pt start, /pt stop, /pt restart, /pt send and /pt backup as slash commands.
Status boards
The bot could keep auto-updating status boards in Discord, so people did not need to open Pterodactyl just to check whether a server was online or how it had been behaving.
The bits I still like
CPU, RAM and network samples were stored for the last hour and rendered as small trend lines directly in Discord status cards.
The bot watched Steam build IDs, confirmed changes before alerting and could schedule restart flows for servers matching a Pterodactyl egg.
Scheduled restarts could post countdown warnings, perform restart or stop/start flows and then watch until the target servers were running again.
Users could optionally store their own Pterodactyl API key so the bot used their panel permissions. Those tokens were encrypted at rest.
Why it is here
The last changes were in February 2026. I do not work on this repo anymore, but the server-status, Steam-watch and restart pieces are still the kind of practical automation I enjoy building.