Skip to content

CustomEvents

Defined in: packages/core/dist/index.d.ts:386

Register your custom events here for typed track() calls. Name the Shardlens package your bot installs (@shardlens/discordjs or @shardlens/http): with pnpm, a bot can’t see @shardlens/core itself.

declare module '@shardlens/discordjs' {
interface CustomEvents {
ticket_opened: { category: 'billing' | 'support' };
}
}
lens.track('ticket_opened', { category: 'billing' });