-
Notifications
You must be signed in to change notification settings - Fork 0
/
channel.go
45 lines (40 loc) · 1.21 KB
/
channel.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
package main
type Channel struct {
Id string `json:"id"`
Name string `json:"name"`
IsChannel bool `json:"is_channel"`
Created int64 `json:"created"`
Creator string `json:"creator"`
IsArchived bool `json:"is_archived"`
IsGeneral bool `json:"is_general"`
NameNormalized string `json:"name_normalized"`
IsShared bool `json:"is_shared"`
IsOrgShared bool `json:"is_org_shared"`
IsMember bool `json:"is_member"`
IsPrivate bool `json:"is_private"`
IsMpim bool `json:"is_mpim"`
Members []string `json:"members"`
Topic Topic `json:"topic"`
Purpose Purpose `json:"purpose"`
PreviousNames []string `json:"previous_names"`
NumMembers int `json:"num_members"`
}
type Topic struct {
Value string `json:"value"`
Creator string `json:"Creator"`
LastSet int64 `json:"last_set"`
}
type Purpose struct {
Value string `json:"value"`
Creator string `json:"creator"`
LastSet int64 `json:"last_set"`
}
type ChannelsList struct {
Ok bool `json:"ok"`
Channels []Channel `json:"channels"`
}
type ChannelHistory struct {
OK bool `json:"ok"`
Messages []Message `json:"messages"`
HasMore bool `json:"has_more"`
}