refactor: centralize slack threading helpers
This commit is contained in:
38
src/slack/types.ts
Normal file
38
src/slack/types.ts
Normal file
@@ -0,0 +1,38 @@
|
||||
export type SlackFile = {
|
||||
id?: string;
|
||||
name?: string;
|
||||
mimetype?: string;
|
||||
size?: number;
|
||||
url_private?: string;
|
||||
url_private_download?: string;
|
||||
};
|
||||
|
||||
export type SlackMessageEvent = {
|
||||
type: "message";
|
||||
user?: string;
|
||||
bot_id?: string;
|
||||
subtype?: string;
|
||||
username?: string;
|
||||
text?: string;
|
||||
ts?: string;
|
||||
thread_ts?: string;
|
||||
event_ts?: string;
|
||||
parent_user_id?: string;
|
||||
channel: string;
|
||||
channel_type?: "im" | "mpim" | "channel" | "group";
|
||||
files?: SlackFile[];
|
||||
};
|
||||
|
||||
export type SlackAppMentionEvent = {
|
||||
type: "app_mention";
|
||||
user?: string;
|
||||
bot_id?: string;
|
||||
username?: string;
|
||||
text?: string;
|
||||
ts?: string;
|
||||
thread_ts?: string;
|
||||
event_ts?: string;
|
||||
parent_user_id?: string;
|
||||
channel: string;
|
||||
channel_type?: "im" | "mpim" | "channel" | "group";
|
||||
};
|
||||
Reference in New Issue
Block a user