Member visibility
Filter class members by access level.
Seedcord(config: GatewayConfig)configBot configuration including paths and Discord client options
Throws:
A SeedcordError When attempting to create multiple instances (singleton)
Showing members with Protected visibility and higher.
public get applicationId(): stringpublic readonly config: GatewayConfigisInitialized
plugins
protected readonly plugins: PluginLike[]Inherited from:Pluggable
public readonly rateLimiter: IRateLimiterSee also:IRateLimiter
public readonly rest: RESTshutdown
Add a task that runs while the bot shuts down.
readonly shutdown: Pick<CoordinatedShutdown, 'addTask'>Inherited from:Pluggable
startFailed
startup
Add a task that runs while the bot starts.
readonly startup: Pick<CoordinatedStartup, 'addTask'>Inherited from:Pluggable
attach()
Attaches a plugin under key. Read the instance back as core[key]. seedcord codegen writes the Core augmentation that types it there.
Startup runs each plugin's init() in attach order within its phase.
Attaching a plugin whose transport or runtime differs from this host fails to compile. Your constructor takes CoreBase as its first parameter (you don't need to pass it though). A narrower one fails to compile here.
attach<Key, Ctor>(
this: this,
key: ChannelKeyAssert<Key>,
Plugin: Ctor &
TransportAssert<InstanceType<Ctor>, BotT> &
RuntimeAssert<InstanceType<Ctor>, BotRt> &
CoreParamAssert<Ctor>,
args: PluginArgs<Ctor>
): this & Record<Key, InstanceType<Ctor>>keyAlso the channel the plugin logs on. Reserved channel names throw.
argsWhatever your constructor takes after the host.
Throws:
A SeedcordError if you attach after the bot has started. A taken or reserved key throws too.
Inherited from:Pluggable
public async start(): Promise<this>