2017 © Pedro Peláez
 

library github

A library to interact with the GitHub API

image

duncan3dc/github

A library to interact with the GitHub API

  • Monday, July 16, 2018
  • by duncan3dc
  • Repository
  • 2 Watchers
  • 1 Stars
  • 8 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 2 Versions
  • 0 % Grown

The README.md

github

A PHP library to interact with the GitHub API, (*1)

Full documentation is available at http://duncan3dc.github.io/github/
PHPDoc API documentation is also available at http://duncan3dc.github.io/github/api/, (*2)

release build coverage, (*3)

Installation

The recommended method of installing this library is via Composer., (*4)

Run the following command from your project root:, (*5)

$ composer require duncan3dc/github

Getting Started

use duncan3dc\GitHub\Api;

require __DIR__ . "/vendor/autoload.php";

# Connect to a GitHub app using the private key
$api = new Api(1014, file_get_contents("/var/safe/github.pem"));

# List all the organizations this app is installed under
foreach ($app->getOrganizations() as $organization) {
    echo $organization->getName() . "\n";
}

# Get a specific organization/user
$organization = $app->getOrganization("duncan3dc");

Read more at http://duncan3dc.github.io/github/, (*6)

Where to get help

Found a bug? Got a question? Just not sure how something works?
Please create an issue and I'll do my best to help out.
Alternatively you can catch me on Twitter, (*7)

The Versions