Every Confluence user needs to be authorized to access a private GitHub repository to see content from this repository.
When including content from private repositories, you will get the following message in place of the content:
Once the page is published, the users can authenticate with GitHub by clicking on the Authenticate yourself link.
If the user is already authenticated, all content included from repositories the user has access to in GitHub will be visible.
It may be necessary to authenticate regularly given GitHub does not provide refresh tokens.