1234567891011121314151617181920212223 |
- <?php namespace Client;
- class GogsAPI {
- use \Lib\Curl;
- public function __construct($api_url, $api_token) {
- $this->url = $api_url;
- $this->token = $api_token;
- }
- public function user($name = "") {
- return new Request\User($this->url, $this->token, $name);
- }
- public function repos($user = "") {
- if ($user == "")
- return $this->user()->get("/repos");
- }
- public function __destruct() {}
- }
- ?>
|