list_forge_pull_requests
List a repository's pull requests through the forge connection for its host, a page at a time: every one opened from a branch when one is named, whatever its state, or the open ones when none is.
Forgeread-onlyidempotentMCP tool
Give the repository as a git remote spells it, and pass the next_page_token back as pagination.cursor for the next page. A repository the connection's credential cannot see is answered as not found, which is also what a repository that does not exist answers. This asks the forge itself; list_pull_requests reads what komrad has stored.
Calling it#
curl -X POST http://127.0.0.1:8787/forge.v1.ForgeService/ListForgePullRequests \
-H 'Content-Type: application/json' \
-d '{
"remoteUrl": "<remoteUrl>"
}'komrad rpc list-forge-pull-requests \
--remote-url <string>{
"name": "list_forge_pull_requests",
"arguments": {
"remoteUrl": "<remoteUrl>"
}
}Offered by the komrad MCP server to orchestrator agents.
Request#
ListForgePullRequestsRequest#
| Field | Type | Description |
|---|---|---|
remoteUrl | string | The repository as a git remote spells it, such as git@github.com:owner/repo.git or https://github.com/owner/repo, whose host picks the forge connection. required, at most 2048 characters |
branch | string | The branch the pull requests were opened from, listed whatever their state; left empty, the repository's open pull requests are listed instead. at most 512 characters |
pagination | Pagination | Which page to read and how many to a page, twenty when unset and at most a hundred, which is what the forge will hand over in one call. |
Response#
ListForgePullRequestsResponse#
| Field | Type | Description |
|---|---|---|
pullRequests | list of ForgePullRequest | One page of pull requests, as the forge orders them. |
nextPageToken | string | The token for the page after this one, unset on the last. |
Types#
Pagination#
ForgePullRequest#
ForgePullRequest is a pull request as the forge describes it, read live and stored nowhere.
| Field | Type | Description |
|---|---|---|
forge | string | Which forge it lives on, such as github. |
providerId | string | The forge's own stable identifier, such as GitHub's node_id. |
url | string | The web address a person opens. |
repositoryUrl | string | The canonical address of the repository it targets. |
headRepositoryUrl | string | The canonical address of the repository its branch lives in, empty when the forge no longer has it. |
number | int32 | The number the forge shows a person, which is per repository. |
title | string | The title as the forge has it. |
headBranch | string | The branch the pull request was opened from. |
headSha | string | The commit at the tip of that branch when last read. |
baseBranch | string | The branch it targets. |
baseSha | string | The commit the target branch was at when last read. |
draft | bool | Whether the forge marks it a draft. |
state | string | Where the forge says it stands, as OPEN, CLOSED or MERGED; read merged_at and closed_at for whether it is finished. |
createdAt | string | When it was opened on the forge, in RFC 3339. |
updatedAt | string | When the forge last saw it change, in RFC 3339. |
mergedAt | string | When it merged, in RFC 3339, unset while it has not. |
closedAt | string | When it closed, in RFC 3339, unset while it is open; a merged one carries this too. |