andrewchilds/slack-notify

Send notification to more than one channel

Closed this issue · 1 comments

slack.send({
  channel: ['#general', '@john'],
  icon_url: 'http://example.com/my-icon.png',
  text: 'Here is my notification',
  unfurl_links: 1,
  username: 'Jimmy'
});

Hello! I'd rather not include support for this use case, as this already has an easy workaround:

['#general', '@john'].forEach((channel) => {
  slack.send({
    channel,
    icon_url: 'http://example.com/my-icon.png',
    text: 'Here is my notification',
    unfurl_links: 1,
    username: 'Jimmy'
  });
});