From 29e664a8b504fe32aa7233189e44053162c31f38 Mon Sep 17 00:00:00 2001 From: kha7iq Date: Fri, 4 Jun 2021 12:07:00 +0800 Subject: [PATCH] docs: add documentation for line messanger --- README.md | 3 +++ docs/services.md | 49 +++++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 51 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 807f6fb..2428a78 100644 --- a/README.md +++ b/README.md @@ -54,6 +54,7 @@ platforms. - *Discord* - *Email* +- *Line* - *Mastodon* - *Mattermost* - *Microsoft Teams* @@ -164,7 +165,9 @@ COMMANDS: mattermost Send message to mattermost pushbullet Send message to pushbullet twillio Send sms via twillio + zulip Send message to zulip mastodon Set status message for mastodon + line Send message to line messenger help, h Shows a list of commands or help for one command GLOBAL OPTIONS: diff --git a/docs/services.md b/docs/services.md index 5046c69..d99ee73 100644 --- a/docs/services.md +++ b/docs/services.md @@ -512,7 +512,7 @@ jobs: ## Zulip -Mastodon uses application token to authorize and set status. +Zulip uses bot email and token for authentication, and sends messages to particular topic. ```bash pingme zulip @@ -564,6 +564,53 @@ jobs: | ZULIP_TOPIC | "" | | ZULIP_MESSAGE | "" | +## Line + +Line uses chanel secret and token for authentication, and sends messages. + +```bash +pingme line + --secret 'secretxxx' \ + --token '12345567' \ + --receivers 'ab1234545xx' \ + --msg 'content of message' +``` + +- GitHub Action + +```yaml +on: [push] + +jobs: + pingme-job: + runs-on: ubuntu-latest + name: PingMe + steps: + - name: Checkout + uses: actions/checkout@v2 + + - name: Ping me On + uses: kha7iq/pingme-action@v1 + env: + LINE_SECRET: ${{ secrets.LINE_SECRET }} + LINE_TOKEN: ${{ secrets.LINE_TOKEN }} + LINE_RECEIVER_IDS: 'ab1235xxx8' + LINE_MSG_TITLE: 'Reference: ${{ github.ref }}' + LINE_MESSAGE: 'Event is triggered by ${{ github.event_name }}' + + with: + service: line +``` + +- **Variables** + +| Variables | Default Value | +| -------------------------- | :----------------: | +| LINE_SECRET | "" | +| LINE_TOKEN | "" | +| LINE_RECEIVER_IDS | "" | +| LINE_MSG_TITLE | "" | +| LINE_MESSAGE | "" | ## Email