list_pull_requests
Retrieve and filter pull requests from a GitHub repository by owner, repo, state, head, base, sort, direction, and pagination for streamlined PR management.
Instructions
List and filter repository pull requests
Input Schema
Name | Required | Description | Default |
---|---|---|---|
base | No | Filter by base branch name | |
direction | No | The direction of the sort | |
head | No | Filter by head user or head organization and branch name | |
owner | Yes | Repository owner (username or organization) | |
page | No | Page number of the results | |
per_page | No | Results per page (max 100) | |
repo | Yes | Repository name | |
sort | No | What to sort results by | |
state | No | State of the pull requests to return |
Input Schema (JSON Schema)
{
"$schema": "http://json-schema.org/draft-07/schema#",
"additionalProperties": false,
"properties": {
"base": {
"description": "Filter by base branch name",
"type": "string"
},
"direction": {
"description": "The direction of the sort",
"enum": [
"asc",
"desc"
],
"type": "string"
},
"head": {
"description": "Filter by head user or head organization and branch name",
"type": "string"
},
"owner": {
"description": "Repository owner (username or organization)",
"type": "string"
},
"page": {
"description": "Page number of the results",
"type": "number"
},
"per_page": {
"description": "Results per page (max 100)",
"type": "number"
},
"repo": {
"description": "Repository name",
"type": "string"
},
"sort": {
"description": "What to sort results by",
"enum": [
"created",
"updated",
"popularity",
"long-running"
],
"type": "string"
},
"state": {
"description": "State of the pull requests to return",
"enum": [
"open",
"closed",
"all"
],
"type": "string"
}
},
"required": [
"owner",
"repo"
],
"type": "object"
}