StaticGramBot API

setStickerPositionInSetПоддерживается

Use this method to move a sticker in a set created by the bot to a specific position. Returns True on success.

Параметры

stickerStringобязательный
File identifier of the sticker
positionIntegerобязательный
New sticker position in the set, zero-based

Пример запроса

curl
curl "https://api.staticgram.top/bot$TOKEN/setStickerPositionInSet" \
  -H "Content-Type: application/json" \
  -d '{
    "sticker": "CAACAgIAAxkBAA...",
    "position": 1
  }'
aiogram 3
from aiogram import Bot
from aiogram.client.session.aiohttp import AiohttpSession
from aiogram.client.telegram import TelegramAPIServer

session = AiohttpSession(api=TelegramAPIServer.from_base("https://api.staticgram.top"))
bot = Bot(TOKEN, session=session)

result = await bot.set_sticker_position_in_set(sticker="CAACAgIAAxkBAA...", position=1)
JavaScript
const res = await fetch(`https://api.staticgram.top/bot${TOKEN}/setStickerPositionInSet`, {
  method: "POST",
  headers: { "Content-Type": "application/json" },
  body: JSON.stringify({
    "sticker": "CAACAgIAAxkBAA...",
    "position": 1
  }),
});
const data = await res.json();

Ответ (True)

JSON
{
  "ok": true,
  "result": true
}

Описания методов и типов взяты из официальной документации Telegram Bot API (Bot API 10.3). Адрес API: https://api.staticgram.top