forge-cpp-mcp

v0.5.1
forge-cpp-mcp Checked 1 day ago Published 29 days ago

A safe MCP server for structured C++ project development workflows.

These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.

workspace_list

Show a directory tree; null depth expands every directory. File paths are errors. include_hidden controls dot directories; dot files remain visible and links are listed without traversal.

ParameterTypeDescription
depth
include_hiddenboolean
pathstring

workspace_find_files

Find file paths recursively by case-sensitive glob, skipping dot directories and links. Patterns without / match basenames; patterns with / match paths relative to the search directory.

ParameterTypeDescription
pathstring
patternstring

workspace_file_info

Read creation/modification times, byte size, and owner of one file.

ParameterTypeDescription
path *string

workspace_read_file

Read UTF-8 text, optionally selecting an inclusive range of one-based lines.

ParameterTypeDescription
path *string
end_line
start_lineinteger

workspace_write_file

Create or fully overwrite a UTF-8 file; its parent directory must exist. Return removed/added line counts and linked change resources.

ParameterTypeDescription
path *string
text *string

workspace_edit_file

Replace one exact text occurrence, or all with replace_all=true. old_text must be nonempty. Missing or ambiguous matches leave the file unchanged. Text and line endings outside replacements are preserved.

ParameterTypeDescription
new_text *string
old_text *string
path *string
replace_allboolean

workspace_move

Move a file or directory within project/ or within storage/. The destination must not exist, and its parent directory must exist.

ParameterTypeDescription
destination *string
source *string

workspace_delete

Delete a file or empty directory; protected paths and roots cannot be deleted.

ParameterTypeDescription
path *string

workspace_mkdir

Create a directory and missing parents, or report that it already exists.

ParameterTypeDescription
path *string

processes_overview

Show current and completed external processes managed by ForgeMCP.

ParameterTypeDescription
statusstring

process_get

Read a log slice: time, then lines, then UTF-8 text bytes. With neither selector, return the last 100 lines. Line ranges are inclusive; time ranges are [start, end) seconds from process start. Last seconds end at now for running processes, at completion otherwise. Returned line numbers remain absolute; a byte limit can cut a line.

ParameterTypeDescription
process_id *integer
linesChoose exactly one object form: {"first": N}, {"last": N}, or {"start": A, "end": B}, with no extra fields. All values are integers >= 1; ranges require A <= B and include both ends.
max_bytesinteger
timeChoose exactly one object form: {"first": N}, {"last": N}, or {"start": A, "end": B}, with no extra fields. Values are finite seconds from process start; N > 0, 0 <= A < B, and the end is excluded.

toolsets_list

List all discovered toolsets and the tools available in each.

toolset_get

Read tool paths and kinds, querying available versions for this request.

ParameterTypeDescription
toolset_id *string

cmake_profiles

List effective profiles and their toolsets, build settings, and preset selections.

cmake_configure

Configure selected profiles; return build/database paths and per-execution errors. Changing a manual profile's generator removes and recreates its build directory.

ParameterTypeDescription
profiles
timeout

cmake_build

Build selected profiles and their build presets after configuration. Omitted targets use CMake or preset defaults; a nonempty targets list selects explicit build targets.

ParameterTypeDescription
parallel
profiles
targets
timeout

cmake_test

Run CTest for selected profiles and test presets after building; return test cases. names selects exact test names, not regex patterns; omit it to use CTest or preset defaults.

ParameterTypeDescription
names
parallel
profiles
timeout

cmake_run_test

Run one project/storage test executable directly with literal command-line arguments. Inherits the server environment; cwd defaults to project/. Zero exit means success. No profiles, CTest properties, or case reports are used. Read output through process_get with the returned process_id.

ParameterTypeDescription
executable *string
arguments
cwdstring
timeout

clangd_configurations

List CMake contexts with an existing compilation database and clangd.

clangd_diagnostics

Get fresh file diagnostics in selected configurations. Omitted or empty configurations select all available contexts.

ParameterTypeDescription
path *string
configurationsarray
timeoutnumber

clangd_hover

Describe the symbol at a one-based line and zero-based code-point position. Omitted or empty configurations select all available contexts.

ParameterTypeDescription
path *string
position *
configurationsarray
timeoutnumber

clangd_definition

Find definitions of the symbol at the supplied position. External locations use root/. Empty configurations select all.

ParameterTypeDescription
path *string
position *
configurationsarray
timeoutnumber

clangd_references

Find references to the symbol in selected configurations. Omitted or empty configurations select all available contexts.

ParameterTypeDescription
path *string
position *
configurationsarray
include_declarationboolean
timeoutnumber

clangd_document_symbols

List file symbols in selected configurations. Omitted or empty configurations select all available contexts.

ParameterTypeDescription
path *string
configurationsarray
timeoutnumber

clangd_workspace_symbols

Find workspace symbols in selected configurations. Omitted or empty configurations select all available contexts.

ParameterTypeDescription
query *string
configurationsarray
timeoutnumber

git_status

Inspect branch, index/worktree changes, and unfinished Git operations.

git_diff

Compare index/worktree or revisions with native patches and typed file metadata.

ParameterTypeDescription
base
contextinteger
modestring
paths
target

git_log

Read a bounded commit page; reuse its resolved revision for later pages.

ParameterTypeDescription
limitinteger
path
revisionstring
skipinteger

git_show

Read a commit and its first-parent patch, including root commits.

ParameterTypeDescription
revisionstring

git_blame

Attribute a committed UTF-8 file or inclusive line range to its commits.

ParameterTypeDescription
path *string
end_line
revisionstring
start_lineinteger

git_branches

List local and remote-tracking branches with upstream and current-branch metadata.

git_tags

List lightweight and annotated tag references without changing them.

git_remotes

List configured remotes with credential-redacted fetch/push URLs.

git_stage

Stage explicit literal paths, including additions, modifications, and deletions.

ParameterTypeDescription
paths *array

git_unstage

Unstage explicit paths while preserving working files, including unborn HEAD.

ParameterTypeDescription
paths *array

git_commit

Commit the current index with a supplied message and normal repository hooks.

ParameterTypeDescription
message *string
amendboolean

git_restore

Restore selected working files from the index or an explicit commit.

ParameterTypeDescription
paths *array
source

git_branch

Create a branch or delete one, requiring explicit force for unmerged deletion.

ParameterTypeDescription
action *string
name *string
forceboolean
start_pointstring

git_switch

Switch or create a branch without force or automatic stash.

ParameterTypeDescription
branch *string
createboolean
start_point

git_stash

List, save, apply, pop, or drop stashes without automatically hiding other edits.

ParameterTypeDescription
action *string
include_untrackedboolean
message
referencestring

git_fetch

Fetch one configured remote; remote-tracking pruning is explicit.

ParameterTypeDescription
pruneboolean
remotestring

git_pull

Pull without auto-stash; fast-forward only is the default integration strategy.

ParameterTypeDescription
branch
remote
strategystring

git_push

Push HEAD to one branch; replacing history requires the expected remote OID.

ParameterTypeDescription
branch
expected_remote_oid
remotestring
set_upstreamboolean

git_merge

Merge one commit, preserving conflicts for explicit resolution and continuation.

ParameterTypeDescription
revision *string
message

git_rebase

Rebase onto one resolved commit without interactive editing or automatic stash.

ParameterTypeDescription
revision *string

git_cherry_pick

Cherry-pick an explicit ordered commit list with resumable conflict state.

ParameterTypeDescription
revisions *array
mainline

git_revert

Revert an ordered commit list without opening an editor.

ParameterTypeDescription
revisions *array
mainline

git_conflicts

Read base/ours/theirs index stages without resolving conflicts.

ParameterTypeDescription
paths

git_continue

Continue, abort, or skip a stopped operation after explicitly staging resolutions.

ParameterTypeDescription
action *string
operation

debugger_adapters

List implemented adapters by toolset without probing executables.

debugger_sessions

List a bounded window of retained debugger session snapshots.

ParameterTypeDescription
page

debugger_get

Read one cached session state without contacting the debugger.

ParameterTypeDescription
session_id *string

debugger_launch

Launch a project/storage native executable with initial breakpoints.

ParameterTypeDescription
options *
toolset_id *string
adapterstring
initial
timeout

debugger_attach

Attach to an explicit local PID and configure initial breakpoints.

ParameterTypeDescription
options *
toolset_id *string
adapterstring
initial
timeout

debugger_open_dump

Open a project/storage user-mode crash dump for inspection.

ParameterTypeDescription
options *
toolset_id *string
adapterstring
timeout

debugger_breakpoints

Replace every source-line breakpoint for one managed source file.

ParameterTypeDescription
points *array
session_id *string
source *string
timeout

debugger_function_breakpoints

Replace the function breakpoint names when the adapter supports them.

ParameterTypeDescription
functions *array
session_id *string
timeout

debugger_exception_breakpoints

Select exception stop filters advertised by the current session.

ParameterTypeDescription
filters *array
session_id *string
timeout

debugger_continue

Continue from an expected stop; wait using the returned execution reference.

ParameterTypeDescription
session_id *string
stop *
timeout

debugger_step

Step over, into, or out in one stopped thread.

ParameterTypeDescription
kind *
session_id *string
stop *
thread *
timeout

debugger_pause

Request a running program to stop without closing its session.

ParameterTypeDescription
session_id *string
timeout

debugger_threads

List the current bounded thread identities.

ParameterTypeDescription
session_id *string
timeout

debugger_stack

Read a stack page from the expected suspended generation.

ParameterTypeDescription
session_id *string
stop *
thread *
page
timeout

debugger_scopes

List the variable scopes belonging to a retained stack frame.

ParameterTypeDescription
frame *
session_id *string
timeout

debugger_variables

Read a page of locals, arguments, or object children.

ParameterTypeDescription
reference *
session_id *string
page
timeout

debugger_modules

Read a page of loaded modules and available symbol information.

ParameterTypeDescription
session_id *string
page
timeout

debugger_exception_info

Inspect exception details for the current stopped thread.

ParameterTypeDescription
session_id *string
stop *
thread *
timeout

debugger_read_memory

Read a bounded memory range, preserving missing dump memory explicitly.

ParameterTypeDescription
count *integer
offset *integer
reference *
session_id *string
timeout

debugger_disassemble

Read a bounded sequence of instructions at an opaque memory reference.

ParameterTypeDescription
count *integer
offset *integer
reference *
session_id *string
timeout

debugger_close

Close by terminating a launched target, detaching, or releasing a dump.

ParameterTypeDescription
session_id *string
timeout

debugger_wait

Wait for a stop or terminal observation; timeout leaves the target running.

ParameterTypeDescription
execution *
session_id *string
timeout