UsingClient
Signature
export type UsingClient = BaseClient & RegisteredPluginExtension & RegisteredClient;Private types
RegisteredClientTypeAlias
type RegisteredClient = SeyfertRegistry extends { client: infer C;} ? [ C] extends [ { readonly [__seyfertClientType]?: infer T; }] ? [ T] extends [ never] ? BaseClient : unknown extends T ? C extends BaseClient ? C : BaseClient : T & Omit<C, typeof __seyfertClientType> : C extends BaseClient ? C : BaseClient : BaseClient;Properties
37Methods
11Properties
rest: ApiHandler<this>;cache: Cache;applications: ApplicationShorter;users: UsersShorter;channels: ChannelShorter;guilds: GuildShorter;messages: MessageShorter;members: MemberShorter;webhooks: WebhookShorter;templates: TemplateShorter;roles: RoleShorter;reactions: ReactionShorter;emojis: EmojiShorter;threads: ThreadShorter;bans: BanShorter;interactions: InteractionShorter;voiceStates: VoiceStateShorter;soundboards: SoundboardShorter;invites: InvitesShorter;stageInstances: StageInstanceShorter;monetization: MonetizationShorter;debugger?: Logger;logger: Logger;langs: LangsHandler;commands: CommandHandler;components: ComponentHandler;handleCommand: HandleCommand;middlewares?: ClientMiddlewares;readonly plugins: ResolvedPluginList;shared: PluginSharedRegistry;events: CustomEventRunner;options: BaseClientOptions;proxyGetterget proxy(): APIRoutes;botIdSetterset botId(id: string);botIdGetterget botId(): string;applicationIdSetterset applicationId(id: string);applicationIdGetterget applicationId(): string;Methods
setServices({ rest, cache, langs, middlewares, handleCommand }: ServicesOptions): void;start(options?: Pick<DeepPartial<StartOptions>, 'langsDir' | 'commandsDir' | 'connection' | 'token' | 'componentsDir'>): Promise<void>;reloadPluginContributions(): Promise<void>;close(): Promise<void>;Closes resources managed by the plugin lifecycle. This waits for in-flight plugin setup and runs `SeyfertPlugin.teardown`. It does not close the gateway, REST client, or cache adapter.
onInteractionRequest(rawBody: APIInteraction): Promise<{ headers: { 'Content-Type'?: string; }; response: APIInteractionResponse | FormData;}>;Parameters
rawBody- body of interaction
Returns
uploadCommands({ applicationId, cachePath }?: { applicationId?: string; cachePath?: string;}): Promise<void>;loadCommands(dir?: string): Promise<void>;loadComponents(dir?: string): Promise<void>;loadLangs(dir?: string): Promise<void>;t(locale: string): SeyfertLocale;getRC<T extends InternalRuntimeConfigHTTP | InternalRuntimeConfig = InternalRuntimeConfigHTTP | InternalRuntimeConfig>(): Promise<ResolvedRC>;