UNPKG

@haelp/teto

Version:

A typescript-based controllable TETR.IO client.

1 lines 1.27 kB
{"version":3,"sources":["../../../src/classes/client/types.ts"],"sourcesContent":["import type { Game, User } from \"../../types\";\nimport type { RibbonOptions } from \"../ribbon\";\n\nexport type ClientOptions = (\n | {\n /** The account's JWT authentication token (you can get this from the browser cookies when logging in on https://tetr.io) */\n token: string;\n }\n | {\n /** The account's username */\n username: string;\n /** The accont's password */\n password: string;\n }\n) & {\n /** The client's handling settings.\n * @default { arr: 0, cancel: false, das: 5, dcd: 0, safelock: false, may20g: true, sdf: 41, irs: \"tap\", ihs: \"tap\" }\n */\n handling?: Game.Handling;\n /** The client's user agent.\n * @default \"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/123.0.0.0 Safari/537.36 Edg/123.0.0.0\"\n */\n userAgent?: string;\n /** a cf_clearance Cloudflare turnstile token. */\n turnstile?: string;\n /** The Ribbon (websocket handler) config */\n ribbon?: Partial<RibbonOptions>;\n};\n\nexport interface ClientUser {\n id: string;\n username: string;\n role: User.Role;\n sessionID: string;\n userAgent: string;\n}\n"],"names":[],"mappings":"AA6BA,WAMC"}