sendSticker

This commit is contained in:
Er2 2022-02-28 09:40:06 +03:00
parent fefafd4923
commit da0a266b72

14
api.lua
View file

@ -64,6 +64,7 @@ function api:reply(msg, txt, pmod, dwp, rmp, dnot)
end end
function api:forward(cid, frcid, mid, dnot) function api:forward(cid, frcid, mid, dnot)
cid = argp(cid)
return self:request('forwardMessage', { return self:request('forwardMessage', {
chat_id = cid, chat_id = cid,
from_chat_id = frcid, from_chat_id = frcid,
@ -72,6 +73,19 @@ function api:forward(cid, frcid, mid, dnot)
}) })
end end
function api:sendSticker(cid, stk, dnot, rmp, pcon, rtmid, swr)
cid, rmp = argp(cid, rmp)
return self:request('sendSticker', {
chat_id = cid,
sticker = stk,
disable_notification = dnot,
protect_content = pcon,
reply_to_message_id = rtmid,
allow_sending_without_reply = swr,
reply_markup = rmp,
})
end
function api:sendPhoto(cid, f, cap, pmod, dnot, rtmid, rmp) function api:sendPhoto(cid, f, cap, pmod, dnot, rtmid, rmp)
cid, rmp, pmod = argp(cid, rmp, pmod) cid, rmp, pmod = argp(cid, rmp, pmod)
return self:request('sendPhoto', { return self:request('sendPhoto', {