campfire-0.0.1: Haskell implementation of the Campfire API

Portabilityportable
Stabilityprovisional
MaintainerMichael Xavier <michael@michaelxavier.net>

Web.Campfire.Types

Description

 

Synopsis

Documentation

data Room Source

A chat room on a Campfire site

Constructors

Room 

Fields

roomId :: Id
 
roomName :: Text
 
roomTopic :: Maybe Text

Room topic if available

roomMembershipLimit :: Integer

Maximum number of users that may be in this room

roomFull :: Maybe Bool

May not be present depending on the API call used

roomOpenToGuests :: Maybe Bool

May not be present depending on the API call used

roomActiveTokenValue :: Maybe Text

Campfire API doesn't really specify what this means

roomUpdatedAt :: CampfireTime
 
roomCreatedAt :: CampfireTime
 
roomUsers :: Maybe [User]
 

newtype RoomWithRoot Source

Utility type used for extracting a Room from the root JSON object the Campfire API returns

Constructors

RoomWithRoot 

Fields

unRootRoom :: Room
 

newtype Rooms Source

Utility type used for extracting a Room from the list returned by the Campfire API

Constructors

Rooms 

Fields

unRooms :: [Room]
 

newtype Messages Source

Utility type used for extracting a Message from the list returned by the Campfire API

Constructors

Messages 

Fields

unMessages :: [Message]
 

data MessageType Source

Distinct types of messages which can be found in Campfire

Constructors

TextMessage 
PasteMessage

Monospaced text displayed in block form

SoundMessage

Audio sound effect message

AdvertisementMessage 
AllowGuestsMessage 
DisallowGuestsMessage 
IdleMessage 
KickMessage

Message indicating that a user was kicked out

LeaveMessage 
SystemMessage 
TimestampMessage 
TopicChangeMessage 
UnidleMessage 
UnlockMessage 
UploadMessage 
EnterMessage 

data Statement Source

Statements are messages that you can send to CampFire.

Constructors

TextStatement 

Fields

statementBody :: Text
 
PasteStatement 

Fields

statementBody :: Text
 
SoundStatement

Play an audio message in the room

Fields

soundType :: Sound
 
TweetStatement

Display a tweet from a url on Twitter

Fields

statementUrl :: Text
 

data Sound Source

Different pre-set sounds that can be played in a room.

Constructors

Rimshot 
Crickets 
Trombone 

data User Source

User which can be found in any number of rooms.

Constructors

User 

Fields

userId :: Id
 
userName :: Text
 
userEmailAddress :: Text
 
userAdmin :: Bool

User has administrative privileges

userCreatedAt :: CampfireTime
 
userType :: UserType
 

newtype UserWithRoot Source

Utility type used for extracting a User from the root JSON object the Campfire API returns

Constructors

UserWithRoot 

Fields

unRootUser :: User
 

data UserType Source

Different classes of users that can be found in chat.

Constructors

Member 
Guest 

newtype Uploads Source

Utility type used for extracting a Upload from the list returned by the Campfire API

Constructors

Uploads 

Fields

unUploads :: [Upload]
 

newtype UploadWithRoot Source

Utility type used for extracting an Upload from the root JSON object the Campfire API returns

Constructors

UploadWithRoot 

Fields

unRootUpload :: Upload
 

newtype CampfireTime Source

Utility type to normalize the non-standard date format that the Campfire API returns

Constructors

CampfireTime