Skip to content

Output Reference

This page documents the JSON output schema for unfault review --output json. Useful when parsing CLI output programmatically or building integrations.

When you run unfault review --output json, the CLI prints a JSON object with the analysis results.

{
"meta": { ... },
"contexts": [ ... ],
"elapsed_ms": 142
}
{
"label": "payments-service",
"languages": ["python"],
"framework_guesses": ["fastapi"],
"requested_dimensions": ["stability", "correctness"]
}
FieldTypeDescription
labelstringWorkspace label (usually directory name)
languagesarrayDetected programming languages
framework_guessesarrayDetected frameworks (e.g., fastapi, express)
requested_dimensionsarrayDimensions that were analyzed

Each context groups findings together. Currently there is one context per workspace:

{
"context_id": "ctx_workspace",
"label": "Workspace",
"findings": [ ... ]
}

A finding is a pattern detected by a rule:

{
"id": "python.http.missing_timeout:api/client.py:42",
"rule_id": "python.http.missing_timeout",
"kind": "StabilityRisk",
"title": "HTTP call has no timeout",
"description": "This HTTP call via requests.get has no timeout specified...",
"severity": "High",
"confidence": 0.9,
"dimension": "stability",
"file_path": "api/client.py",
"line": 42,
"column": 5,
"end_line": 42,
"end_column": 45,
"fix_preview": "Add timeout parameter: requests.get(url, timeout=30)"
}
FieldTypeDescription
idstringUnique finding identifier (rule_id:file_path:line)
rule_idstringRule that produced this finding
kindenumFinding category (see below)
titlestringShort title
descriptionstringDetailed explanation
severityenumCritical, High, Medium, Low, Info
confidencefloatConfidence score (0.0 to 1.0)
dimensionstringWhich dimension this finding relates to
file_pathstringFile path where the finding was detected
lineintegerLine number (1-based)
columninteger | nullColumn number (1-based)
end_lineinteger | nullEnd line number
end_columninteger | nullEnd column number
fix_previewstring | nullHuman-readable summary of suggested fix
KindDescription
StabilityRiskCould cause service instability or outages
PerformanceSmellMay impact performance
BehaviorThreatUnexpected behavior under certain conditions
AntiPatternCode pattern that typically leads to problems
ResourceLeakPotential resource leak (connections, memory)
ReliabilityRiskCould affect service reliability
SecurityVulnerabilitySecurity concern
SeverityDescription
CriticalImmediate action required
HighShould be addressed soon
MediumWorth addressing
LowMinor improvement
InfoInformational
DimensionDescription
stabilityService stability and resilience
performanceExecution speed and resource usage
correctnessLogic and behavior correctness
scalabilityAbility to handle increased load
observabilityLogging, tracing, and monitoring
reliabilityConsistent operation over time
securitySecurity posture
maintainabilityCode maintainability
{
"meta": {
"label": "payments-service",
"languages": ["python"],
"framework_guesses": ["fastapi"],
"requested_dimensions": ["stability", "correctness"]
},
"contexts": [
{
"context_id": "ctx_workspace",
"label": "Workspace",
"findings": [
{
"id": "python.http.missing_timeout:src/client.py:42",
"rule_id": "python.http.missing_timeout",
"kind": "StabilityRisk",
"title": "HTTP call has no timeout",
"description": "This HTTP call via requests.get has no timeout specified. If the remote service is slow or unresponsive, this call will block indefinitely.",
"severity": "High",
"confidence": 0.9,
"dimension": "stability",
"file_path": "src/client.py",
"line": 42,
"column": 5,
"fix_preview": "Add timeout parameter: requests.get(url, timeout=30)"
}
]
}
],
"elapsed_ms": 142
}

CodeMeaning
0Success, no findings
1General error
2Configuration error
4Network error
5Findings detected
6Invalid input