buape/carbon — reverse-engineered prompt

Reverse engineered prompt

Build me a TypeScript library for making Discord bots that feels easy to start with but can grow into something more serious. I want it to focus on HTTP interactions first, so people can build slash commands, user and message commands, buttons, select menus, and modals in one clean system, then optionally add gateway features later without rewriting everything.

It should work across normal server runtimes and fetch style runtimes, like Node, Bun, Cloudflare Workers, and Next.js. Please make it strongly typed, plugin friendly, and good for reusable command classes, auto registering components, simple custom ID parsing, waiting for a single component response, prechecks, wildcard handlers, and hosting more than one Discord app from one deployment.

Include optional caching with memory and Redis style storage, plus examples or demo apps for at least a Node setup and a Workers setup. A small docs site would be great too. Keep it polished and production ready, and look up current Discord interaction docs online if you need to.

Want more depth? Deep Reverse