githubgithub-apigithub-enterprisegithub-api-v3

How to query Github enterprise using REST


I would like to know how do we connect to enterprise version of github and access multiple data like , organization settings, users, repositories etc.,

I can find in google that we can access open github details using endpoint

https://api.github.com/

how about access my Enterprise version ? considering enterprise name "test". I can login into it through web using
"https://github.com/enterprises/test/people"

Can you please help me in pointing a REST guide or example to access data please.

I tried using https://api.github.com/enterprises/test but no luck

kindly help


Solution

  • We need to pass an valid access token

    To query Users :

    https://api.github.com/user/orgs

    To query members in an organization. were {organization} is the organization name case sensitive

    https://api.github.com/orgs/{organization}/members