-
Notifications
You must be signed in to change notification settings - Fork 75
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add authenticated user list repo #256
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks good to me, thanks!
* | ||
* @param accessToken to identify the authenticated user | ||
* @param headers optional user headers to include in the request | ||
* @param visiblility can be all, public, private |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
* @param visiblility can be all, public, private | |
* @param visibility can be all, public, private |
): M[GHResponse[List[Repository]]] = | ||
httpClient.get[List[Repository]]( | ||
accessToken, | ||
s"user/repos", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
s"user/repos", | |
"user/repos", |
def listAuthenticatedUserRepos( | ||
accessToken: Option[String] = None, | ||
headers: Map[String, String] = Map(), | ||
visibility: Option[String] = None, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
visibility
and affiliation
aren't being used within this request. Add them to the request query params like in listCommits
endpoint. Keep in mind that you can't mix them with type
param or github would return a 422 error.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The API has changed a fair bit since this PR was opened. As a result I'm closing this, feel free to open a new PR 👍
Add support for endpoint
/user/repos
as described in https://developer.github.com/v3/repos/#list-your-repositories .