or run

npx @tessl/cli init
Log in

Version

Tile

Overview

Evals

Files

Files

docs

advanced.mdauth.mdchannels.mdchat.mdfiles.mdindex.mdinteractive.mdrtm.mdsearch.mdusers.md

interactive.mddocs/

0

# Interactive Features

1

2

Manage reactions, starred items, pinned messages, and other interactive Slack features.

3

4

## Capabilities

5

6

### Reactions

7

8

Add, view, and manage emoji reactions on messages and files.

9

10

```python { .api }

11

def add(self, name, file_=None, file_comment=None, channel=None, timestamp=None):

12

"""

13

Add emoji reaction to message or file.

14

15

Args:

16

name (str): Emoji name (without colons, e.g., 'thumbsup')

17

file_ (str, optional): File ID to react to

18

file_comment (str, optional): File comment ID to react to

19

channel (str, optional): Channel ID (required with timestamp)

20

timestamp (str, optional): Message timestamp (required with channel)

21

22

Note: Must specify either file_/file_comment OR channel+timestamp

23

24

Returns:

25

Response: Reaction confirmation

26

"""

27

28

def get(self, file_=None, file_comment=None, channel=None, timestamp=None, full=None):

29

"""

30

Get reactions for message or file.

31

32

Args:

33

file_ (str, optional): File ID

34

file_comment (str, optional): File comment ID

35

channel (str, optional): Channel ID

36

timestamp (str, optional): Message timestamp

37

full (bool, optional): Include full user info in reactions

38

39

Returns:

40

Response: Reaction details with user information

41

"""

42

43

def list(self, user=None, full=None, count=None, page=None):

44

"""

45

List reactions by user.

46

47

Args:

48

user (str, optional): User ID (current user if None)

49

full (bool, optional): Include full item details

50

count (int, optional): Number of items per page

51

page (int, optional): Page number

52

53

Returns:

54

Response: User's reactions with context

55

"""

56

57

def remove(self, name, file_=None, file_comment=None, channel=None, timestamp=None):

58

"""

59

Remove emoji reaction from message or file.

60

61

Args:

62

name (str): Emoji name to remove

63

file_ (str, optional): File ID

64

file_comment (str, optional): File comment ID

65

channel (str, optional): Channel ID (required with timestamp)

66

timestamp (str, optional): Message timestamp (required with channel)

67

68

Returns:

69

Response: Removal confirmation

70

"""

71

```

72

73

### Stars

74

75

Star and unstar messages, files, and other items for easy reference.

76

77

```python { .api }

78

def add(self, file_=None, file_comment=None, channel=None, timestamp=None):

79

"""

80

Star an item.

81

82

Args:

83

file_ (str, optional): File ID to star

84

file_comment (str, optional): File comment ID to star

85

channel (str, optional): Channel ID (for message starring)

86

timestamp (str, optional): Message timestamp (for message starring)

87

88

Note: Must specify at least one of the parameters

89

90

Returns:

91

Response: Star confirmation

92

"""

93

94

def list(self, user=None, count=None, page=None):

95

"""

96

List starred items.

97

98

Args:

99

user (str, optional): User ID (current user if None)

100

count (int, optional): Number of items per page

101

page (int, optional): Page number

102

103

Returns:

104

Response: List of starred items with details

105

"""

106

107

def remove(self, file_=None, file_comment=None, channel=None, timestamp=None):

108

"""

109

Remove star from an item.

110

111

Args:

112

file_ (str, optional): File ID to unstar

113

file_comment (str, optional): File comment ID to unstar

114

channel (str, optional): Channel ID (for message unstarring)

115

timestamp (str, optional): Message timestamp (for message unstarring)

116

117

Returns:

118

Response: Unstar confirmation

119

"""

120

```

121

122

### Pins

123

124

Pin and unpin messages and files in channels for easy reference.

125

126

```python { .api }

127

def add(self, channel, file_=None, file_comment=None, timestamp=None):

128

"""

129

Pin an item to a channel.

130

131

Args:

132

channel (str): Channel ID to pin in

133

file_ (str, optional): File ID to pin

134

file_comment (str, optional): File comment ID to pin

135

timestamp (str, optional): Message timestamp to pin

136

137

Note: Must specify one of file_, file_comment, or timestamp

138

139

Returns:

140

Response: Pin confirmation

141

"""

142

143

def remove(self, channel, file_=None, file_comment=None, timestamp=None):

144

"""

145

Unpin an item from a channel.

146

147

Args:

148

channel (str): Channel ID to unpin from

149

file_ (str, optional): File ID to unpin

150

file_comment (str, optional): File comment ID to unpin

151

timestamp (str, optional): Message timestamp to unpin

152

153

Returns:

154

Response: Unpin confirmation

155

"""

156

157

def list(self, channel):

158

"""

159

List pinned items in a channel.

160

161

Args:

162

channel (str): Channel ID

163

164

Returns:

165

Response: List of pinned items in channel

166

"""

167

```

168

169

### Custom Emoji

170

171

Manage workspace custom emoji.

172

173

```python { .api }

174

def list(self):

175

"""

176

List custom emoji in workspace.

177

178

Returns:

179

Response: Dictionary of custom emoji names and URLs

180

"""

181

```

182

183

Usage:

184

```python

185

# Add reaction to message

186

slack.reactions.add('thumbsup', channel='C1234567890', timestamp='1234567890.123456')

187

188

# Star a message

189

slack.stars.add(channel='C1234567890', timestamp='1234567890.123456')

190

191

# Pin a message

192

slack.pins.add('C1234567890', timestamp='1234567890.123456')

193

194

# List pinned items in channel

195

pins = slack.pins.list('C1234567890')

196

197

# Get custom emoji

198

emoji = slack.emoji.list()

199

for name, url in emoji.body['emoji'].items():

200

print(f":{name}: -> {url}")

201

```

202

203

## Types

204

205

```python { .api }

206

class Reactions(BaseAPI):

207

"""Emoji reaction management."""

208

def add(self, name, file_=None, file_comment=None, channel=None, timestamp=None): ...

209

def get(self, file_=None, file_comment=None, channel=None, timestamp=None, full=None): ...

210

def list(self, user=None, full=None, count=None, page=None): ...

211

def remove(self, name, file_=None, file_comment=None, channel=None, timestamp=None): ...

212

213

class Stars(BaseAPI):

214

"""Starred item management."""

215

def add(self, file_=None, file_comment=None, channel=None, timestamp=None): ...

216

def list(self, user=None, count=None, page=None): ...

217

def remove(self, file_=None, file_comment=None, channel=None, timestamp=None): ...

218

219

class Pins(BaseAPI):

220

"""Pinned item management."""

221

def add(self, channel, file_=None, file_comment=None, timestamp=None): ...

222

def remove(self, channel, file_=None, file_comment=None, timestamp=None): ...

223

def list(self, channel): ...

224

225

class Emoji(BaseAPI):

226

"""Custom emoji management."""

227

def list(self): ...

228

```