New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

slack-notify

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

slack-notify

  • 0.6.0
  • Rubygems
  • Socket score

Version published
Maintainers
1
Created
Source

slack-notify

Send notifications to Slack via webhooks.

Build Status Code Climate Gem Version

Installation

Add this line to your application's Gemfile:

gem "slack-notify"

And then execute:

$ bundle

Or install it yourself as:

$ gem install slack-notify

Usage

Require:

require "slack-notify"

Initialize client:

client = SlackNotify::Client.new(webhook_url: "slack webhook url")

Initialize with options:

client = SlackNotify::Client.new(
  webhook_url: "slack webhook url",
  channel: "#development",
  username: "mybot",
  icon_url: "http://mydomain.com/myimage.png",
  icon_emoji: ":shipit:",
  link_names: 1
)

Initialize via shorthand method:

client = SlackNotify.new(options)

Send test request:

client.test

Send message:

client.notify("Hello There!")
client.notify("Another message", "#channel2")
client.notify("Message", ["#channel1", "#channel2"])

Send direct message:

client.notify("Hello There!", "@username")

You can also test gem via rake console:

rake console

License

Copyright (c) 2013-2015 Dan Sosedoff, dan.sosedoff@gmail.com

MIT License

FAQs

Package last updated on 23 Dec 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc