GithubHelp home page GithubHelp logo

littleor / feishu-github-webhook-bot Goto Github PK

View Code? Open in Web Editor NEW

This project forked from handsomehan515/feishu-webhook

1.0 0.0 0.0 184 KB

使用飞书机器人推送GitHub仓库变动和Action状态(Feishu Github WebHook Bot)

TypeScript 99.41% Shell 0.59%

feishu-github-webhook-bot's Introduction

FeiShu Bot for Github Webhook

github-profile-readme-generator forks github-profile-readme-generator stars github-profile-readme-generator issues github-profile-readme-generator pull-requests

This repository is a webhook server for github, it will send message to FeiShu group when github webhook trigger.

Install

# If you use yarn
yarn

# If you use npm
npm install

Start

Config the env

You should config the env in .env file, you can copy the .env.example file to .env and modify it.

PORT=8090
WORKFLOW_WHITELIST=["completed", "requested"]
FEISHU_URI=https://xxxx     
FEISHU_SECRET=xxxxxxx       

NOTE

  • FEISHU_URI and FEISHU_SECRET can get from FeiShu Bot's Webhook URI, you can refer to this document
  • WORKFLOW_WHITELIST is for the workflow_run, it will send message when the workflow_run's status in the list
  • PORT is the server port

Build & Run

yarn build
yarn start

Config the Github WebHook

  1. Go to the repository you want to config the webhook
  2. Go to Settings > Webhooks
  3. Click Add webhook
  4. Add the Payload URL(e.g. https://www.example.com/webhook/github)
  5. Set Content type to application/json
  6. DO NOT Set Secret
  7. Set Which events would you like to trigger this webhook? to Let me select individual events. or Send me everything.
  8. Now everything is ok, you can test push the code or create a pull request to test the webhook.

Support

  • Create Branch
  • Delete Branch
  • Commit Comment
  • Pull Request
  • Push Commit
  • Create Issues
  • Issue comment
  • Pull request review comment
  • Workflow run requested
  • Workflow run in_progress
  • Workflow run completed

OPENAPI

To generate new schema file with openapi.yaml, run under folder path

npx openapi-typescript openapi.yaml --output ./app/schema/GeneratedSchema.ts

feishu-github-webhook-bot's People

Contributors

handsomehan515 avatar littleor avatar

Stargazers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.