Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Apps.ListUserRepos may return message "specify a custom media type in the 'Accept' header". #797
I know this can be fix by adding following accept header:
// in github/github.go line 85~86 // https://developer.github.com/changes/2016-09-14-Integrations-Early-Access/ mediaTypeIntegrationPreview = "application/vnd.github.machine-man-preview+json"
And it can be fix by add following to
I can provide a PR to fix this.
I noticed that there is a TODO comment in other function says that
referenced this issue
Nov 29, 2017
Hi, thanks for reporting this.
I've taken a look at the documentation for that endpoint at https://developer.github.com/v3/apps/installations/#list-repositories-accessible-to-the-user-for-an-installation and was surprised to find that it doesn't mention anything about a custom Accept header there.
I'd really like to be able to confirm that adding that header is the right fix via documentation.
After digging further, I found PR #436 which mentioned https://developer.github.com/changes/2016-09-14-Integrations-Early-Access/, which includes:
So I think that confirms this is the right thing to do.