function randomBotToken
randomBotToken(bot_id?: number): string

Generates a random bot token

Examples

Example 1

import { randomBotToken } from "@izzqz/tgtb/utils";
randomBotToken();
// "1542529915:AAG2lazAfktSdXzKacTXfzU2hmcg99POAZQ"

// with specific bot id
randomBotToken(1234567);
// "1234567:ABC-DEF1234ghIkl-zyx57W2v1u123ew11"

Parameters

optional
bot_id: number
  • The bot ID to use in the token. If not provided, a random ID will be generated.

Return Type

string

A random bot token.

Usage

import { randomBotToken } from "utils";