From 5f0963dd346d5dcba2d440a62b242eb94b9b22eb Mon Sep 17 00:00:00 2001 From: Gregory Zak Date: Wed, 4 Mar 2026 16:19:30 -0800 Subject: [PATCH] fix(mcp): change mcpCheckInput default operation from query to execute Follows axonflow-enterprise#1288. The check-input endpoint is called by external orchestrators managing their own MCP execution, so defaulting to "execute" (conservative) is semantically correct over "query" (read-only). --- src/main/java/com/getaxonflow/sdk/AxonFlow.java | 2 +- .../java/com/getaxonflow/sdk/types/MCPCheckInputRequest.java | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main/java/com/getaxonflow/sdk/AxonFlow.java b/src/main/java/com/getaxonflow/sdk/AxonFlow.java index 9730814..b7ad8bd 100644 --- a/src/main/java/com/getaxonflow/sdk/AxonFlow.java +++ b/src/main/java/com/getaxonflow/sdk/AxonFlow.java @@ -1504,7 +1504,7 @@ public MCPCheckInputResponse mcpCheckInput(String connectorType, String statemen return retryExecutor.execute(() -> { MCPCheckInputRequest request; if (options != null) { - String operation = (String) options.getOrDefault("operation", "query"); + String operation = (String) options.getOrDefault("operation", "execute"); @SuppressWarnings("unchecked") Map parameters = (Map) options.get("parameters"); request = new MCPCheckInputRequest(connectorType, statement, parameters, operation); diff --git a/src/main/java/com/getaxonflow/sdk/types/MCPCheckInputRequest.java b/src/main/java/com/getaxonflow/sdk/types/MCPCheckInputRequest.java index 4c4cc07..2511d0e 100644 --- a/src/main/java/com/getaxonflow/sdk/types/MCPCheckInputRequest.java +++ b/src/main/java/com/getaxonflow/sdk/types/MCPCheckInputRequest.java @@ -44,13 +44,13 @@ public final class MCPCheckInputRequest { /** * Creates a request with connector type and statement only. - * Operation defaults to "query". + * Operation defaults to "execute". * * @param connectorType the MCP connector type (e.g., "postgres") * @param statement the statement to validate */ public MCPCheckInputRequest(String connectorType, String statement) { - this(connectorType, statement, null, "query"); + this(connectorType, statement, null, "execute"); } /**