Invoke

Invoke

Requesting function using raw api.
Raw api is a function constructor which is declared in the telegram schema.

Usage

import { Raw } from 'tgsnake'; // '@tgsnake/core'
 
client.api.invoke(query, retries, timeout, sleepTreshold);
namerequiredtypedescription
queryYesObjectConstructor (object) which will be sent to the Telegram server.
retriesNoIntegerIf the function fails, how many attempts should it run.
timeoutNoIntegerThe maximum time limit for running the query function.
sleepTresholdNoIntegerPause sleep time if a flood occurs.

Not all classes contained in Raw Api can be executed, only classes that are functions can be executed. See »

Reference