telegram-bot-api-7.0: Easy to use library for building Telegram bots. Exports Telegram Bot API.
Safe HaskellSafe-Inferred
LanguageHaskell2010

Telegram.Bot.API.Stickers

Synopsis

Documentation

data StickerType Source #

Type of uploaded sticker file. Static or animated.

Constructors

PngSticker

PNG image with the sticker, must be up to 512 kilobytes in size, dimensions must not exceed 512px, and either width or height must be exactly 512px. Pass a file_id as a String to send a file that already exists on the Telegram servers, pass an HTTP URL as a String for Telegram to get a file from the Internet, or upload a new one using multipart/form-data.

TgsSticker

TGS animation with the sticker, uploaded using multipart/form-data. See https://core.telegram.org/animated_stickers#technical-requirements for technical requirements.

WebmSticker

WEBM video with the sticker, uploaded using multipart/form-data. See https://core.telegram.org/stickers#video-sticker-requirements for technical requirements.

data StickerFile Source #

Sticker file with static/animated label.

sendSticker

data SendStickerRequest Source #

Request parameters for sendSticker.

Constructors

SendStickerRequest 

Fields

Instances

Instances details
ToJSON SendStickerRequest Source # 
Instance details

Defined in Telegram.Bot.API.Stickers

Generic SendStickerRequest Source # 
Instance details

Defined in Telegram.Bot.API.Stickers

Associated Types

type Rep SendStickerRequest :: Type -> Type #

ToMultipart Tmp SendStickerRequest Source # 
Instance details

Defined in Telegram.Bot.API.Stickers

type Rep SendStickerRequest Source # 
Instance details

Defined in Telegram.Bot.API.Stickers

type Rep SendStickerRequest = D1 ('MetaData "SendStickerRequest" "Telegram.Bot.API.Stickers" "telegram-bot-api-7.0-2XShkJeCLX71W7OKNKemWZ" 'False) (C1 ('MetaCons "SendStickerRequest" 'PrefixI 'True) (((S1 ('MetaSel ('Just "sendStickerChatId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 SomeChatId) :*: S1 ('MetaSel ('Just "sendStickerMessageThreadId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe MessageThreadId))) :*: (S1 ('MetaSel ('Just "sendStickerEmoji") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "sendStickerSticker") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 InputFile))) :*: ((S1 ('MetaSel ('Just "sendStickerDisableNotification") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe Bool)) :*: S1 ('MetaSel ('Just "sendStickerProtectContent") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe Bool))) :*: (S1 ('MetaSel ('Just "sendStickerReplyToMessageId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe MessageId)) :*: (S1 ('MetaSel ('Just "sendStickerReplyParameters") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe ReplyParameters)) :*: S1 ('MetaSel ('Just "sendStickerReplyMarkup") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe InlineKeyboardMarkup)))))))

sendSticker :: SendStickerRequest -> ClientM (Response Message) Source #

Use this method to send static .WEBP or animated .TGS stickers. On success, the sent Message is returned.

getCustomEmojiStickers

data GetCustomEmojiStickersRequest Source #

Request parameters for getCustomEmojiStickers.

Constructors

GetCustomEmojiStickersRequest 

Fields

uploadStickerFile

data UploadStickerFileRequest Source #

Request parameters for uploadStickerFile.

Constructors

UploadStickerFileRequest 

Fields

Instances

Instances details
ToJSON UploadStickerFileRequest Source # 
Instance details

Defined in Telegram.Bot.API.Stickers

Generic UploadStickerFileRequest Source # 
Instance details

Defined in Telegram.Bot.API.Stickers

Associated Types

type Rep UploadStickerFileRequest :: Type -> Type #

ToMultipart Tmp UploadStickerFileRequest Source # 
Instance details

Defined in Telegram.Bot.API.Stickers

type Rep UploadStickerFileRequest Source # 
Instance details

Defined in Telegram.Bot.API.Stickers

type Rep UploadStickerFileRequest = D1 ('MetaData "UploadStickerFileRequest" "Telegram.Bot.API.Stickers" "telegram-bot-api-7.0-2XShkJeCLX71W7OKNKemWZ" 'False) (C1 ('MetaCons "UploadStickerFileRequest" 'PrefixI 'True) (S1 ('MetaSel ('Just "uploadStickerFileUserId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 UserId) :*: (S1 ('MetaSel ('Just "uploadStickerFileSticker") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 InputFile) :*: S1 ('MetaSel ('Just "uploadStickerFileStickerFormat") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text))))

uploadStickerFile :: UploadStickerFileRequest -> ClientM (Response File) Source #

Use this method to upload f file in .WEBP, .PNG, .TGS, or .WEBM format with a sticker for later use in createNewStickerSet and addStickerToSet methods (can be used multiple times). Returns the uploaded File on success.

createNewStickerSet

data CreateNewStickerSetRequest Source #

Request parameters for createNewStickerSet.

Constructors

CreateNewStickerSetRequest 

Fields

Instances

Instances details
ToJSON CreateNewStickerSetRequest Source # 
Instance details

Defined in Telegram.Bot.API.Stickers

Generic CreateNewStickerSetRequest Source # 
Instance details

Defined in Telegram.Bot.API.Stickers

Associated Types

type Rep CreateNewStickerSetRequest :: Type -> Type #

type Rep CreateNewStickerSetRequest Source # 
Instance details

Defined in Telegram.Bot.API.Stickers

type Rep CreateNewStickerSetRequest = D1 ('MetaData "CreateNewStickerSetRequest" "Telegram.Bot.API.Stickers" "telegram-bot-api-7.0-2XShkJeCLX71W7OKNKemWZ" 'False) (C1 ('MetaCons "CreateNewStickerSetRequest" 'PrefixI 'True) ((S1 ('MetaSel ('Just "createNewStickerSetUserId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 UserId) :*: (S1 ('MetaSel ('Just "createNewStickerSetName") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text) :*: S1 ('MetaSel ('Just "createNewStickerSetTitle") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text))) :*: ((S1 ('MetaSel ('Just "createNewStickerSetStickers") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 [InputSticker]) :*: S1 ('MetaSel ('Just "createNewStickerFormat") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text)) :*: (S1 ('MetaSel ('Just "createNewStickerSetType") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe StickerSetType)) :*: S1 ('MetaSel ('Just "createNewStickerSetNeedsRepainting") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe Bool))))))

createNewStickerSet :: CreateNewStickerSetRequest -> ClientM (Response Bool) Source #

Use this method to create a new sticker set owned by a user. The bot will be able to edit the sticker set thus created. You must use exactly one of the fields png_sticker or tgs_sticker. Returns True on success.

addStickerToSet

data AddStickerToSetRequest Source #

Request parameters for addStickerToSet.

Constructors

AddStickerToSetRequest 

Fields

Instances

Instances details
ToJSON AddStickerToSetRequest Source # 
Instance details

Defined in Telegram.Bot.API.Stickers

Generic AddStickerToSetRequest Source # 
Instance details

Defined in Telegram.Bot.API.Stickers

Associated Types

type Rep AddStickerToSetRequest :: Type -> Type #

type Rep AddStickerToSetRequest Source # 
Instance details

Defined in Telegram.Bot.API.Stickers

type Rep AddStickerToSetRequest = D1 ('MetaData "AddStickerToSetRequest" "Telegram.Bot.API.Stickers" "telegram-bot-api-7.0-2XShkJeCLX71W7OKNKemWZ" 'False) (C1 ('MetaCons "AddStickerToSetRequest" 'PrefixI 'True) (S1 ('MetaSel ('Just "addStickerToSetUserId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 UserId) :*: (S1 ('MetaSel ('Just "addStickerToSetName") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text) :*: S1 ('MetaSel ('Just "addStickerToSetStickers") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 InputSticker))))

addStickerToSet :: AddStickerToSetRequest -> ClientM (Response Bool) Source #

Use this method to add a new sticker to a set created by the bot. You must use exactly one of the fields png_sticker or tgs_sticker. Animated stickers can be added to animated sticker sets and only to them. Animated sticker sets can have up to 50 stickers. Static sticker sets can have up to 120 stickers. Returns True on success.

getStickerSet

getStickerSet Source #

Arguments

:: Text

Name of the sticker set

-> ClientM (Response StickerSet) 

Use this method to get a sticker set. On success, a StickerSet object is returned.

setStickerPositionInSet

type SetStickerPositionInSet = "setStickerPositionInSet" :> (RequiredQueryParam "sticker" Text :> (RequiredQueryParam "position" Integer :> Post '[JSON] (Response Bool))) Source #

setStickerPositionInSet Source #

Arguments

:: Text

File identifier of the sticker

-> Integer

New sticker position in the set, zero-based

-> ClientM (Response Bool) 

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

deleteStickerFromSet

type DeleteStickerFromSet = "deleteStickerFromSet" :> (RequiredQueryParam "sticker" Text :> Post '[JSON] (Response Bool)) Source #

deleteStickerFromSet Source #

Arguments

:: Text

File identifier of the sticker

-> ClientM (Response Bool) 

Use this method to delete a sticker from a set created by the bot. Returns True on success.

setStickerSetThumbnail

data SetStickerSetThumbnailRequest Source #

Request parameters for setStickerSetThumbnail.

Constructors

SetStickerSetThumbnailRequest 

Fields

Instances

Instances details
ToJSON SetStickerSetThumbnailRequest Source # 
Instance details

Defined in Telegram.Bot.API.Stickers

Generic SetStickerSetThumbnailRequest Source # 
Instance details

Defined in Telegram.Bot.API.Stickers

Associated Types

type Rep SetStickerSetThumbnailRequest :: Type -> Type #

ToMultipart Tmp SetStickerSetThumbnailRequest Source # 
Instance details

Defined in Telegram.Bot.API.Stickers

type Rep SetStickerSetThumbnailRequest Source # 
Instance details

Defined in Telegram.Bot.API.Stickers

type Rep SetStickerSetThumbnailRequest = D1 ('MetaData "SetStickerSetThumbnailRequest" "Telegram.Bot.API.Stickers" "telegram-bot-api-7.0-2XShkJeCLX71W7OKNKemWZ" 'False) (C1 ('MetaCons "SetStickerSetThumbnailRequest" 'PrefixI 'True) (S1 ('MetaSel ('Just "setStickerSetThumbnailName") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text) :*: (S1 ('MetaSel ('Just "setStickerSetThumbnailUserId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 UserId) :*: S1 ('MetaSel ('Just "setStickerSetThumbnailThumbnail") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 InputFile))))

setStickerSetThumbnail :: SetStickerSetThumbnailRequest -> ClientM (Response Bool) Source #

Use this method to set the thumbnail of a sticker set. Animated thumbnails can be set for animated sticker sets only. Returns True on success.