| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
Return compact response shapes for pull request statuses, review comment replies, and individual workflow runs. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> Copilot-Session: d6786153-698a-4563-97ad-a8221c40e306
There was a problem hiding this comment.
Reduces tool response payloads while retaining identifiers, diagnostics, and follow-up links.
Changes:
| File | Description |
|---|---|
| pkg/github/pullrequests.go | Returns minimal status and reply responses. |
| pkg/github/pullrequests_test.go | Verifies compact status and reply serialization. |
| pkg/github/minimal_types.go | Adds minimal commit-status types and converters. |
| pkg/github/actions.go | Uses the minimal workflow-run response. |
| pkg/github/actions_test.go | Verifies compact workflow-run serialization. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Summary
Return compact successful responses for pull request statuses, pull request review comment replies, and individual Actions workflow runs while preserving identifiers, diagnostics, and human-facing links needed for follow-up work.
Why
Several successful tool responses include SDK transport metadata and nested objects that are not needed for diagnosis or supported follow-up calls. Focused contracts reduce response payload size without changing input schemas.
What changed
Response contracts and estimated size
The estimates below compare minified JSON generated from representative SDK and test fixtures before and after this change. Exact savings vary with populated optional fields and content length.
pull_request_read.get_status
Retained combined-status fields: state, sha, total_count, and statuses.
Dropped combined-status fields: name, commit_url, and repository_url.
Retained fields for each status: state, context, description, target_url, created_at, and updated_at.
Dropped fields for each status: id, node_id, url, avatar_url, and creator. The human-facing target_url remains available; only the REST transport url is removed.
add_reply_to_pull_request_comment
Retained output fields for a newly created reply: id as a string and url populated from the comment's human-facing html_url. The reaction-only path was already minimal and is unchanged; body-plus-reaction responses now contain minimal comment and reaction objects.
Dropped reply-comment fields: node_id, in_reply_to_id, body, path, diff_hunk, pull_request_review_id, position, original_position, start_line, line, original_line, original_start_line, side, start_side, commit_id, original_commit_id, user, reactions, created_at, updated_at, author_association, the REST transport url, pull_request_url, and subject_type. The source html_url key is replaced by the minimal response's url key rather than losing its value.
actions_get.get_workflow_run
Retained fields: id, name, display_title, workflow_id, run_number, run_attempt, event, status, conclusion, head_branch, head_sha, path, html_url, created_at, updated_at, and run_started_at.
Retained nested data: head_commit.message; pull request numbers in pull_requests; compact actor and triggering_actor values containing login, id, profile_url, and avatar_url; and referenced workflow path, sha, and ref values.
Dropped fields: node_id, check_suite_id, check_suite_node_id, url, jobs_url, logs_url, check_suite_url, artifacts_url, cancel_url, rerun_url, previous_attempt_url, workflow_url, full repository and head_repository objects, all pull request fields except number, actor fields outside the compact identity above, and all head-commit fields except message.
MCP impact
Successful response bodies for the three methods above are smaller. Their input schemas and error behavior are unchanged.
Prompts tested (tool changes only)
Security / limits
Responses intentionally omit unused metadata while retaining identifiers needed by supported follow-up operations.
Tool renaming
Note: if you're renaming tools, you must add the tool aliases. For more information on how to do so, please refer to the official docs.
Lint & tests
Docs