Use of webhooks in GitHub

Source: Internet
Author: User

Directory

    • The configuration of webhooks in GitHub
    • Testing the configuration of the Webhooks

Currently in the team designing an application management feature, you need to understand the use of common code-managed webhooks. Webhooks, the first of GitHub, took the lead, and recorded the use of webhooks in GitHub below.

The configuration of webhooks in GitHub
在自己的GitHub的项目中选中settings按钮,进入到webhooks的配置界面,然后选择左侧栏的webhooks进行配置。详细的参数配置属性值,可以查看官方的文档https://developer.github.com/webhooks/,当然,基础的配置我们一眼就看出来了,不看文档也行,嘻嘻。。。



After the configuration is displayed a callback address, you can see that the push in the back of the slogan for we just selected the push code when the callback, the URL of the callback can also be edited and deleted

Testing the configuration of the Webhooks
由于我选择的是push代码的时候才进行回调,所以我们在自己的项目中提交一个commit,来看看webhooks回调我们的URL时给出的数据格式是什么。提交一个commit后,我再次进入Settings->Webhooks 最下方有我们刚才出发的回调

点击上面的最近的一次提交,我们可以看到请求头信息,和响应信息在请求的参数中,我们可以拿到好多有用的信息,比如提交人的名字,邮箱,修改的文件,上次提交的ID,代码库的创始人,邮箱等等有用的信息


Use of webhooks in GitHub

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.