cody icon indicating copy to clipboard operation
cody copied to clipboard

Reviewers API

Open aergonaut opened this issue 9 years ago • 1 comments

Some users might want to have other sources for adding reviewers. Maybe an external service that runs security and vulnerability checks on PRs and adds appropriate reviewers depending on the result of the scan. We can't anticipate all the ways users might want to add reviewers so instead we should add an API to allow external services to access and update the review list.

This should have a few endpoints:

  • GET /repo/:repo/pulls/:number/reviewers
    • Retrieve the current list of reviewers for a PR
  • PATCH /repo/:repo/pulls/:number/reviewers
    • Add the specified reviewers to the current list of reviewers
  • PUT /repo/:repo/pulls/:number/reviewers
    • Replace the current list of reviewers with the specified list of reviewers

The :number key should be the PR number from GitHub while :repo should be the full name-with-owner GitHub repository identifier.

Other considerations:

  • Authorization: probably via tokens
  • API versioning: HTTP headers (assess if this is really necessary from the start)

aergonaut avatar Apr 05 '16 19:04 aergonaut

This API should be GraphQL instead of REST

aergonaut avatar Jul 11 '17 19:07 aergonaut