Module

x/grammy/mod.ts>Transformer

The Telegram Bot Framework.
Very Popular
Go to Latest
type alias Transformer
import { type Transformer } from "https://dotland.deno.dev/x/grammy@v1.18.3/mod.ts";

API call transformers are functions that can access and modify the method and payload of an API call on the fly. This can be useful if you want to implement rate limiting or other things against the Telegram Bot API.

Confer the grammY documentation to read more about how to use transformers.

Type Parameters

optional
R extends RawApi = RawApi
definition: <M extends Methods<R>>(
prev: ApiCallFn<R>,
method: M,
payload: Payload<M, R>,
signal?: AbortSignal,
) => Promise<ApiResponse<ApiCallResult<M, R>>>