Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Github Api Laravel Package

knplabs/github-api

Lightweight, well-tested PHP wrapper for GitHub APIs v3 (REST) and v4 (GraphQL). PSR-17/PSR-18 compatible via HTTPlug, with easy setup using Guzzle, Symfony HttpClient, or other PSR clients. Supports framework integrations (Laravel via graham-campbell/github).

View on GitHub
Deep Wiki
Context7

Users API

Back to the navigation

Searching users, getting user information and managing authenticated user account information. Wrap GitHub User API.

Search for users by keyword

Use the Search API to find users by keyword.

Lists all users, in the order they signed up, since the last user you've seen

$users = $client->api('user')->all(135);

Returns an array of all users that registered after the user whose ID is 135.

Lists all users, in the order they signed up

$users = $client->api('user')->all();

Returns an array of all users.

Get information about a user

$user = $client->api('user')->show('KnpLabs');

Returns an array of information about the user.

You can also use the User ID, but it will use an undocumented GitHub API

$user = $client->api('user')->showById(202732);

Update user information

Requires authentication.

Change user attributes: name, email, blog, company, location.

$client->api('current_user')->update(array(
    'location' => 'France',
    'blog'     => 'http://diem-project.org/blog'
));

Returns an array of information about the user.

Get users that a specific user is following

$users = $client->api('user')->following('KnpLabs');

Returns an array of followed users.

For authenticated user use.

Requires authentication.

$users = $client->api('current_user')->follow()->all();

Get users following a specific user

$users = $client->api('user')->followers('KnpLabs');

Returns an array of following users.

For authenticated user use.

Requires authentication.

$users = $client->api('current_user')->followers();

Follow a user

Requires authentication.

Make the authenticated user follow a user.

$client->api('current_user')->follow()->follow('symfony');

Returns an array of followed users.

Unfollow a user

Requires authentication.

Make the authenticated user unfollow a user.

$client->api('current_user')->follow()->unfollow('symfony');

Returns an array of followed users.

Get repos that a specific user is watching

See more.

$users = $client->api('user')->watched('ornicar');

For authenticated user use.

Requires authentication.

$users = $client->api('current_user')->watchers()->all();

Returns an array of watched repos.

Get repos that a specific user has starred

See more.

$users = $client->api('user')->starred('ornicar');

For authenticated user use.

Requires authentication.

$users = $client->api('current_user')->starring()->all();

Returns an array of starred repos.

Get the authenticated user activity

Requires authentication.

$activity = $client->api('user')->events('ornicar');

Returns an array of private and public events created for all repos related to the user.

See more.

Get the authenticated user emails

Requires authentication.

$emails = $client->api('current_user')->emails()->all();

Returns an array of the authenticated user emails.

Add an email to the authenticated user

Requires authentication.

$emails = $client->api('current_user')->emails()->add('my-email@provider.org');
// or add few emails at once
$emails = $client->api('current_user')->emails()->add(array('first@provider.org', 'second@provider.org'));

Returns an array of the authenticated user emails.

Remove an email from the authenticated user

Requires authentication.

$emails = $client->api('current_user')->emails()->remove('my-email@provider.org');
// or remove few emails at once
$emails = $client->api('current_user')->emails()->remove(array('first@provider.org', 'second@provider.org'));

Return an array of the authenticated user emails.

Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
davejamesmiller/laravel-breadcrumbs
artisanry/parsedown
christhompsontldr/phpsdk
bower-asset/punycode
bower-asset/inputmask
bower-asset/jquery
bower-asset/yii2-pjax
laravel/nova
spatie/laravel-mailcoach
spatie/laravel-superseeder
laravel/liferaft
nst/json-test-suite
danielmiessler/sec-lists
jackalope/jackalope-transport
twbs/bootstrap4
php-http/client-implementation
phpcr/phpcr-implementation
cucumber/gherkin-monorepo
haydenpierce/class-finder
psr/simple-cache-implementation