class ClientPlain
extends ClientAbstract
import { ClientPlain } from "https://deno.land/x/mtkruto@0.6.2/client/1_client_plain.ts";
An MTProto client for making plain connections. Most users won't need to interact with this. Used internally for creating authorization keys.
Constructors
new
ClientPlain(params?: ClientPlainParams)Methods
createAuthKey(): Promise<[Uint8Array, bigint]>
invoke<T extends Api.AnyObject, R = T extends Api.AnyGenericFunction<infer X> ? Api.ReturnType<X> : T["_"] extends keyof Api.Functions ? Api.ReturnType<T> extends never ? Api.ReturnType<Api.Functions[T["_"]]> : never : never>(function_: T): Promise<R>