This is an automated email from the ASF dual-hosted git repository.

davsclaus pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git


The following commit(s) were added to refs/heads/main by this push:
     new d9f3fa093994 CAMEL-26929: camel-jbang - camel cmd send and the trace 
dump have --json (#30029)
d9f3fa093994 is described below

commit d9f3fa0939941b212519aaaa8ef471c3e18324b6
Author: Claus Ibsen <[email protected]>
AuthorDate: Sun Nov 15 16:44:31 2026 +0100

    CAMEL-26929: camel-jbang - camel cmd send and the trace dump have --json 
(#30029)
    
    - camel cmd send --json prints the answer of the integration as JSON 
(status, exchange id, elapsed and, with --reply,
      the reply message as the --show options say) instead of the status line 
and the message table; the exit code is as
      before.
    - camel trace --action=dump --json prints each trace as a JSON object of 
its own line (JSON Lines), also when
      following; --json printed only the status of tracing.
    
    CAMEL-26929: camel-jbang - a shorter description of cmd send --json, and a 
test of the summary of a repeat as JSON (review)
    
    Co-Authored-By: Claude Opus 5.5 <[email protected]>
---
 .../pages/jbang-commands/camel-jbang-cmd-send.adoc |  1 +
 .../pages/jbang-commands/camel-jbang-trace.adoc    |  2 +-
 .../META-INF/camel-jbang-commands-metadata.json    |  4 +-
 .../core/commands/action/CamelSendAction.java      | 44 ++++++++++++++++++++++
 .../core/commands/action/CamelTraceAction.java     | 40 +++++++++++++++++++-
 .../commands/action/CamelSendActionResultTest.java | 43 +++++++++++++++++++++
 .../core/commands/action/CamelTraceActionTest.java | 16 ++++++++
 .../src/test/resources/golden/cli-help.txt         |  8 +++-
 8 files changed, 152 insertions(+), 6 deletions(-)

diff --git 
a/docs/user-manual/modules/ROOT/pages/jbang-commands/camel-jbang-cmd-send.adoc 
b/docs/user-manual/modules/ROOT/pages/jbang-commands/camel-jbang-cmd-send.adoc
index 92d2ac0d2cd0..589971d39ca5 100644
--- 
a/docs/user-manual/modules/ROOT/pages/jbang-commands/camel-jbang-cmd-send.adoc
+++ 
b/docs/user-manual/modules/ROOT/pages/jbang-commands/camel-jbang-cmd-send.adoc
@@ -26,6 +26,7 @@ camel cmd send [options]
 | `--header` | Message header (key=value) |  | List
 | `--infra` | Send to infrastructure service (e.g., nats, kafka) |  | String
 | `--interval` | The pause between two messages with --repeat or a folder 
body, in millis or as a duration such as 200ms or 1s, or a range such as 
100..500 or 100ms..2s to draw each pause at random (at most 60s) |  | String
+| `--json` | Output the outcome in JSON Format: the status, the exchange id, 
and the reply message with --reply |  | boolean
 | `--logging-color` | Use colored logging | true | boolean
 | `--poll` | Poll instead of sending a message. This can be used to receive 
latest message from a Kafka topic or JMS queue. |  | boolean
 | `--pretty` | Pretty print response message body (InOut) when using JSon or 
XML format |  | boolean
diff --git 
a/docs/user-manual/modules/ROOT/pages/jbang-commands/camel-jbang-trace.adoc 
b/docs/user-manual/modules/ROOT/pages/jbang-commands/camel-jbang-trace.adoc
index d7a8307382fd..b0a383c7abf6 100644
--- a/docs/user-manual/modules/ROOT/pages/jbang-commands/camel-jbang-trace.adoc
+++ b/docs/user-manual/modules/ROOT/pages/jbang-commands/camel-jbang-trace.adoc
@@ -27,7 +27,7 @@ camel trace [options]
 | `--find` | Find and highlight matching text (ignore case). |  | String[]
 | `--follow` | Keep following and outputting new traces (press enter to exit). 
Without an interactive terminal the default is false, unless --duration is 
given. | true | boolean
 | `--grep` | Filter traces to only output trace matching text (ignore case). | 
 | String[]
-| `--json` | Output the status of tracing in JSON Format |  | boolean
+| `--json` | Output in JSON Format: the status of tracing, and with 
--action=dump each trace as a JSON object per line |  | boolean
 | `--latest` | Only output traces from the latest (follow if necessary until 
complete and exit) |  | boolean
 | `--logging-color` | Use colored logging | true | boolean
 | `--mask` | Whether to mask endpoint URIs to avoid printing sensitive 
information such as password or access keys |  | boolean
diff --git 
a/dsl/camel-jbang/camel-jbang-core/src/generated/resources/META-INF/camel-jbang-commands-metadata.json
 
b/dsl/camel-jbang/camel-jbang-core/src/generated/resources/META-INF/camel-jbang-commands-metadata.json
index b57862a5c744..2851cd3ccd97 100644
--- 
a/dsl/camel-jbang/camel-jbang-core/src/generated/resources/META-INF/camel-jbang-commands-metadata.json
+++ 
b/dsl/camel-jbang/camel-jbang-core/src/generated/resources/META-INF/camel-jbang-commands-metadata.json
@@ -3,7 +3,7 @@
     { "name": "ask", "fullName": "ask", "description": "Ask a question about a 
running Camel application using AI", "sourceClass": 
"org.apache.camel.dsl.jbang.core.commands.Ask", "options": [ { "names": 
"--api-key", "description": "API key. Also reads ANTHROPIC_API_KEY, 
OPENAI_API_KEY, WATSONX_APIKEY, or LLM_API_KEY env vars", "javaType": 
"java.lang.String", "type": "string" }, { "names": "--api-type", "description": 
"API type: 'ollama', 'openai', 'anthropic', or 'watsonx'", "javaType":  [...]
     { "name": "bind", "fullName": "bind", "description": "DEPRECATED: Bind 
source and sink Kamelets as a new Camel integration", "deprecated": true, 
"sourceClass": "org.apache.camel.dsl.jbang.core.commands.bind.Bind", "options": 
[ { "names": "--error-handler", "description": "Add error handler 
(none|log|sink:<endpoint>). Sink endpoints are expected in the format 
\"[[apigroup\/]version:]kind:[namespace\/]name\", plain Camel URIs or Kamelet 
name.", "javaType": "java.lang.String", "type": " [...]
     { "name": "catalog", "fullName": "catalog", "description": "List artifacts 
from Camel Catalog", "sourceClass": 
"org.apache.camel.dsl.jbang.core.commands.catalog.CatalogCommand", "options": [ 
{ "names": "-h,--help", "description": "Display this help and exit", 
"javaType": "boolean", "type": "boolean" } ], "subcommands": [ { "name": 
"component", "fullName": "catalog component", "description": "List components 
from the Camel Catalog", "sourceClass": "org.apache.camel.dsl.jbang.core.comm 
[...]
-    { "name": "cmd", "fullName": "cmd", "description": "Performs commands in 
the running Camel integrations, such as start\/stop route, or change logging 
levels.", "sourceClass": 
"org.apache.camel.dsl.jbang.core.commands.action.CamelAction", "options": [ { 
"names": "-h,--help", "description": "Display this help and exit", "javaType": 
"boolean", "type": "boolean" } ], "subcommands": [ { "name": "browse", 
"fullName": "cmd browse", "description": "Browse pending messages on 
endpoints", "sou [...]
+    { "name": "cmd", "fullName": "cmd", "description": "Performs commands in 
the running Camel integrations, such as start\/stop route, or change logging 
levels.", "sourceClass": 
"org.apache.camel.dsl.jbang.core.commands.action.CamelAction", "options": [ { 
"names": "-h,--help", "description": "Display this help and exit", "javaType": 
"boolean", "type": "boolean" } ], "subcommands": [ { "name": "browse", 
"fullName": "cmd browse", "description": "Browse pending messages on 
endpoints", "sou [...]
     { "name": "completion", "fullName": "completion", "description": "Generate 
completion script for bash\/zsh", "sourceClass": 
"org.apache.camel.dsl.jbang.core.commands.Complete", "options": [ { "names": 
"-h,--help", "description": "Display this help and exit", "javaType": 
"boolean", "type": "boolean" } ] },
     { "name": "config", "fullName": "config", "description": "Get and set user 
configuration values", "sourceClass": 
"org.apache.camel.dsl.jbang.core.commands.config.ConfigCommand", "options": [ { 
"names": "-h,--help", "description": "Display this help and exit", "javaType": 
"boolean", "type": "boolean" } ], "subcommands": [ { "name": "get", "fullName": 
"config get", "description": "Display user configuration value", "sourceClass": 
"org.apache.camel.dsl.jbang.core.commands.config.ConfigG [...]
     { "name": "debug", "fullName": "debug", "description": "Debug local Camel 
integration", "sourceClass": "org.apache.camel.dsl.jbang.core.commands.Debug", 
"options": [ { "names": "--ago", "description": "Use ago instead of yyyy-MM-dd 
HH:mm:ss in timestamp.", "javaType": "boolean", "type": "boolean" }, { "names": 
"--background", "description": "Run in the background", "defaultValue": 
"false", "javaType": "boolean", "type": "boolean" }, { "names": 
"--background-wait", "description": "How [...]
@@ -35,7 +35,7 @@
     { "name": "status", "fullName": "status", "description": "The state of a 
running Camel integration in one call: where it runs and its files, its routes, 
health, last errors and last reload, its JVM, and the end of its log", 
"sourceClass": 
"org.apache.camel.dsl.jbang.core.commands.process.IntegrationStatus", 
"options": [ { "names": "--errors", "description": "How many of the last errors 
to show", "defaultValue": "5", "javaType": "int", "type": "integer" }, { 
"names": "--json", "descri [...]
     { "name": "stop", "fullName": "stop", "description": "Shuts down running 
Camel integrations", "sourceClass": 
"org.apache.camel.dsl.jbang.core.commands.process.StopProcess", "options": [ { 
"names": "--kill", "description": "To force killing the process (SIGKILL)", 
"javaType": "boolean", "type": "boolean" }, { "names": "--no-wait", 
"description": "Do not wait for the integration to stop", "javaType": 
"boolean", "type": "boolean" }, { "names": "--timeout", "description": "How 
long to wa [...]
     { "name": "top", "fullName": "top", "description": "Top status of Camel 
integrations", "sourceClass": 
"org.apache.camel.dsl.jbang.core.commands.process.CamelTop", "options": [ { 
"names": "--watch", "description": "Execute periodically and showing output 
fullscreen", "javaType": "boolean", "type": "boolean" }, { "names": 
"-h,--help", "description": "Display this help and exit", "javaType": 
"boolean", "type": "boolean" } ], "subcommands": [ { "name": "context", 
"fullName": "top context [...]
-    { "name": "trace", "fullName": "trace", "description": "Tail message 
traces from running Camel integrations", "sourceClass": 
"org.apache.camel.dsl.jbang.core.commands.action.CamelTraceAction", "options": 
[ { "names": "--action", "description": "Action to start, stop, clear, list 
status, or dump traces", "defaultValue": "status", "javaType": 
"java.lang.String", "type": "string" }, { "names": "--ago", "description": "Use 
ago instead of yyyy-MM-dd HH:mm:ss in timestamp.", "javaType": "b [...]
+    { "name": "trace", "fullName": "trace", "description": "Tail message 
traces from running Camel integrations", "sourceClass": 
"org.apache.camel.dsl.jbang.core.commands.action.CamelTraceAction", "options": 
[ { "names": "--action", "description": "Action to start, stop, clear, list 
status, or dump traces", "defaultValue": "status", "javaType": 
"java.lang.String", "type": "string" }, { "names": "--ago", "description": "Use 
ago instead of yyyy-MM-dd HH:mm:ss in timestamp.", "javaType": "b [...]
     { "name": "transform", "fullName": "transform", "description": "Transform 
message or Camel routes", "sourceClass": 
"org.apache.camel.dsl.jbang.core.commands.TransformCommand", "options": [ { 
"names": "-h,--help", "description": "Display this help and exit", "javaType": 
"boolean", "type": "boolean" } ], "subcommands": [ { "name": "dataweave", 
"fullName": "transform dataweave", "description": "Convert DataWeave scripts to 
DataSonnet format", "sourceClass": "org.apache.camel.dsl.jbang.c [...]
     { "name": "update", "fullName": "update", "description": "Update Camel 
project", "sourceClass": 
"org.apache.camel.dsl.jbang.core.commands.update.UpdateCommand", "options": [ { 
"names": "-h,--help", "description": "Display this help and exit", "javaType": 
"boolean", "type": "boolean" } ], "subcommands": [ { "name": "list", 
"fullName": "update list", "description": "List available update versions for 
Camel and its runtime variants", "sourceClass": 
"org.apache.camel.dsl.jbang.core.comma [...]
     { "name": "version", "fullName": "version", "description": "Manage Camel 
versions", "sourceClass": 
"org.apache.camel.dsl.jbang.core.commands.version.VersionCommand", "options": [ 
{ "names": "-h,--help", "description": "Display this help and exit", 
"javaType": "boolean", "type": "boolean" } ], "subcommands": [ { "name": "get", 
"fullName": "version get", "description": "Displays current Camel version", 
"sourceClass": "org.apache.camel.dsl.jbang.core.commands.version.VersionGet", 
"optio [...]
diff --git 
a/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/action/CamelSendAction.java
 
b/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/action/CamelSendAction.java
index 94e77bb6c816..0c62c1a7196a 100644
--- 
a/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/action/CamelSendAction.java
+++ 
b/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/action/CamelSendAction.java
@@ -162,6 +162,10 @@ public class CamelSendAction extends ActionBaseCommand {
     @Option(name = "logging-color", hasValue = false, description = "Use 
colored logging", defaultValue = "true")
     boolean loggingColor = true;
 
+    @Option(name = "json", hasValue = false,
+            description = "Output the outcome in JSON Format: the status, the 
exchange id, and the reply message with --reply")
+    boolean jsonOutput;
+
     @Option(name = "infra", description = "Send to infrastructure service 
(e.g., nats, kafka)")
     String infra;
 
@@ -359,6 +363,9 @@ public class CamelSendAction extends ActionBaseCommand {
             String error = result.status() == ActionClient.Status.TIMEOUT ? 
"Send timeout: " + result.error() : result.error();
             throw new CliException(result.exitCode(), error);
         }
+        if (jsonOutput) {
+            return showJson(result, jo);
+        }
         printStatusLine(jo);
         if (jo.containsKey("sent")) {
             return showSummary(jo);
@@ -418,6 +425,43 @@ public class CamelSendAction extends ActionBaseCommand {
         return CliExitCode.OK;
     }
 
+    /**
+     * The answer of the integration as JSON, with what the --show options 
leave out removed, so a script or an AI agent
+     * reads the outcome of the send instead of parsing a table (CAMEL-26929).
+     */
+    private int showJson(ActionResult result, JsonObject jo) {
+        JsonObject message = jo.getMap("message");
+        if (message != null) {
+            if (!showExchangeProperties) {
+                message.remove("exchangeProperties");
+            }
+            if (!showExchangeVariables) {
+                message.remove("exchangeVariables");
+            }
+            if (!showHeaders) {
+                message.remove("headers");
+            }
+            if (!showBody) {
+                message.remove("body");
+            }
+        }
+        if (!showException) {
+            jo.remove("exception");
+        }
+        if (!result.isOk() && message == null && jo.getMap("exception") == 
null && jo.getString("error") == null) {
+            jo.put("error", result.error());
+        }
+        jo.put("pid", pid);
+        printer().println(pretty ? Jsoner.prettyPrint(jo.toJson(), 2) : 
jo.toJson());
+        String status = jo.getString("status");
+        if ("timeout".equals(status)) {
+            return CliExitCode.TIMEOUT;
+        } else if ("failed".equals(status) || "error".equals(status)) {
+            return CliExitCode.FAILURE;
+        }
+        return result.isOk() || "success".equals(status) ? CliExitCode.OK : 
CliExitCode.FAILURE;
+    }
+
     /** The summary of a repeat or a folder of messages: the errors, as the 
status line has the counts. */
     private int showSummary(JsonObject jo) {
         Collection<JsonObject> errors = jo.getCollection("errors");
diff --git 
a/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/action/CamelTraceAction.java
 
b/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/action/CamelTraceAction.java
index dba7946f1f0b..078c9203c475 100644
--- 
a/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/action/CamelTraceAction.java
+++ 
b/dsl/camel-jbang/camel-jbang-core/src/main/java/org/apache/camel/dsl/jbang/core/commands/action/CamelTraceAction.java
@@ -112,7 +112,9 @@ public class CamelTraceAction extends ActionBaseCommand {
             completer = PidNameAgeCompletionCandidates.class)
     String sort;
 
-    @Option(name = "json", hasValue = false, description = "Output the status 
of tracing in JSON Format")
+    @Option(name = "json", hasValue = false,
+            description = "Output in JSON Format: the status of tracing, and 
with --action=dump each trace as a JSON object"
+                          + " per line")
     boolean jsonOutput;
 
     @Mixin
@@ -692,6 +694,37 @@ public class CamelTraceAction extends ActionBaseCommand {
         }
     }
 
+    static JsonObject toJson(Row row) {
+        JsonObject jo = new JsonObject();
+        jo.put("pid", JsonValues.pid(row.pid));
+        jo.put("name", row.name);
+        jo.put("uid", row.uid);
+        jo.put("exchangeId", row.exchangeId);
+        jo.put("exchangePattern", row.exchangePattern);
+        jo.put("timestamp", row.timestamp);
+        jo.put("elapsed", row.elapsed);
+        jo.put("threadName", row.threadName);
+        jo.put("location", row.location);
+        jo.put("routeId", row.routeId);
+        jo.put("nodeId", row.nodeId);
+        jo.put("first", row.first);
+        jo.put("last", row.last);
+        jo.put("done", row.done);
+        jo.put("failed", row.failed);
+        putIfNotNull(jo, "endpoint", row.endpoint);
+        putIfNotNull(jo, "endpointService", row.endpointService);
+        putIfNotNull(jo, "aggregate", row.aggregate);
+        putIfNotNull(jo, "message", row.message);
+        putIfNotNull(jo, "exception", row.exception);
+        return jo;
+    }
+
+    private static void putIfNotNull(JsonObject jo, String key, Object value) {
+        if (value != null) {
+            jo.put(key, value);
+        }
+    }
+
     private boolean isValidGrep(String line) {
         if (grep == null) {
             return true;
@@ -732,6 +765,11 @@ public class CamelTraceAction extends ActionBaseCommand {
         if (!valid) {
             return;
         }
+        if (jsonOutput) {
+            // one JSON object per line (JSON Lines), also when following, for 
a script or an AI agent (CAMEL-26929)
+            printer().println(toJson(row).toJson());
+            return;
+        }
 
         String nameWithPrefix = null;
         if (name != null) {
diff --git 
a/dsl/camel-jbang/camel-jbang-core/src/test/java/org/apache/camel/dsl/jbang/core/commands/action/CamelSendActionResultTest.java
 
b/dsl/camel-jbang/camel-jbang-core/src/test/java/org/apache/camel/dsl/jbang/core/commands/action/CamelSendActionResultTest.java
index 3f30a46e1dd2..fc09aad12971 100644
--- 
a/dsl/camel-jbang/camel-jbang-core/src/test/java/org/apache/camel/dsl/jbang/core/commands/action/CamelSendActionResultTest.java
+++ 
b/dsl/camel-jbang/camel-jbang-core/src/test/java/org/apache/camel/dsl/jbang/core/commands/action/CamelSendActionResultTest.java
@@ -253,4 +253,47 @@ class CamelSendActionResultTest extends 
ActionCommandTestSupport {
         answer.put("message", message);
         return answer;
     }
+
+    @Test
+    void theOutcomeAsJson() throws Exception {
+        // CAMEL-26929: send had no --json, so a script or an AI agent had to 
read the status line and the table
+        writeStatusFile(TEST_PID, "orders");
+
+        int exit = callWithResponse(command("orders", 
"--endpoint=direct:start", "--body=hello", "--reply", "--json"),
+                answer("success"));
+
+        assertThat(exit).isEqualTo(CliExitCode.OK);
+        JsonObject out = (JsonObject) Jsoner.deserialize(printer.getStdout());
+        assertThat(out.getString("status")).isEqualTo("success");
+        assertThat(out.getString("exchangeId")).isEqualTo("ex-1");
+        assertThat(out.getLong("pid")).isEqualTo(TEST_PID);
+        assertThat(printer.getStdout()).doesNotContain("Sent (");
+    }
+
+    @Test
+    void theSummaryOfARepeatAsJson() throws Exception {
+        writeStatusFile(TEST_PID, "orders");
+        JsonObject summary = new JsonObject(
+                Map.of("status", "success", "sent", 10L, "failed", 0L, 
"elapsed", 3000L,
+                        "endpoint", "direct://start", "errors", new 
JsonArray()));
+
+        int exit = callWithResponse(command("orders", 
"--endpoint=direct:start", "--repeat=10", "--json"), summary);
+
+        assertThat(exit).isEqualTo(CliExitCode.OK);
+        JsonObject out = (JsonObject) Jsoner.deserialize(printer.getStdout());
+        assertThat(out.getLong("sent")).isEqualTo(10L);
+        assertThat(out.getString("status")).isEqualTo("success");
+    }
+
+    @Test
+    void aFailedSendAsJsonIsAFailure() throws Exception {
+        writeStatusFile(TEST_PID, "orders");
+
+        int exit = callWithResponse(command("orders", 
"--endpoint=direct:start", "--json"), answer("error"));
+
+        assertThat(exit).isEqualTo(CliExitCode.FAILURE);
+        JsonObject out = (JsonObject) Jsoner.deserialize(printer.getStdout());
+        assertThat(out.getString("status")).isEqualTo("error");
+        assertThat(out.containsKey("exception")).isTrue();
+    }
 }
diff --git 
a/dsl/camel-jbang/camel-jbang-core/src/test/java/org/apache/camel/dsl/jbang/core/commands/action/CamelTraceActionTest.java
 
b/dsl/camel-jbang/camel-jbang-core/src/test/java/org/apache/camel/dsl/jbang/core/commands/action/CamelTraceActionTest.java
index 208fc12d8ccb..cd10d18ab6db 100644
--- 
a/dsl/camel-jbang/camel-jbang-core/src/test/java/org/apache/camel/dsl/jbang/core/commands/action/CamelTraceActionTest.java
+++ 
b/dsl/camel-jbang/camel-jbang-core/src/test/java/org/apache/camel/dsl/jbang/core/commands/action/CamelTraceActionTest.java
@@ -277,4 +277,20 @@ class CamelTraceActionTest extends 
ActionCommandTestSupport {
         root.put("trace", trace);
         return root;
     }
+
+    @Test
+    void dumpAsJsonLines() throws Exception {
+        // CAMEL-26929: the dump had no --json; now each trace is a JSON 
object of its own line
+        writeStatusFile(TEST_PID, status(true, false));
+        writeTraces(exchange());
+
+        assertThat(callWithSingleProcess(dump("--json"))).isZero();
+
+        List<String> lines = printer.getStdout().lines().toList();
+        assertThat(lines).isNotEmpty().allSatisfy(line -> 
assertThat(Jsoner.deserialize(line)).isInstanceOf(JsonObject.class));
+        JsonObject first = (JsonObject) Jsoner.deserialize(lines.get(0));
+        assertThat(first.getLong("pid")).isEqualTo(TEST_PID);
+        assertThat(first.getBoolean("first")).isTrue();
+        assertThat(lines).anySatisfy(line -> assertThat(line).contains("Hello 
Camel"));
+    }
 }
diff --git 
a/dsl/camel-jbang/camel-jbang-core/src/test/resources/golden/cli-help.txt 
b/dsl/camel-jbang/camel-jbang-core/src/test/resources/golden/cli-help.txt
index 8548057a1fa5..2117d969dbe8 100644
--- a/dsl/camel-jbang/camel-jbang-core/src/test/resources/golden/cli-help.txt
+++ b/dsl/camel-jbang/camel-jbang-core/src/test/resources/golden/cli-help.txt
@@ -1644,7 +1644,7 @@ Usage: camel cmd send [-h] [--properties=<properties>] 
[--prop=<prop>]
                        [--interval=<interval>] [--timeout=<timeout>]
                        [--show-exchange-properties] [--show-exchange-variables]
                        [--show-headers] [--show-body] [--show-exception]
-                       [--pretty] [--logging-color] [--infra=<infra>]
+                       [--pretty] [--logging-color] [--json] [--infra=<infra>]
                        [--download] [--repo=<repo>] [--fresh] [<name>]
 
 Options:
@@ -1701,6 +1701,8 @@ Options:
                             using JSon or XML format
       --logging-color       Use colored logging
                             Default: true
+      --json                Output the outcome in JSON Format: the status, the
+                            exchange id, and the reply message with --reply
       --infra=<infra>       Send to infrastructure service (e.g., nats, kafka)
       --download            Whether to allow automatic downloading JAR
                             dependencies (over the internet)
@@ -6447,7 +6449,9 @@ Options:
       --sort=<sort>         Sort by pid, name or age for showing status of
                             tracing
                             Default: pid
-      --json                Output the status of tracing in JSON Format
+      --json                Output in JSON Format: the status of tracing, and
+                            with --action=dump each trace as a JSON object per
+                            line
       --timeout=<timeout>   How long to wait for the integration to answer, in
                             millis or as a duration such as 30s
                             Default: 10000

Reply via email to