We are using the GitHub API on Stack Overflow Careers to bring in a user's repositories. We haven't succeeded in bringing in a user's repositories that are part of an organization.
For example, wycats is a contributor to the jQuery project. Yet querying his repositories via the API does not indicate this -- the jQuery repo is owned by the jQuery organization.
What is the API call(s) to learn that wycats is a contributor to the jQuery repository? The correct answer will take the form of a URL(s) which returns a list of organization repositories for a given user name. If it takes more than one call, that's fine.
Thanks!
How To List All Public Repositories Belonging to a User? So, to list all public repos from a user, send a GET request to https://api.github.com/users/<USER-NAME>/repos , replacing with the actual user from whom you want to retrieve the repositories.
To access an organization that you're a member of, you must sign in to your personal account. Tip: Only organization owners can see and change the account settings for an organization. In the top right corner of GitHub.com, click your profile photo, then click Your organizations. Click the name of your organization.
(1) Right click inside the folder you want all of the repos to clone to (2) select "Git Bash Here" - Bash window will open (3) Edit the script with your org name, then copy and paste it into the bash window (maybe make sure line endings are unix based, not sure, I did just to be safe). (4) it should start running.
Find an existing repo You can find repos in two ways: Type “14ers-git” in the github.com search bar to find the repository.
I think this is what you're looking for.
Checking Organization Membership
/user/show/:user/organizations [GET]
https://github.com/api/v2/json/user/show/wycats/organizations
List all public repositories of any organization
/organizations/:org/public_repositories [GET]
https://github.com/api/v2/json/organizations/jquery/public_repositories
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With