PHPackages                             falko189/github - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Framework](/categories/framework)
4. /
5. falko189/github

ActiveLibrary[Framework](/categories/framework)

falko189/github
===============

GitHub Is A GitHub Bridge For Laravel 5

10.0.3(7y ago)02MITPHPPHP ^7.1.3

Since Jul 27Pushed 7y ago1 watchersCompare

[ Source](https://github.com/falko189/Laravel-GitHub)[ Packagist](https://packagist.org/packages/falko189/github)[ RSS](/packages/falko189-github/feed)WikiDiscussions master Synced 4d ago

READMEChangelog (3)Dependencies (12)Versions (37)Used By (0)

Laravel GitHub
==============

[](#laravel-github)

Laravel GitHub was created by, and is maintained by [Graham Campbell](https://github.com/GrahamCampbell), and is a [PHP GitHub API](https://github.com/KnpLabs/php-github-api) bridge for [Laravel 5](http://laravel.com). It utilises my [Laravel Manager](https://github.com/GrahamCampbell/Laravel-Manager) package. Feel free to check out the [change log](CHANGELOG.md), [releases](https://github.com/GrahamCampbell/Laravel-GitHub/releases), [license](LICENSE), and [contribution guidelines](CONTRIBUTING.md).

[![Laravel GitHub](https://cloud.githubusercontent.com/assets/2829600/4432305/c14a3934-468c-11e4-8371-684e72291139.PNG)](https://cloud.githubusercontent.com/assets/2829600/4432305/c14a3934-468c-11e4-8371-684e72291139.PNG)

[![StyleCI Status](https://camo.githubusercontent.com/b9e912f126a35ccea7db6ed45f461a966cfb516c911af7368fee20caa68d77b5/68747470733a2f2f7374796c6563692e696f2f7265706f732f32323238383836392f736869656c64)](https://styleci.io/repos/22288869)[![Build Status](https://camo.githubusercontent.com/a188709e144c47ef95426d8ca0374702e240c2535185e8878e1068fc759329cc/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f47726168616d43616d7062656c6c2f4c61726176656c2d4769744875622f6d61737465722e7376673f7374796c653d666c61742d737175617265)](https://travis-ci.org/GrahamCampbell/Laravel-GitHub)[![Coverage Status](https://camo.githubusercontent.com/c0bb307e0e152bdbe0e9851c3d79295eaade70763e0c63a82d521b319941f65a/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f636f7665726167652f672f47726168616d43616d7062656c6c2f4c61726176656c2d4769744875622e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/GrahamCampbell/Laravel-GitHub/code-structure)[![Quality Score](https://camo.githubusercontent.com/6dc4bef2aec4ed73217d83c2608372a35d4c6a1290743242d8a4d2ef6929715f/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f47726168616d43616d7062656c6c2f4c61726176656c2d4769744875622e7376673f7374796c653d666c61742d737175617265)](https://scrutinizer-ci.com/g/GrahamCampbell/Laravel-GitHub)[![Software License](https://camo.githubusercontent.com/55c0218c8f8009f06ad4ddae837ddd05301481fcf0dff8e0ed9dadda8780713e/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f6c6963656e73652d4d49542d627269676874677265656e2e7376673f7374796c653d666c61742d737175617265)](LICENSE)[![Latest Version](https://camo.githubusercontent.com/06a729a772ca88bf7662f241a00dae6c9e724bb098072a753e6c3a7db4cb5338/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f72656c656173652f47726168616d43616d7062656c6c2f4c61726176656c2d4769744875622e7376673f7374796c653d666c61742d737175617265)](https://github.com/GrahamCampbell/Laravel-GitHub/releases)

Installation
------------

[](#installation)

Laravel GitHub requires [PHP](https://php.net) 7.1 or 7.2. This particular version supports Laravel 5.5 - 5.7 only.

To get the latest version, simply require the project using [Composer](https://getcomposer.org). You will need to install any package that "provides" `php-http/client-implementation`. Most users will want:

```
$ composer require graham-campbell/github php-http/guzzle6-adapter:^1.1
```

Once installed, if you are not using automatic package discovery, then you need to register the `GrahamCampbell\GitHub\GitHubServiceProvider` service provider in your `config/app.php`.

You can also optionally alias our facade:

```
        'GitHub' => GrahamCampbell\GitHub\Facades\GitHub::class,
```

Configuration
-------------

[](#configuration)

Laravel GitHub requires connection configuration.

To get started, you'll need to publish all vendor assets:

```
$ php artisan vendor:publish
```

This will create a `config/github.php` file in your app that you can modify to set your configuration. Also, make sure you check for changes to the original config file in this package between releases.

There are two config options:

##### Default Connection Name

[](#default-connection-name)

This option (`'default'`) is where you may specify which of the connections below you wish to use as your default connection for all work. Of course, you may use many connections at once using the manager class. The default value for this setting is `'main'`.

##### GitHub Connections

[](#github-connections)

This option (`'connections'`) is where each of the connections are setup for your application. Example configuration has been included, but you may add as many connections as you would like. Note that the 5 supported authentication methods are: `"application"`, `"jwt"`, `"none"`, `"password"`, and `"token"`.

Usage
-----

[](#usage)

##### GitHubManager

[](#githubmanager)

This is the class of most interest. It is bound to the ioc container as `'github'` and can be accessed using the `Facades\GitHub` facade. This class implements the `ManagerInterface` by extending `AbstractManager`. The interface and abstract class are both part of my [Laravel Manager](https://github.com/GrahamCampbell/Laravel-Manager) package, so you may want to go and checkout the docs for how to use the manager class over at [that repo](https://github.com/GrahamCampbell/Laravel-Manager#usage). Note that the connection class returned will always be an instance of `\Github\Client`.

##### Facades\\GitHub

[](#facadesgithub)

This facade will dynamically pass static method calls to the `'github'` object in the ioc container which by default is the `GitHubManager` class.

##### GitHubServiceProvider

[](#githubserviceprovider)

This class contains no public methods of interest. This class should be added to the providers array in `config/app.php`. This class will setup ioc bindings.

##### Real Examples

[](#real-examples)

Here you can see an example of just how simple this package is to use. Out of the box, the default adapter is `main`. After you enter your authentication details in the config file, it will just work:

```
use GrahamCampbell\GitHub\Facades\GitHub;
// you can alias this in config/app.php if you like

GitHub::me()->organizations();
// we're done here - how easy was that, it just works!

GitHub::repo()->show('GrahamCampbell', 'Laravel-GitHub');
// this example is simple, and there are far more methods available
```

The github manager will behave like it is a `\Github\Client` class. If you want to call specific connections, you can do with the `connection` method:

```
use GrahamCampbell\GitHub\Facades\GitHub;

// the alternative connection is the other example provided in the default config
GitHub::connection('alternative')->me()->emails()->add('foo@bar.com');

// now we can see the new email address in the list of all the user's emails
GitHub::connection('alternative')->me()->emails()->all();
```

With that in mind, note that:

```
use GrahamCampbell\GitHub\Facades\GitHub;

// writing this:
GitHub::connection('main')->issues()->show('GrahamCampbell', 'Laravel-GitHub', 2);

// is identical to writing this:
GitHub::issues()->show('GrahamCampbell', 'Laravel-GitHub', 2);

// and is also identical to writing this:
GitHub::connection()->issues()->show('GrahamCampbell', 'Laravel-GitHub', 2);

// this is because the main connection is configured to be the default
GitHub::getDefaultConnection(); // this will return main

// we can change the default connection
GitHub::setDefaultConnection('alternative'); // the default is now alternative
```

If you prefer to use dependency injection over facades like me, then you can easily inject the manager like so:

```
use GrahamCampbell\GitHub\GitHubManager;
use Illuminate\Support\Facades\App; // you probably have this aliased already

class Foo
{
    protected $github;

    public function __construct(GitHubManager $github)
    {
        $this->github = $github;
    }

    public function bar()
    {
        $this->github->issues()->show('GrahamCampbell', 'Laravel-GitHub', 2);
    }
}

App::make('Foo')->bar();
```

For more information on how to use the `\Github\Client` class we are calling behind the scenes here, check out the docs at , and the manager class at .

##### Further Information

[](#further-information)

There are other classes in this package that are not documented here. This is because they are not intended for public use and are used internally by this package.

Security
--------

[](#security)

If you discover a security vulnerability within this package, please send an e-mail to Graham Campbell at . All security vulnerabilities will be promptly addressed.

License
-------

[](#license)

Laravel GitHub is licensed under [The MIT License (MIT)](LICENSE).

###  Health Score

29

—

LowBetter than 57% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity2

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity70

Established project with proven stability

 Bus Factor1

Top contributor holds 95.5% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~48 days

Recently: every ~87 days

Total

36

Last Release

2662d ago

Major Versions

3.2.x-dev → v4.0.02015-06-26

4.4.x-dev → v5.0.02016-12-11

5.1.x-dev → v6.0.02017-08-06

v6.2.1 → v7.0.02018-03-01

v7.3.0 → 10.0.02019-01-27

PHP version history (4 changes)v0.1.0-alphaPHP &gt;=5.4.7

v3.1.0PHP &gt;=5.5.9

v6.0.0PHP ^7.0

v7.0.0PHP ^7.1.3

### Community

Maintainers

![](https://www.gravatar.com/avatar/83c7bd56ccd5ece1d23b661e3c67a61d3e85ce5a5dc875611e430435d0f614ca?d=identicon)[falko189](/maintainers/falko189)

---

Top Contributors

[![GrahamCampbell](https://avatars.githubusercontent.com/u/2829600?v=4)](https://github.com/GrahamCampbell "GrahamCampbell (253 commits)")[![zanechua](https://avatars.githubusercontent.com/u/4265429?v=4)](https://github.com/zanechua "zanechua (4 commits)")[![R3VoLuT1OneR](https://avatars.githubusercontent.com/u/1111188?v=4)](https://github.com/R3VoLuT1OneR "R3VoLuT1OneR (2 commits)")[![diegohq](https://avatars.githubusercontent.com/u/1486939?v=4)](https://github.com/diegohq "diegohq (1 commits)")[![lucasmichot](https://avatars.githubusercontent.com/u/513603?v=4)](https://github.com/lucasmichot "lucasmichot (1 commits)")[![PoLaKoSz](https://avatars.githubusercontent.com/u/1327533?v=4)](https://github.com/PoLaKoSz "PoLaKoSz (1 commits)")[![jrean](https://avatars.githubusercontent.com/u/5646128?v=4)](https://github.com/jrean "jrean (1 commits)")[![driesvints](https://avatars.githubusercontent.com/u/594614?v=4)](https://github.com/driesvints "driesvints (1 commits)")[![jbrooksuk](https://avatars.githubusercontent.com/u/246103?v=4)](https://github.com/jbrooksuk "jbrooksuk (1 commits)")

---

Tags

frameworklaravelgithubGraham CampbellGrahamCampbellBridgephp-github-apigithub bridgeLaravel GitHub

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/falko189-github/health.svg)

```
[![Health](https://phpackages.com/badges/falko189-github/health.svg)](https://phpackages.com/packages/falko189-github)
```

###  Alternatives

[graham-campbell/github

GitHub Is A GitHub Bridge For Laravel

6501.9M21](/packages/graham-campbell-github)[laravel/horizon

Dashboard and code-driven configuration for Laravel queues.

4.2k95.4M293](/packages/laravel-horizon)[laravel/sail

Docker files for running a basic Laravel application.

1.9k205.7M1.3k](/packages/laravel-sail)[graham-campbell/digitalocean

DigitalOcean Is A DigitalOcean Bridge For Laravel

508364.3k2](/packages/graham-campbell-digitalocean)[graham-campbell/bitbucket

Bitbucket Is A Bitbucket Bridge For Laravel

77195.1k2](/packages/graham-campbell-bitbucket)[laravel/ai

The official AI SDK for Laravel.

1.0k3.2M183](/packages/laravel-ai)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
