How can I use the GitHub login in Visual Studio to access the GitHub APIs through a custom Visual Studio extension?


I am currently using Azure Devops Server (on-prem) with a custom Visual Studio extension that simplifies remote branch management and pull request management via the Azure Devops API and integrated authentication.

We are investigating moving to GitHub Enterprise (cloud) and are having trouble figuring out any way to maintain this functionality without having to manually enter a token in the configuration and then figure out some way to securely store it.

Ideally, we’d like to be able to use the built in keychain functionality that Visual Studio has for holding a GitHub Enterprise login and use that account for requesting remote branch management and pull request creation, but I can’t find anyway to access this information in a usable way from our custom Visual Studio extension.

What is the best way to access the GitHub Enterprise APIs from a custom Visual Studio extension in a secure manner?

Leave a Reply

Your email address will not be published. Required fields are marked *