Adding session id as part of json o/p (#14504)

This commit is contained in:
Jainam M
2025-12-04 22:36:20 +05:30
committed by GitHub
parent 84f521b1c6
commit 8b0a8f47c1
8 changed files with 126 additions and 27 deletions
+3 -1
View File
@@ -428,7 +428,9 @@ export async function runNonInteractive({
} else if (config.getOutputFormat() === OutputFormat.JSON) {
const formatter = new JsonFormatter();
const stats = uiTelemetryService.getMetrics();
textOutput.write(formatter.format(responseText, stats));
textOutput.write(
formatter.format(config.getSessionId(), responseText, stats),
);
} else {
textOutput.ensureTrailingNewline(); // Ensure a final newline
}