Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/sy-records/webhooks

WebHook Handler for GitHub, Gitee and GitLab.
https://github.com/sy-records/webhooks

git gitee github gitlab php webhooks

Last synced: 2 months ago
JSON representation

WebHook Handler for GitHub, Gitee and GitLab.

Awesome Lists containing this project

README

        

# webhooks

WebHook Handler for GitHub, Gitee, Gitea, GitLab and Gogs.

[![Latest Stable Version](http://poser.pugx.org/sy-records/webhooks/v)](https://packagist.org/packages/sy-records/webhooks)
[![Total Downloads](http://poser.pugx.org/sy-records/webhooks/downloads)](https://packagist.org/packages/sy-records/webhooks)
[![Latest Unstable Version](http://poser.pugx.org/sy-records/webhooks/v/unstable)](https://packagist.org/packages/sy-records/webhooks)
[![License](http://poser.pugx.org/sy-records/webhooks/license)](https://packagist.org/packages/sy-records/webhooks)
[![PHP Version Require](http://poser.pugx.org/sy-records/webhooks/require/php)](https://packagist.org/packages/sy-records/webhooks)

## Install

```bash
composer require sy-records/webhooks
```

## Usage

```php
use Luffy\WebHook\Payload;
use Luffy\WebHook\Interfaces\HandlerInterface;

// 如果存在实现MessageInterface的request对象,可以传入
// 不传则从全局变量中获取
$payload = new Payload();
/** @var HandlerInterface $handler */
$handler = $payload->getHandler();
```