SlackEvent

rawEvent

Underlying raw event from Slack.

Example:

event.rawEvent;
// {
//   type: 'message',
//   channel: 'C2147483705',
//   user: 'U2147483697',
//   text: 'Hello world',
//   ts: '1355517523.000005',
// }

isMessage

Determine if the event is a message event.

Example:

event.isMessage; // true

isChannelsMessage

Determine if the event is a message event sent from channels.

Example:

event.isChannelsMessage; // true

isGroupsMessage

Determine if the event is a message event sent from groups.

Example:

event.isGroupsMessage; // true

isImMessage

Determine if the event is a message event sent from instant messaging.

Example:

event.isImMessage; // true

isMpimMessage

Determine if the event is a message event sent from multiple people instant messaging.

Example:

event.isMpimMessage; // true

message

The message object from Slack raw event.

Example:

event.message;
// {
//   type: 'message',
//   channel: 'C2147483705',
//   user: 'U2147483697',
//   text: 'Hello world',
//   ts: '1355517523.000005',
// }

isText

Determine if the event is a message event which includes text.

Example:

event.isText; // true

text

The text string from Slack raw event.

Example:

event.text; // 'Hello world'

isInteractiveMessage

Determine if the event is a interactive message (button/menu) event.

Example:

event.isInteractiveMessage; // true

callbackId

The callback_id from Slack interactive message.

Example:

event.callbackId; // 'wopr_game'

action

The action from Slack interactive message.

Example:

event.action;
// {
//   name: 'game',
//   type: 'button',
//   value: 'chess',
// }

isAppUninstalled

Determine if the event is an app_uninstalled event.

Example:

event.isAppUninstalled; // true

isChannelArchive

Determine if the event is a channel_archive event.

Example:

event.isChannelArchive; // true

isChannelCreated

Determine if the event is a channel_created event.

Example:

event.isChannelCreated; // true

isChannelDeleted

Determine if the event is a channel_deleted event.

Example:

event.isChannelDeleted; // true

isChannelHistoryChanged

Determine if the event is a channelhistorychanged event.

Example:

event.isChannelHistoryChanged; // true

isChannelRename

Determine if the event is a channel_rename event.

Example:

event.isChannelRename; // true

isChannelUnarchive

Determine if the event is a channel_unarchive event.

Example:

event.isChannelUnarchive; // true

isDndUpdated

Determine if the event is a dnd_updated event.

Example:

event.isDndUpdated; // true

isDndUpdatedUser

Determine if the event is a dndupdateduser event.

Example:

event.isDndUpdatedUser; // true

isEmailDomainChanged

Determine if the event is an emaildomainchanged event.

Example:

event.isEmailDomainChanged; // true

isEmojiChanged

Determine if the event is an emoji_changed event.

Example:

event.isEmojiChanged; // true

isFileChange

Determine if the event is a file_change event.

Example:

event.isFileChange; // true

isFileCommentAdded

Determine if the event is a filecommentadded event.

Example:

event.isFileCommentAdded; // true

isFileCommentDeleted

Determine if the event is a filecommentdeleted event.

Example:

event.isFileCommentDeleted; // true

isFileCommentEdited

Determine if the event is a filecommentedited event.

Example:

event.isFileCommentEdited; // true

isFileCreated

Determine if the event is a file_created event.

Example:

event.isFileCreated; // true

isFileDeleted

Determine if the event is a file_deleted event.

Example:

event.isFileDeleted; // true

isFilePublic

Determine if the event is a file_public event.

Example:

event.isFilePublic; // true

isFileShared

Determine if the event is a file_shared event.

Example:

event.isFileShared; // true

isFileUnshared

Determine if the event is a file_unshared event.

Example:

event.isFileUnshared; // true

isGridMigrationFinished

Determine if the event is a gridmigrationfinished event.

Example:

event.isGridMigrationFinished; // true

isGridMigrationStarted

Determine if the event is a gridmigrationstarted event.

Example:

event.isGridMigrationStarted; // true

isGroupArchive

Determine if the event is a group_archive event.

Example:

event.isGroupArchive; // true

isGroupClose

Determine if the event is a group_close event.

Example:

event.isGroupClose; // true

isGroupHistoryChanged

Determine if the event is a grouphistorychanged event.

Example:

event.isGroupHistoryChanged; // true

isGroupOpen

Determine if the event is a group_open event.

Example:

event.isGroupOpen; // true

isGroupRename

Determine if the event is a group_rename event.

Example:

event.isGroupRename; // true

isGroupUnarchive

Determine if the event is a group_unarchive event.

Example:

event.isGroupUnarchive; // true

isImClose

Determine if the event is a im_close event.

Example:

event.isImClose; // true

isImCreated

Determine if the event is a im_created event.

Example:

event.isImCreated; // true

isImHistoryChanged

Determine if the event is a imhistorychanged event.

Example:

event.isImHistoryChanged; // true

isImOpen

Determine if the event is a im_open event.

Example:

event.isImOpen; // true

isLinkShared

Determine if the event is a link_shared event.

Example:

event.isLinkShared; // true

isMemberJoinedChannel

Determine if the event is a memberjoinedchannel event.

Example:

event.isMemberJoinedChannel; // true

isMemberLeftChannel

Determine if the event is a memberleftchannel event.

Example:

event.isMemberLeftChannel; // true

isPinAdded

Determine if the event is a pin_added event.

Example:

event.isPinAdded; // true

isPinRemoved

Determine if the event is a pin_removed event.

Example:

event.isPinRemoved; // true

isReactionAdded

Determine if the event is a reaction_added event.

Example:

event.isReactionAdded; // true

isReactionRemoved

Determine if the event is a reaction_removed event.

Example:

event.isReactionRemoved; // true

isStarAdded

Determine if the event is a star_added event.

Example:

event.isStarAdded; // true

isStarRemoved

Determine if the event is a star_removed event.

Example:

event.isStarRemoved; // true

isSubteamCreated

Determine if the event is a subteam_created event.

Example:

event.isSubteamCreated; // true

isSubteamMembersChanged

Determine if the event is a subteammemberschanged event.

Example:

event.isSubteamMembersChanged; // true

isSubteamSelfAdded

Determine if the event is a subteamselfadded event.

Example:

event.isSubteamSelfAdded; // true

isSubteamSelfRemoved

Determine if the event is a subteamselfremoved event.

Example:

event.isSubteamSelfRemoved; // true

isSubteamUpdated

Determine if the event is a subteam_updated event.

Example:

event.isSubteamUpdated; // true

isTeamDomainChange

Determine if the event is a teamdomainchange event.

Example:

event.isTeamDomainChange; // true

isTeamJoin

Determine if the event is a team_join event.

Example:

event.isTeamJoin; // true

isTeamRename

Determine if the event is a team_rename event.

Example:

event.isTeamRename; // true

isTokensRevoked

Determine if the event is a tokens_revoked event.

Example:

event.isTokensRevoked; // true

isUrlVerification

Determine if the event is an url_verification event.

Example:

event.isUrlVerification; // true

isUserChange

Determine if the event is an user_change event.

Example:

event.isUserChange; // true