LoginSignup
2
4

More than 3 years have passed since last update.

[Ruby]Line通知を使う

Last updated at Posted at 2019-05-19

都内でエンジニアとしている@emonoといいます。
仕事では主にrubyを書いてます。
botの実行結果をlineび通知したいなあ〜と思ってgemを作ったので、使い方をメモっときます。
作ったときの話はこちら
Gemはこちら

事前準備

使い方

# Gemを追加
gem install 'line-notify-client'
irb(main):005:0> require 'line-notify-client'
=> true
irb(main):006:0> token = "hoge1234" # irb(main):007:0> message = "hogehoge" # send_message
irb(main):008:0> Line::Notify::Client.message(token: token, message: message)
=> {"status"=>200, "message"=>"ok"} 

以上、ありがとうございました〜。

2
4
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
4