I'm our site's GHE appliance administrator, and I'm trying to help clean up our repos.
I can see how to use the API to make another user's public repo's private by generating an impersonation authorization token, and editing the repo with the new token. However, this only works for active users.
I'd like to do the same with the public repos on our suspended users. This is do-able via the GUI, but I cannot see the way to do this via the api. I can delete the user entirely, but I would like to just change their repos to private before we wait a while to delete them to give anyone who is accessing them a chance to notify us.
Is this possible, or am I going to have to script interacting with the GUI frontend instead?
Thank you for being here and please accept my sincere apologies for our in delay in response. As far as I know there is no dedicated API to accomplish this. I've taken your post and passed it along as feedback to the appropriate teams.
Mark helpful posts with Accept as Solution to help other users locate important info. Don't forget to give Kudos for great content!