Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Module

x/mtkruto/mod.ts>Client#invoke

[WIP] Cross-runtime JavaScript library for building Telegram clients
Go to Latest
method Client.prototype.invoke
import { Client } from "https://deno.land/x/mtkruto@0.0.998/mod.ts";

Invokes a function waiting and returning its reply if the second parameter is not true. Requires the client to be connected.

Type Parameters

optional
T extends (functions.Function<unknown> | types.Type) = functions.Function<unknown>

Parameters

function_: T

The function to invoke.

Returns

Promise<T extends functions.Function<unknown> ? T["__R"] : void>

Type Parameters

optional
T extends (functions.Function<unknown> | types.Type) = functions.Function<unknown>

Parameters

function_: T
noWait: true

Returns

Promise<void>