PHP Classes

Github PHP API Library: Get responses to requests to the Github API

Recommend this page to a friend!
  Info   View files Example   Demos   View files View files (13)   DownloadInstall with Composer Download .zip   Reputation   Support forum (1)   Blog (1)    
Ratings Unique User Downloads Download Rankings
Not yet rated by the usersTotal: 75 All time: 10,009 This week: 157Up
Version License PHP version Categories
phpgithub 1.3.0Free for non-comm...7PHP 5, Files and Folders, Web services, P...
Description Author

This library class provides functions to work with the GitHub API v3.

It can send a HTTP request to the GitHub API Web server to perform queries using a given API URL.

The class returns an object with several details of the API response like an:

- The API call success status
- An error that may have occurred in case it failed
- The API response data, content type and content length
- The HTTP response code
- The API server IP address

Picture of Mat Jung
  Performance   Level  
Name: Mat Jung <contact>
Classes: 3 packages by
Country: Switzerland Switzerland
Age: 46
All time rank: 404332 in Switzerland Switzerland
Week rank: 563 Up4 in Switzerland Switzerland Up
Innovation award
Innovation award
Nominee: 1x

The class has a dependency with PHP cURL If that is not working for you, the class won't work for you. Class namespace: namespace php\github; Instantiation: $hub = new php\github\phpGithub(); Optional $hub->AddCurlConfig(CURLOPT_CAINFO, "/path/to/php/curl/cacert.pem"); Sample client $response=$hub->returnRoot(); if($response->success) { echo $response->urlip ." " . $response->url ." " . $response->http_code . "<br>"; } Sample output 200 In tab Example you find a more comprehensive sample github api client
  GitHub Repository Directory TreeExternal page   Invite yourself to GitHub RepoExternal page  
  Files folder image Files  
File Role Description
Files folder imageconsumer (1 directory)
Accessible without login Plain text file ghacadduser2repo.php Example Sample invite friends to GitHub Repository
Accessible without login Plain text file githubclient.php Example Sample php client that works with phpGitHub
Accessible without login Plain text file githubclient_current_user.php Example Sample client for calling current_user_url
Accessible without login Plain text file githubclient_repository_content_tree.php Example GitHub Content Tree Walker
Accessible without login Plain text file githubclient_userprofile.php Example Example for phpGithubUser
Plain text file hubHelper.php Class class helper
Plain text file phpGithub.php Class class phpGithub
Plain text file phpGithubContent.php Class class phpGithubContent
Accessible without login Plain text file phpGithubServiceArray.php Appl. AssociativeArray gh mapping between service name and api url
Plain text file phpGithubUser.php Class class phpGithubUser Model for Github user
Plain text file phpHubResult.php Class class phpHubResult
Accessible without login Plain text file Readme Doc. Readme

  Files folder image Files  /  consumer  
File Role Description
Files folder imagejhu (1 file)

  Files folder image Files  /  consumer  /  jhu  
File Role Description
  Accessible without login Plain text file web.php Example Returns todays covid file from JHU repository

 Version Control Unique User Downloads Download Rankings  
This week:0
All time:10,009
This week:157Up