Skip to content
12 changes: 12 additions & 0 deletions packages/web-api/src/types/request/chat.ts
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,9 @@ export type ChatPostEphemeralArguments = TokenOverridable &
* The user should be in the channel specified by the `channel` argument.
*/
user: string;
/** @description Accepts message text formatted in markdown. This argument should not be used
* in conjunction with blocks or text. Limit this field to 12,000 characters. */
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

praise: Thank you for adding jsdoc 📚 ✨

thought: Might leaving line breaks to the editor should be an overall change we make? I'm thinking we could perhaps snag this from the kind docs.slack.dev/reference/methods pages in neartimes 🤖

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thought: That "editor" I realize is not so clear but I find this in testing:

linewrap

markdown_text?: string;
} & Authorship &
Parse &
LinkNames &
Expand All @@ -184,13 +187,19 @@ export type ChatPostMessageArguments = TokenOverridable &
Unfurls & {
/** @description Disable Slack markup parsing by setting to `false`. Enabled by default. */
mrkdwn?: boolean;
/** @description Accepts message text formatted in markdown. This argument should not be used
* in conjunction with blocks or text. Limit this field to 12,000 characters. */
markdown_text?: string;
};

// https://docs.slack.dev/reference/methods/chat.scheduleMessage
export type ChatScheduleMessageArguments = TokenOverridable &
MessageContents & {
/** @description Unix EPOCH timestamp of time in future to send the message. */
post_at: string | number;
/** @description Accepts message text formatted in markdown. This argument should not be used
* in conjunction with blocks or text. Limit this field to 12,000 characters. */
markdown_text?: string;
Comment thread
zimeg marked this conversation as resolved.
Outdated
} & ReplyInThread &
Parse &
LinkNames &
Expand Down Expand Up @@ -265,4 +274,7 @@ export type ChatUpdateArguments = MessageContents & {
file_ids?: string[];
/** @description Broadcast an existing thread reply to make it visible to everyone in the channel or conversation. */
reply_broadcast?: boolean;
/** @description Accepts message text formatted in markdown. This argument should not be used
* in conjunction with blocks or text. Limit this field to 12,000 characters. */
markdown_text?: string;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

praise: I am a fan of inlining these arguments! 👾

};
Loading