Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -1205,6 +1205,17 @@ The following sets of tools are available:
- `repo`: Repository name (string, required)
- `sha`: Commit SHA, branch name, or tag name (string, required)

- **get_file_blame** - Get file blame information
- **Required OAuth Scopes**: `repo`
- `after`: Cursor for pagination. Use the endCursor from the previous page's PageInfo for GraphQL APIs. (string, optional)
- `end_line`: Optional 1-based ending line of the window of interest. Must be >= start_line when both are provided. (number, optional)
- `owner`: Repository owner (username or organization) (string, required)
- `path`: Path to the file in the repository, relative to the repository root (string, required)
- `perPage`: Results per page for pagination (min 1, max 100) (number, optional)
- `ref`: Git reference (branch, tag, or commit SHA). Defaults to the repository's default branch (HEAD). (string, optional)
- `repo`: Repository name (string, required)
- `start_line`: Optional 1-based starting line of the window of interest. Only ranges overlapping [start_line, end_line] are returned, clamped to the window. (number, optional)

- **get_file_contents** - Get file or directory contents
- **Required OAuth Scopes**: `repo`
- `owner`: Repository owner (username or organization) (string, required)
Expand Down
54 changes: 54 additions & 0 deletions pkg/github/__toolsnaps__/get_file_blame.snap
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
{
"annotations": {
"readOnlyHint": true,
"title": "Get file blame information"
},
"description": "Get git blame information for a file, showing the commit that last modified each line. Ranges share commit metadata via the top-level 'commits' map keyed by SHA. Use 'start_line'/'end_line' to restrict the result to a window of the file, and 'perPage'/'after' to cursor-page through returned ranges. Matching ranges are capped at 1000; when the cap is hit 'truncated' is set to true and 'total_ranges' reports the pre-cap match count.",
"inputSchema": {
"properties": {
"after": {
"description": "Cursor for pagination. Use the endCursor from the previous page's PageInfo for GraphQL APIs.",
"type": "string"
},
"end_line": {
"description": "Optional 1-based ending line of the window of interest. Must be \u003e= start_line when both are provided.",
"minimum": 1,
"type": "number"
},
"owner": {
"description": "Repository owner (username or organization)",
"type": "string"
},
"path": {
"description": "Path to the file in the repository, relative to the repository root",
"type": "string"
},
"perPage": {
"description": "Results per page for pagination (min 1, max 100)",
"maximum": 100,
"minimum": 1,
"type": "number"
},
"ref": {
"description": "Git reference (branch, tag, or commit SHA). Defaults to the repository's default branch (HEAD).",
"type": "string"
},
"repo": {
"description": "Repository name",
"type": "string"
},
"start_line": {
"description": "Optional 1-based starting line of the window of interest. Only ranges overlapping [start_line, end_line] are returned, clamped to the window.",
"minimum": 1,
"type": "number"
}
},
"required": [
"owner",
"repo",
"path"
],
"type": "object"
},
"name": "get_file_blame"
}
Loading