Skip to content

Commit

Permalink
docs: update readme to v0.1.1
Browse files Browse the repository at this point in the history
  • Loading branch information
moonD4rk committed Apr 25, 2022
1 parent 025c79c commit 0c0d971
Showing 1 changed file with 12 additions and 8 deletions.
20 changes: 12 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ notifier is a simple Go library to send notification to other applications.
| [Bark](https://apps.apple.com/us/app/bark-customed-notifications/id1403753865) | [provider/bark](https://github.com/moonD4rk/notifier/tree/main/provider/bark) |
| [Lark](https://www.larksuite.com/en_us/) | [provider/lark](https://github.com/moonD4rk/notifier/tree/main/provider/lark) |
| [Feishu](https://www.feishu.cn/) | [provider/feishu](https://github.com/moonD4rk/notifier/tree/main/provider/feishu) |
| [Server 酱](https://sct.ftqq.com/) | [provider/serverchan](https://github.com/moonD4rk/notifier/tree/main/provider/serverchan) |

## Install

Expand All @@ -32,20 +33,23 @@ import (

func main() {
var (
dingtalkToken = os.Getenv("dingtalk_token")
dingtalkSecret = os.Getenv("dingtalk_secret")
barkKey = os.Getenv("bark_key")
barkServer = notifier.DefaultBarkServer
feishuToken = os.Getenv("feishu_token")
feishuSecret = os.Getenv("feishu_secret")
larkToken = os.Getenv("feishu_token")
larkSecret = os.Getenv("feishu_secret")
dingtalkToken = os.Getenv("dingtalk_token")
dingtalkSecret = os.Getenv("dingtalk_secret")
barkKey = os.Getenv("bark_key")
barkServer = notifier.DefaultBarkServer
feishuToken = os.Getenv("feishu_token")
feishuSecret = os.Getenv("feishu_secret")
larkToken = os.Getenv("lark_token")
larkSecret = os.Getenv("lark_secret")
serverChanUserID = "" // server chan's userID could be empty
serverChanSendKey = os.Getenv("server_chan_send_key")
)
notifier := notifier.New(
notifier.WithDingTalk(dingtalkToken, dingtalkSecret),
notifier.WithBark(barkKey, barkServer),
notifier.WithFeishu(feishuToken, feishuSecret),
notifier.WithLark(larkToken, larkSecret),
notifier.WithServerChan(serverChanUserID, serverChanSendKey),
)

var (
Expand Down

0 comments on commit 0c0d971

Please sign in to comment.