GitHub hub

GitHub profile pull requests API

Page through public pull requests authored by a GitHub login — title, repo, state, created time, and URL — with optional since/until filters and cursor pagination in the shared Social Fetch envelope.

GET /v1/github/profiles/{handle}/pull-requests

1 credit per successful request.

About this endpoint

GET /v1/github/profiles/{handle}/pull-requests is the list route. Pass the GitHub login in the path and send x-api-key. Optional query params: since and until (YYYY-MM-DD created dates) and cursor from a previous page. Branch on data.lookupStatus before you write. On found, data.pullRequests is the page (it can be empty), and data.page has nextCursor and hasMore. Each item includes title, repo (owner/repo), url, nullable number when it can be read from url, and nullable state / createdAt when reported. state is GitHub's search state (open or closed); merged PRs usually appear as closed.

Use this route to inventory public PRs a user authored. For repository inventory, call GET /v1/github/profiles/{handle}/repositories. For one repository when you already have the URL, call GET /v1/github/repositories. Pricing is 1 credit per successful request; bill from meta.creditsCharged on the response.

GitHub profile pull requests API FAQ

How do I list GitHub pull requests for a profile via API?

Call GET /v1/github/profiles/{handle}/pull-requests with your Social Fetch API key (x-api-key) and the GitHub username (login) in the path. Read data.lookupStatus, then data.pullRequests and data.page. See the API docs for parameters.

How much does the GitHub profile pull requests endpoint cost?

Pricing is documented on the operation in the API registry (shown on this page). Confirm on every response with meta.creditsCharged — that field is the billing source of truth.

How does pagination work on GitHub profile pull requests?

Each response includes data.page.nextCursor and data.page.hasMore. When hasMore is true, pass nextCursor as the cursor query param on the next request. Keep the same since / until filters when you follow a cursor. The cursor is opaque.

How do I filter pull requests by created date?

Optional since returns PRs created on or after that YYYY-MM-DD date. Optional until returns PRs created on or before that date. until must be on or after since when both are set.

What does state mean on each pull request?

state is GitHub's public search state, typically open or closed. Merged pull requests usually come back as closed. number is the GitHub PR number when url is a standard /pull/{n} link. This route does not expose merged, draft, or review status.

What happens for missing GitHub logins?

Unknown handles resolve as lookupStatus not_found with an empty pull-requests array. HTTP 200 still means the request finished. Always branch on lookupStatus before treating the payload as a found list. An empty pullRequests array with found means the login resolved but this page has no public authored PRs in range.

Do I need a GitHub personal access token?

Not for Social Fetch public routes. Authenticate with your Social Fetch API key. Prefer GitHub's official API with a GitHub token for authenticated apps, webhooks, and private repos you are authorized to read.