0
Example of responding to a slack command
One script reply has been approved by the moderators Verified

This script respond to a slack command /windmill <text>.

Created by admin 744 days ago Viewed 11049 times
1
Submitted by henri186 Deno
Verified 483 days ago
1
export async function main(response_url: string, text: string) {
2
  const x = await fetch(response_url, {
3
    method: "POST",
4
    body: JSON.stringify({ text: `ROGER ${text}` }),
5
  });
6
  const username = await Deno.env.get("WM_USERNAME");
7
  console.log(`user = ${username}`);
8
}
9

Other submissions