Skip to content

fix: Improve 401 error handling in axios interceptor #9

fix: Improve 401 error handling in axios interceptor

fix: Improve 401 error handling in axios interceptor #9

Workflow file for this run

name: Telegram Commit Notification
on:
push:
branches: [ main, dev ]
jobs:
notify:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Send Telegram notification
env:
BOT_TOKEN: ${{ secrets.TELEGRAM_BOT_TOKEN }}
CHAT_ID: ${{ secrets.TELEGRAM_CHAT_ID }}
run: |
MESSAGE="🚀 A new commit was pushed to: ${{ github.ref_name }}
📂 Repository: <b>${{ github.repository }}</b>
✉️ Commit Message: <i>${{ github.event.head_commit.message }}</i>
👤 Author: <code>${{ github.event.head_commit.author.name }}</code>
🔑 Commit SHA: <code>${{ github.sha }}</code>
🔍 Compare Changes: <a href='${{ github.event.compare }}'>View Changes</a>
⏰ Timestamp: ${{ github.event.head_commit.timestamp }}
🌟 Happy coding!
🔄 Triggered automatically by GitHub Actions"
curl -s -X POST \
"https://api.telegram.org/bot${BOT_TOKEN}/sendMessage" \
-d "chat_id=${CHAT_ID}" \
-d "text=${MESSAGE}" \
-d "parse_mode=HTML" \
-d "disable_web_page_preview=true"