Add JSON output to vMCP validation - #6381
Open
Whxuan0701 wants to merge 1 commit into
Open
Conversation
Expose a stable, secret-free validation summary so CI and Agent harnesses can consume vMCP validation results without parsing human-readable logs. Preserve the existing text behavior while adding format validation, focused tests, and generated CLI documentation. Signed-off-by: XD <xd@XDdeMacBook-Pro.local>
Whxuan0701
requested review from
ChrisJBurns,
JAORMX,
amirejaz,
aponcedeleonch,
jerm-dro,
jhrozek,
rdimitrov,
reyortiz3 and
tgrunnagle
as code owners
August 19, 2026 07:38
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Automation and Agent harnesses need a stable validation result, but
thv vmcp validatecurrently emits only human-oriented logs. Parsing those logs is brittle and can accidentally expose configuration details that machine consumers do not need.--format jsontothv vmcp validatewhile preserving the existing text behavior by default.Type of change
Test plan
task -t Taskfile.focused.yml test, using the repository's-race, linker, andgotestfmtsettings for./pkg/vmcp/cliand./cmd/thv/app)task test-e2e)task lint-fix)The full
task testsuite was also attempted. It reached the test phase but unrelated Docker-dependent API/runtime and Envoy container tests could not run because Docker is unavailable in the local environment.API Compatibility
v1beta1API.Changes
pkg/vmcp/cli/validate.gopkg/vmcp/cli/validate_test.gocmd/thv/app/vmcp.gocmd/thv/app/vmcp_test.godocs/cli/thv_vmcp_validate.md--formatflag.Does this introduce a user-facing change?
Yes. Users can now run
thv vmcp validate --config <path> --format jsonand consume a stable validation summary from stdout.Special notes for reviewers
The JSON schema deliberately omits backend URLs, headers, policy contents, expanded environment values, and other configuration payloads.
backend_auth_override_countcounts backend-specific outgoing-auth overrides;backend_countcounts configured static backends.