irc-core-2.13: IRC core library for glirc

Copyright | (c) Eric Mertens 2016
License | ISC
Maintainer | emertens@gmail.com
Safe Haskell | None
Language | Haskell2010

Irc.Commands

Contents

- ZNC support
- SASL support

Description

This module provides smart constructors for IRC commands.

Synopsis

- ircAdmin :: Text -> RawIrcMsg
- ircAway :: Text -> RawIrcMsg
- ircCapEnd :: RawIrcMsg
- ircCapLs :: RawIrcMsg
- ircCapReq :: [Text] -> RawIrcMsg
- ircChantrace :: Text -> RawIrcMsg
- ircCnotice :: Text -> Text -> Text -> RawIrcMsg
- ircCprivmsg :: Text -> Text -> Text -> RawIrcMsg
- ircEtrace :: Text -> RawIrcMsg
- ircHelp :: Text -> RawIrcMsg
- ircInfo :: RawIrcMsg
- ircInvite :: Text -> Identifier -> RawIrcMsg
- ircIson :: [Text] -> RawIrcMsg
- ircJoin :: Text -> Maybe Text -> RawIrcMsg
- ircKick :: Identifier -> Text -> Text -> RawIrcMsg
- ircKill :: Text -> Text -> RawIrcMsg
- ircKline :: Text -> Text -> Text -> RawIrcMsg
- ircKnock :: Text -> Text -> RawIrcMsg
- ircLinks :: [Text] -> RawIrcMsg
- ircList :: [Text] -> RawIrcMsg
- ircLusers :: [Text] -> RawIrcMsg
- ircMap :: RawIrcMsg
- ircMasktrace :: Text -> Text -> RawIrcMsg
- ircMode :: Identifier -> [Text] -> RawIrcMsg
- ircMonitor :: [Text] -> RawIrcMsg
- ircMotd :: Text -> RawIrcMsg
- ircNames :: Identifier -> RawIrcMsg
- ircNick :: Text -> RawIrcMsg
- ircNotice :: Text -> Text -> RawIrcMsg
- ircOper :: Text -> Text -> RawIrcMsg
- ircOperwall :: Text -> RawIrcMsg
- ircPart :: Identifier -> Text -> RawIrcMsg
- ircPass :: Text -> RawIrcMsg
- ircPing :: [Text] -> RawIrcMsg
- ircPong :: [Text] -> RawIrcMsg
- ircPrivmsg :: Text -> Text -> RawIrcMsg
- ircQuit :: Text -> RawIrcMsg
- ircRemove :: Identifier -> Text -> Text -> RawIrcMsg
- ircRules :: Text -> RawIrcMsg
- ircStats :: [Text] -> RawIrcMsg
- ircTestline :: Text -> RawIrcMsg
- ircTestmask :: Text -> Text -> RawIrcMsg
- ircTime :: Text -> RawIrcMsg
- ircTopic :: Identifier -> Text -> RawIrcMsg
- ircTrace :: [Text] -> RawIrcMsg
- ircUndline :: Text -> Maybe Text -> RawIrcMsg
- ircUnkline :: Text -> Maybe Text -> RawIrcMsg
- ircUnxline :: Text -> Maybe Text -> RawIrcMsg
- ircUnresv :: Text -> Maybe Text -> RawIrcMsg
- ircUser :: Text -> Text -> RawIrcMsg
- ircUserhost :: [Text] -> RawIrcMsg
- ircUserip :: [Text] -> RawIrcMsg
- ircUsers :: Text -> RawIrcMsg
- ircVersion :: Text -> RawIrcMsg
- ircWallops :: Text -> RawIrcMsg
- ircWho :: [Text] -> RawIrcMsg
- ircWhois :: [Text] -> RawIrcMsg
- ircWhowas :: [Text] -> RawIrcMsg
- ircZnc :: [Text] -> RawIrcMsg
- newtype AuthenticatePayload = AuthenticatePayload ByteString
- ircAuthenticate :: Text -> RawIrcMsg
- ircAuthenticates :: AuthenticatePayload -> [RawIrcMsg]
- encodePlainAuthentication :: Text -> Text -> Text -> AuthenticatePayload
- encodeExternalAuthentication :: Text -> AuthenticatePayload

# Documentation

ircAdmin Source #

Arguments

:: Text | target
-> RawIrcMsg |

ADMIN command

    ADMIN [<target>]

ircAway Source #

Arguments

:: Text | message
-> RawIrcMsg |

AWAY command

ircCapEnd :: RawIrcMsg Source #

CAP END command

ircCapLs :: RawIrcMsg Source #

CAP LS command - support CAP version 3.2

ircCapReq Source #

Arguments

:: [Text] | capabilities
-> RawIrcMsg |

CAP REQ command

ircChantrace Source #

Arguments

:: Text | channel
-> RawIrcMsg |

CHANTRACE command

ircCnotice Source #

Arguments

:: Text | nickname
-> Text | channel
-> Text | message
-> RawIrcMsg |

CNOTICE command

    CNOTICE <nickname> <channel> :<message>

ircCprivmsg Source #

Arguments

:: Text | nickname
-> Text | channel
-> Text | message
-> RawIrcMsg |

CPRIVMSG command

    CPRIVMSG <nickname> <channel> :<message>

ircEtrace Source #

Arguments

:: Text | argument
-> RawIrcMsg |

ETRACE command

ircHelp Source #

Arguments

:: Text | topic
-> RawIrcMsg |

HELP command

ircInfo :: RawIrcMsg Source #

INFO command

ircInvite Source #

Arguments

:: Text | nickname
-> Identifier | channel
-> RawIrcMsg |

INVITE command

ircIson Source #

Arguments

:: [Text] | nicknames
-> RawIrcMsg |

ISON command

ircJoin Source #

Arguments

:: Text | channel
-> Maybe Text | key
-> RawIrcMsg |

JOIN command

ircKick Source #

Arguments

:: Identifier | channel
-> Text | nickname
-> Text | message
-> RawIrcMsg |

KICK command

ircKill Source #

Arguments

:: Text | client
-> Text | message
-> RawIrcMsg |

KILL command

ircKline Source #

Arguments

:: Text | minutes
-> Text | mask
-> Text | reason
-> RawIrcMsg |

KLINE command

ircKnock Source #

Arguments

:: Text | channel
-> Text | message
-> RawIrcMsg |

KNOCK command

    KNOCK <channel> [<message>]

ircLinks Source #

Arguments

:: [Text] | parameters
-> RawIrcMsg |

LINKS command

ircList Source #

Arguments

:: [Text] | parameters
-> RawIrcMsg |

LIST command

ircLusers Source #

Arguments

:: [Text] | params
-> RawIrcMsg |

LUSERS command

    LUSERS [<mask> [<server>]]

ircMap :: RawIrcMsg Source #

MAP command

ircMasktrace Source #

Arguments

:: Text | mask
-> Text | gecos
-> RawIrcMsg |

MASKTRACE command

ircMode Source #

Arguments

:: Identifier | target
-> [Text] | parameters
-> RawIrcMsg |

MODE command

ircMonitor Source #

Arguments

:: [Text] | parameters
-> RawIrcMsg |

ircMotd Source #

Arguments

:: Text | server
-> RawIrcMsg |

MOTD command

    MOTD [<server>]

ircNames Source #

Arguments

:: Identifier | channel
-> RawIrcMsg |

NAMES command

ircNick Source #

Arguments

:: Text | nickname
-> RawIrcMsg |

NICK command

ircNotice Source #

Arguments

:: Text | target
-> Text | message
-> RawIrcMsg |

NOTICE command

ircOper Source #

Arguments

:: Text | username
-> Text | password
-> RawIrcMsg |

OPER command

ircOperwall Source #

Arguments

:: Text | message
-> RawIrcMsg |

OPERWALL command

ircPart Source #

Arguments

:: Identifier | channel
-> Text | message
-> RawIrcMsg |

PART command

ircPass Source #

Arguments

:: Text | password
-> RawIrcMsg |

PASS command

ircPing Source #

Arguments

:: [Text] | parameters
-> RawIrcMsg |

PING command

ircPong Source #

Arguments

:: [Text] | parameters
-> RawIrcMsg |

PONG command

ircPrivmsg Source #

Arguments

:: Text | target
-> Text | message
-> RawIrcMsg |

PRIVMSG command

ircQuit Source #

Arguments

:: Text | quit message
-> RawIrcMsg |

QUIT command

ircRemove Source #

Arguments

:: Identifier | channel
-> Text | nickname
-> Text | message
-> RawIrcMsg |

REMOVE command

ircRules Source #

Arguments

:: Text | servername
-> RawIrcMsg |

RULES command

ircStats Source #

Arguments

:: [Text] | parameters
-> RawIrcMsg |

STATS command

ircTestline Source #

Arguments

:: Text | mask
-> RawIrcMsg |

TESTLINE command

ircTestmask Source #

Arguments

:: Text | mask
-> Text | gecos
-> RawIrcMsg |

TESTMASK command

ircTime Source #

Arguments

:: Text | optional servername
-> RawIrcMsg |

TIME command

ircTopic Source #

Arguments

:: Identifier | channel
-> Text | topic
-> RawIrcMsg |

TOPIC command

ircTrace Source #

Arguments

:: [Text] | params
-> RawIrcMsg |

TRACE command

    TRACE [<target>]

ircUndline Source #

Arguments

:: Text | mask
-> Maybe Text | server
-> RawIrcMsg |

UNDLINE command

ircUnkline Source #

Arguments

:: Text | mask
-> Maybe Text | server
-> RawIrcMsg |

UNKLINE command

ircUnxline Source #

Arguments

:: Text | mask
-> Maybe Text | server
-> RawIrcMsg |

UNXLINE command

ircUnresv Source #

Arguments

:: Text | mask
-> Maybe Text | server
-> RawIrcMsg |

UNRESV command

ircUser Source #

Arguments

:: Text | username
-> Text | realname
-> RawIrcMsg |

USER command

ircUserhost Source #

Arguments

:: [Text] | parameters
-> RawIrcMsg |

USERHOST command

ircUserip Source #

Arguments

:: [Text] | parameters
-> RawIrcMsg |

USERIP command

ircUsers Source #

Arguments

:: Text | optional servername
-> RawIrcMsg |

USERS command

ircVersion Source #

Arguments

:: Text | server
-> RawIrcMsg |

VERSION command

ircWallops Source #

Arguments

:: Text | message
-> RawIrcMsg |

WALLOPS command

ircWho Source #

Arguments

:: [Text] | parameters
-> RawIrcMsg |

WHO command

ircWhois Source #

Arguments

:: [Text] | parameters
-> RawIrcMsg |

WHOIS command

ircWhowas Source #

Arguments

:: [Text] | parameters
-> RawIrcMsg |

WHOWAS command

# ZNC support

ircZnc Source #

Arguments

:: [Text] | parameters
-> RawIrcMsg |

ZNC command

specific to ZNC

# SASL support

newtype AuthenticatePayload Source #

Payload for `ircAuthenticates`

Constructors

AuthenticatePayload ByteString |

#### Instances

Instances details

Show AuthenticatePayload Source # |
Instance details Defined in Irc.Commands Methods showsPrec :: Int -> AuthenticatePayload -> ShowS Source # show :: AuthenticatePayload -> String Source # showList :: [AuthenticatePayload] -> ShowS Source #

ircAuthenticate Source #

Arguments

:: Text | authentication mechanism
-> RawIrcMsg |

ircAuthenticates Source #

Arguments

:: AuthenticatePayload | authentication payload
-> [RawIrcMsg] |

AUTHENTICATE command generator. Returns a list because AUTHENTICATE has a chunking behavior.

encodePlainAuthentication Source #

Arguments

:: Text | authorization identity
-> Text | authentication identity
-> Text | password
-> AuthenticatePayload |

Encoding of username and password in PLAIN authentication

encodeExternalAuthentication Source #

Arguments

:: Text | authorization identity
-> AuthenticatePayload |

Encoding of username in EXTERNAL authentication