Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/grammy/mod.ts>Api#replaceStickerInSet

The Telegram Bot Framework.
Very Popular
Latest
method Api.prototype.replaceStickerInSet
import { Api } from "https://deno.land/x/grammy@v1.31.0/mod.ts";

Use this method to replace an existing sticker in a sticker set with a new one. The method is equivalent to calling deleteStickerFromSet, then addStickerToSet, then setStickerPositionInSet. Returns True on success.

Parameters

user_id: number

User identifier of the sticker set owner

name: string

Sticker set name

old_sticker: string

File identifier of the replaced sticker

sticker: InputSticker

An object with information about the added sticker. If exactly the same sticker had already been added to the set, then the set remains unchanged.:x

optional
signal: AbortSignal

Optional AbortSignal to cancel the request

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