Skip to main content

Minimal example

Event model

Chameleon uses discriminated union events. In practice, that means each event has a type, and TypeScript narrows correctly inside handlers without extra casting. Example:

Notes

  • debug: true enables framework logging where implemented.
  • client.user becomes available after the ready flow completes.
  • Gateway events are modeled as typed payloads, not mutable runtime entity instances.
  • Managers such as client.messages and client.guilds are the main action surface once the client is running.

Next step

Read Architecture next, because Chameleon’s cache and data model differ from the class-heavy patterns many Discord developers expect.
Last modified on June 13, 2026