@param string $username
@param string $repository
@param int    $page

@return array|string

@see https://developer.github.com/v3/activity/events/#list-repository-events
760171
public function events($username, $repository, $page = 1)
    {
        return $this->get('/repos/'.rawurldecode($username).'/'.rawurldecode($repository).'/events', ['page' => $page]);
    }
374575
public function check($username, $repository, $collaborator)
    {
        return $this->get('/repos/'.rawurlencode($username).'/'.rawurlencode($repository).'/collaborators/'.rawurlencode($collaborator));
    }
202097
public function getRemovedMessages(User $user, $search = '', $page = 1)
    {
        $query = $search === '' ?
            $this->userMessageRepo->findRemoved($user, false):
            $this->userMessageRepo->findRemovedByObjectOrSender($user, $search, false);

        return $this->pagerFactory->createPager($query, $page);
    }
63686
public function getUsersList($page = 1)
    {
        $this->checkPageNumber($page);

        return $this->adapter->get(sprintf('/users?page=%d', $page));
    }
861182
public function findPageBy($page, $rpp, array $criteria = [], array $orderBy = null, $hydrateMode = AbstractQuery::HYDRATE_OBJECT)
    {
        $qb = $this->createPaginatedQueryBuilder($criteria, null, $orderBy);
        $qb->addSelect($this->getEntityAlias());
        $this->processOrderBy($qb, $orderBy);
        $qb->addPagination($page, $rpp);

        $results = $qb->getQuery()->getResult($hydrateMode);
        $total = $this->countBy($criteria);

        return new PaginatedArrayCollection($results, $page, $rpp, $total);
    }
492247
public function create($username, $repository, array $params)
    {
        if (!isset($params['title'])) {
            throw new MissingArgumentException('title');
        }
        if (isset($params['state']) && !in_array($params['state'], ['open', 'closed'])) {
            $params['state'] = 'open';
        }

        return $this->post('/repos/'.rawurlencode($username).'/'.rawurlencode($repository).'/milestones', $params);
    }
280097
public function unlock($username, $repository, $id)
    {
        return $this->delete('/repos/'.rawurlencode($username).'/'.rawurlencode($repository).'/issues/'.rawurlencode($id).'/lock');
    }
774504
public function usersGroups($page = null, $limit = null)
    {
        $parameters = [];

        if (null !== $page) {
            $parameters['page'] = (int)$page;
        }
        if (null !== $limit) {
            $parameters['limit'] = (int)$limit;
        }

        /** @noinspection PhpUndefinedMethodInspection */
        return $this->client->makeRequest(
            '/user-groups',
            "GET",
            $parameters
        );
    }
840932
public function all($username, $repository, $issue = null)
    {
        if ($issue === null) {
            $path = '/repos/'.rawurlencode($username).'/'.rawurlencode($repository).'/labels';
        } else {
            $path = '/repos/'.rawurlencode($username).'/'.rawurlencode($repository).'/issues/'.rawurlencode($issue).'/labels';
        }

        return $this->get($path);
    }
1194210
public function update($username, $repository, $id, array $params)
    {
        if (isset($params['state']) && !in_array($params['state'], ['open', 'closed'])) {
            $params['state'] = 'open';
        }

        return $this->patch('/repos/'.rawurlencode($username).'/'.rawurlencode($repository).'/milestones/'.rawurlencode($id), $params);
    }
1087132
public function create($username, $repository, array $params)
    {
        if (!isset($params['tree']) || !is_array($params['tree'])) {
            throw new MissingArgumentException('tree');
        }

        if (!isset($params['tree'][0])) {
            $params['tree'] = [$params['tree']];
        }

        foreach ($params['tree'] as $key => $tree) {
            if (!isset($tree['path'], $tree['mode'], $tree['type'])) {
                throw new MissingArgumentException(["tree.$key.path", "tree.$key.mode", "tree.$key.type"]);
            }

            // If `sha` is not set, `content` is required
            if (!isset($tree['sha']) && !isset($tree['content'])) {
                throw new MissingArgumentException("tree.$key.content");
            }
        }

        return $this->post('/repos/'.rawurlencode($username).'/'.rawurlencode($repository).'/git/trees', $params);
    }
603336
public function show($username, $repository, $sha, $recursive = false)
    {
        return $this->get('/repos/'.rawurlencode($username).'/'.rawurlencode($repository).'/git/trees/'.rawurlencode($sha), $recursive ? ['recursive' => 1] : []);
    }
119792
public function UserAnimeList(string $username, int $page = 1, int $status = 7): array
    {
        return $this->myanimelist->getUserAnimeList(
            new Request\User\UserAnimeListRequest($username, $page, $status)
        );
    }
393050
public function remove($username, $repository, $id)
    {
        return $this->delete('/repos/'.rawurlencode($username).'/'.rawurlencode($repository).'/milestones/'.rawurlencode($id));
    }
1158047
public function getVisibleUsers($page)
    {
        $roleSuperAdmin = 'ROLE_SUPER_ADMIN';

        if ($this->securityContext->isGranted($roleSuperAdmin)) {
            $entities = $this->userManager->findPaginateUsers($page);
        } else {
            $entities = $this->userManager->findPaginateUsersExcludingRole($roleSuperAdmin, $page);
        }

        return $entities;
    }
949106
public function getUserByUsername($username)
    {
        $return = array();

        $users = $this->repository->users;
        foreach ($users as $user) {
            if ($user->username == $username) {
                $return = $user;
                break;
            }
        }

        return $return;
    }
1326543
public function show($username, $repository, $label)
    {
        return $this->get('/repos/'.rawurlencode($username).'/'.rawurlencode($repository).'/labels/'.rawurlencode($label));
    }