Skip to content

Commit 4f7b2e6

Browse files
committed
Merge pull request octokit#218 from guilro/pull-request-filter
Add pull request filter by head and base
2 parents 4c1b742 + f4ae869 commit 4f7b2e6

File tree

3 files changed

+6
-0
lines changed

3 files changed

+6
-0
lines changed

api/v3.0.0/pullRequests.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@ var pullRequests = module.exports = {
3030
* - user (String): Required.
3131
* - repo (String): Required.
3232
* - state (String): Optional. open, closed, or all Validation rule: ` ^(open|closed|all)$ `.
33+
* - head (String): Optional. Filter pulls by head user and branch name in the format of user:ref-name. Example: github:new-script-format.
34+
* - base (String): Optional. Filter pulls by base branch name. Example: gh-pages.
3335
* - page (Number): Optional. Page number of the results to fetch. Validation rule: ` ^[0-9]+$ `.
3436
* - per_page (Number): Optional. A custom page size up to 100. Default is 30. Validation rule: ` ^[0-9]+$ `.
3537
* - sort (String): Optional. Possible values are: `created`, `updated`, `popularity`, `long-running`, Default: `created` Validation rule: ` ^(created|updated|popularity|long-running)$ `.

api/v3.0.0/pullRequestsTest.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,8 @@ describe("[pullRequests]", function() {
3131
{
3232
user: "String",
3333
repo: "String",
34+
base: "String",
35+
head: "String",
3436
state: "String",
3537
page: "Number",
3638
per_page: "Number"

api/v3.0.0/routes.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1624,6 +1624,8 @@
16241624
"invalidmsg": "open, closed, all, default: open",
16251625
"description": "open, closed, or all"
16261626
},
1627+
"$head": null,
1628+
"$base": null,
16271629
"$page": null,
16281630
"$per_page": null,
16291631
"sort": {

0 commit comments

Comments
 (0)