/slackbot

Slackbot in Haskell

Primary LanguageHaskellBSD 3-Clause "New" or "Revised" LicenseBSD-3-Clause

BSD3 License

slackbot

A bot for Slack. Easy way to add new commands for slack channels.

Uses slack-api for Slack RTM API.

Installation

Use stack to install the packages and build the project.

Commands

Check out existing commands in SlackBot.Commands. For new commands please create a PR.

Commands must have public function cmd :: Command.

data Command = Command
    { cName :: Text
    , cDesc :: Text
    , cFunc :: Text -> IO Text
    }
Attr Meaning
name Name of the command. Will be used in Slack like this: !name blabla
desc Description will be shown by the help command.
func Function of the command.