Skip to main content
Deno 2 is finally here 🎉️
Learn more
Very Popular
Latest
method Api.prototype.setChatAdministratorCustomTitle
import { Api } from "https://deno.land/x/grammy@v1.30.1/mod.ts";

Use this method to set a custom title for an administrator in a supergroup promoted by the bot. Returns True on success.

Parameters

chat_id: number | string

Unique identifier for the target chat or username of the target supergroup (in the format @supergroupusername)

user_id: number

Unique identifier of the target user

custom_title: string

New custom title for the administrator; 0-16 characters, emoji are not allowed

optional
signal: AbortSignal

Optional AbortSignal to cancel the request

Official reference: https://core.telegram.org/bots/api#setchatadministratorcustomtitle