Send Message to Channel - slack
One script reply has been approved by the moderators Verified

Created by admin 427 days ago Viewed 14339 times 0 Points

slack

No comments yet

Login to be able to comment
Points: 0
deno
One script reply has been approved by the moderators
Ap­pro­ved
import { WebClient } from "https://deno.land/x/slack_web_api@1.0.0/mod.ts";

type Slack = {
  token: string;
};
export async function main(text: string, channel: string, slack: Slack) {
  const web = new WebClient(slack.token);

  await web.chat.postMessage({
    channel,
    text,
  });
}

Submitted by admin 427 days ago

Edited 46 days ago

No comments yet

Login to be able to comment