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

Telegram.Bot.API.Methods.RestrictChatMember

Synopsis

restrictChatMember

data RestrictChatMemberRequest Source #

Request parameters for restrictChatMember.

Constructors

RestrictChatMemberRequest 

Fields

Instances

Instances details
FromJSON RestrictChatMemberRequest Source # 
Instance details

Defined in Telegram.Bot.API.Methods.RestrictChatMember

ToJSON RestrictChatMemberRequest Source # 
Instance details

Defined in Telegram.Bot.API.Methods.RestrictChatMember

Generic RestrictChatMemberRequest Source # 
Instance details

Defined in Telegram.Bot.API.Methods.RestrictChatMember

Associated Types

type Rep RestrictChatMemberRequest :: Type -> Type #

type Rep RestrictChatMemberRequest Source # 
Instance details

Defined in Telegram.Bot.API.Methods.RestrictChatMember

type Rep RestrictChatMemberRequest = D1 ('MetaData "RestrictChatMemberRequest" "Telegram.Bot.API.Methods.RestrictChatMember" "telegram-bot-api-6.5-3pY7XQZ5v9zCuyh8HdDMyB" 'False) (C1 ('MetaCons "RestrictChatMemberRequest" 'PrefixI 'True) ((S1 ('MetaSel ('Just "restrictChatMemberChatId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 SomeChatId) :*: S1 ('MetaSel ('Just "restrictChatMemberUserId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 UserId)) :*: (S1 ('MetaSel ('Just "restrictChatMemberPermissions") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 ChatPermissions) :*: (S1 ('MetaSel ('Just "restrictChatMemberUseIndependentChatPermissions") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe Bool)) :*: S1 ('MetaSel ('Just "restrictChatMemberUntilDate") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (Maybe Int))))))

restrictChatMember :: RestrictChatMemberRequest -> ClientM (Response Bool) Source #

Use this method to restrict a user in a supergroup. The bot must be an administrator in the supergroup for this to work and must have the appropriate administrator rights. Pass True for all permissions to lift restrictions from a user. Returns True on success.