From 2ec7fc7cccd6a3350f71a1edd9954a3e4536db49 Mon Sep 17 00:00:00 2001 From: Thom Wright Date: Mon, 29 Jan 2018 10:00:50 +0000 Subject: [PATCH] Add updateResponse callback to replyAndUpdate type --- lib/Botkit.d.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/Botkit.d.ts b/lib/Botkit.d.ts index ba072f4ea..802de1867 100644 --- a/lib/Botkit.d.ts +++ b/lib/Botkit.d.ts @@ -244,6 +244,9 @@ declare namespace botkit { title_link?: string; ts?: string; } + interface SlackUpdateMessageCallback { + (newResponse: string | SlackMessage, cb?: (err: Error) => void): void + } interface SlackBot extends Bot { readonly api: SlackWebAPI; configureIncomingWebhook(config: { url: string; }): this; @@ -254,7 +257,7 @@ declare namespace botkit { identifyTeam(): string; identifyBot(): { id: string; name: string; team_id: string; }; replyAcknowledge(cb?: (err: Error) => void): void; - replyAndUpdate(src: SlackMessage, resp: string | SlackMessage, cb: (err: Error, res: string) => void): void; + replyAndUpdate(src: SlackMessage, resp: string | SlackMessage, cb: (err: Error, res: string, updateResponse: SlackUpdateMessageCallback) => void): void; replyInThread(src: SlackMessage, resp: string | SlackMessage, cb: (err: Error, res: string) => void): void; replyPrivate(src: SlackMessage, resp: string | SlackMessage, cb?: (err: Error) => void): void; replyPrivateDelayed(src: SlackMessage, resp: string | SlackMessage, cb?: (err: Error) => void): void;