This action send a notification about your action runs.
See action.yml
Basic:
- uses: haishanh/actions-telegram-notification@v1
if: ${{ always() }}
with:
notification-token: ${{ secrets.NOTIFICATION_TOKEN }}
job-status: ${{ job.status }}
You can obtain a NOTIFICATION_TOKEN
by sending the command /token
to the GitHub Actions Notification bot. After you get the token, goto your repo "Settings" page, select "Secrets" and add it as a secret environment variables there.
Note that GitHub Actions Notification bot is not a GitHub official one, the source code of the bot API is here. And it's running on vercel.
# install deps
yarn
create a .env
file with content like below:
JWT="The NOTIFICATION_TOKEN you grab from the bot"
# if you want to use your own bot
BOT_TOKEN="your BOT_TOKEN"
CHAT_ID="your chat id"
yarn do ./src/local.ts