Git
v2026.11.27Read, search and manipulate Git repositories: status, diff, log, commit, branch and more
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
git_status
Shows the working tree status
| Parameter | Type | Description |
|---|---|---|
repo_path * | string |
git_diff_unstaged
Shows changes in the working directory that are not yet staged
| Parameter | Type | Description |
|---|---|---|
repo_path * | string | |
context_lines | integer |
git_diff_staged
Shows changes that are staged for commit
| Parameter | Type | Description |
|---|---|---|
repo_path * | string | |
context_lines | integer |
git_diff
Shows differences between branches or commits, or across a revision range (main..feature, main...feature)
| Parameter | Type | Description |
|---|---|---|
repo_path * | string | |
target * | string | |
context_lines | integer |
git_commit
Records changes to the repository
| Parameter | Type | Description |
|---|---|---|
message * | string | |
repo_path * | string |
git_add
Adds file contents to the staging area
| Parameter | Type | Description |
|---|---|---|
files * | array | |
repo_path * | string |
git_reset
Unstages all staged changes
| Parameter | Type | Description |
|---|---|---|
repo_path * | string |
git_log
Shows the commit log, newest commit first. For the latest commits, pass only repo_path (and optionally max_count). start_timestamp and end_timestamp are optional filters for a date range: omit them unless a specific period is asked for, because a range that holds no commits returns none.
| Parameter | Type | Description |
|---|---|---|
repo_path * | string | |
end_timestamp | Optional: only show commits at or before this time. Omit for no upper bound. Accepts: ISO 8601 format (e.g., '2024-01-15T14:30:25'), relative dates (e.g., '2 weeks ago', 'yesterday'), or absolute date… | |
max_count | integer | Maximum number of commits to show. Must be at least 1. |
start_timestamp | Optional: only show commits at or after this time. Omit for no lower bound. Accepts: ISO 8601 format (e.g., '2024-01-15T14:30:25'), relative dates (e.g., '2 weeks ago', 'yesterday'), or absolute dates… |
git_create_branch
Creates a new branch from an optional base branch or commit
| Parameter | Type | Description |
|---|---|---|
branch_name * | string | |
repo_path * | string | |
base_branch | Branch, tag or commit SHA to create the branch from. Defaults to the current branch, or to the current commit when HEAD is detached |
git_checkout
Switches branches
| Parameter | Type | Description |
|---|---|---|
branch_name * | string | |
repo_path * | string |
git_merge
Merges a branch into the current branch. Fast-forward only unless fast_forward_only is false; refuses a dirty working tree, and aborts a merge that conflicts, leaving the repository unchanged
| Parameter | Type | Description |
|---|---|---|
repo_path * | string | |
source_branch * | string | Branch, tag or commit to merge into the current branch |
fast_forward_only | boolean | Only fast-forward, failing if the branches have diverged. False allows a merge commit |
git_show
Shows the contents of a commit, or of a file or directory given as <revision>:<path>
| Parameter | Type | Description |
|---|---|---|
repo_path * | string | |
revision * | string |
git_branch
List Git branches
| Parameter | Type | Description |
|---|---|---|
branch_type * | string | Whether to list local branches ('local'), remote branches ('remote') or all branches('all'). |
repo_path * | string | The path to the Git repository. |
contains | The commit sha that branch should contain. Do not pass anything to this param if no commit sha is specified | |
not_contains | The commit sha that branch should NOT contain. Do not pass anything to this param if no commit sha is specified |
git_remote
Lists the repository's remotes with their fetch and push URLs, like `git remote -v`. Credentials embedded in a URL's userinfo, query values or fragment are shown as <redacted>; path segments are shown as configured
| Parameter | Type | Description |
|---|---|---|
repo_path * | string | The path to the Git repository. |