@fractional-company/common
Version:
Tessera constants
30 lines (29 loc) • 898 B
TypeScript
import { InternalEventBuilder } from "./InternalEventBuilder";
export declare type SlackField = {
title: string;
value: string | number;
short: boolean;
};
export declare enum SlackMessageTypes {
"Success" = "Success",
"Error" = "Error",
"Warn" = "Warn",
"Info" = "Info"
}
export declare type SlackEventBody = {
fields: SlackField[];
messageType: SlackMessageTypes;
title: string;
channelId?: string;
};
export declare class SlackEventBuilder extends InternalEventBuilder {
fields: SlackField[] | undefined;
messageType: SlackMessageTypes;
title: string;
channelId?: string;
setFields(fields: SlackField[]): this;
setMessageType(messageType: SlackMessageTypes): this;
setTitle(title: string): this;
setChannelId(channelId: string): this;
getEventBody(eventName: string): SlackEventBody;
}