diff --git a/src/module/client.ts b/src/module/client.ts index 53dbcf843..aff72d6cf 100644 --- a/src/module/client.ts +++ b/src/module/client.ts @@ -35,7 +35,7 @@ export interface IdentifyPayload { shard: [number, number]; } -export const createClient = async (data: ClientOptions) => { +export async function createClient(data: ClientOptions) { if (data.eventHandlers) eventHandlers = data.eventHandlers; authorization = `Bot ${data.token}`; diff --git a/src/module/hugebot.ts b/src/module/hugebot.ts new file mode 100644 index 000000000..8acddedb7 --- /dev/null +++ b/src/module/hugebot.ts @@ -0,0 +1,20 @@ +import { ClientOptions } from "../types/options.ts"; + +/** + * This function should be used only by bot developers whose bots are in over 25,000 servers. + * Please be aware if you are a beginner developer using this, things will not work as per the guides. This is for advanced developers only! + * + * Advanced Devs: This function will allow you to have an insane amount of customization potential as when you get to large bots you need to be able to optimize every tiny detail to make you bot work the way you need. +*/ +export async function startHugeBot(data: HugeBotOptions) { + +} + +export interface HugeBotOptions extends ClientOptions { + /** This can be used to distribute your bot across different servers. For example, if you wanted 1 million shards per server you could control it using this. */ + shards: [number, number]; + /** This can be used to forward the ws handling to a proxy. */ + wsURL?: string; + /** This can be used to forward the REST handling to a proxy. */ + restURL?: string; +} diff --git a/src/types/options.ts b/src/types/options.ts index 641432ada..1b8d20fa0 100644 --- a/src/types/options.ts +++ b/src/types/options.ts @@ -31,6 +31,7 @@ export interface Fulfilled_Client_Options { export interface ClientOptions { token: string; + /** @deprecated Will be removed in next major version! */ properties?: Properties; compress?: boolean; intents: Intents[];