From c9948a022882292ad6929bf1a416301440843081 Mon Sep 17 00:00:00 2001 From: souvikghosh04 Date: Tue, 28 Oct 2025 16:17:04 +0530 Subject: [PATCH 1/9] Bug fix for setting dml tools based on bool value as set in config --- src/Config/ObjectModel/DmlToolsConfig.cs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/Config/ObjectModel/DmlToolsConfig.cs b/src/Config/ObjectModel/DmlToolsConfig.cs index c14f8e49ed..73728f65b7 100644 --- a/src/Config/ObjectModel/DmlToolsConfig.cs +++ b/src/Config/ObjectModel/DmlToolsConfig.cs @@ -116,12 +116,12 @@ public static DmlToolsConfig FromBoolean(bool enabled) return new DmlToolsConfig { AllToolsEnabled = enabled, - DescribeEntities = null, - CreateRecord = null, - ReadRecords = null, - UpdateRecord = null, - DeleteRecord = null, - ExecuteEntity = null + DescribeEntities = enabled, + CreateRecord = enabled, + ReadRecords = enabled, + UpdateRecord = enabled, + DeleteRecord = enabled, + ExecuteEntity = enabled }; } From e103d3060cfbd9414437c943776fb4611f708c90 Mon Sep 17 00:00:00 2001 From: souvikghosh04 Date: Thu, 30 Oct 2025 16:39:58 +0530 Subject: [PATCH 2/9] Fixed potential incorrect JSON serialization as suggessted by Github copilot --- src/Config/ObjectModel/DmlToolsConfig.cs | 37 +++++++++++++++++------- 1 file changed, 27 insertions(+), 10 deletions(-) diff --git a/src/Config/ObjectModel/DmlToolsConfig.cs b/src/Config/ObjectModel/DmlToolsConfig.cs index 73728f65b7..d773d309f9 100644 --- a/src/Config/ObjectModel/DmlToolsConfig.cs +++ b/src/Config/ObjectModel/DmlToolsConfig.cs @@ -113,16 +113,15 @@ public DmlToolsConfig( /// public static DmlToolsConfig FromBoolean(bool enabled) { - return new DmlToolsConfig - { - AllToolsEnabled = enabled, - DescribeEntities = enabled, - CreateRecord = enabled, - ReadRecords = enabled, - UpdateRecord = enabled, - DeleteRecord = enabled, - ExecuteEntity = enabled - }; + return new DmlToolsConfig( + allToolsEnabled: enabled, + describeEntities: enabled, + createRecord: enabled, + readRecords: enabled, + updateRecord: enabled, + deleteRecord: enabled, + executeEntity: enabled + ); } /// @@ -185,4 +184,22 @@ public static DmlToolsConfig FromBoolean(bool enabled) [JsonIgnore(Condition = JsonIgnoreCondition.Always)] [MemberNotNullWhen(true, nameof(ExecuteEntity))] public bool UserProvidedExecuteEntity { get; init; } = false; + + /// + /// Checks if a specific tool is enabled + /// + public bool IsToolEnabled(string toolName) + { + return toolName.ToLowerInvariant() switch + { + "all" => AllToolsEnabled, + "describe_entities" => DescribeEntities ?? AllToolsEnabled, + "create_record" => CreateRecord ?? AllToolsEnabled, + "read_records" => ReadRecords ?? AllToolsEnabled, + "update_record" => UpdateRecord ?? AllToolsEnabled, + "delete_record" => DeleteRecord ?? AllToolsEnabled, + "execute_entity" => ExecuteEntity ?? AllToolsEnabled, + _ => throw new ArgumentException($"Unknown tool name: {toolName}") + }; + } } From 0217d7545038d823c0ca53bb9ffdccaf5861917e Mon Sep 17 00:00:00 2001 From: souvikghosh04 Date: Thu, 30 Oct 2025 17:05:00 +0530 Subject: [PATCH 3/9] Removed ununsed method --- src/Config/ObjectModel/DmlToolsConfig.cs | 18 ------------------ 1 file changed, 18 deletions(-) diff --git a/src/Config/ObjectModel/DmlToolsConfig.cs b/src/Config/ObjectModel/DmlToolsConfig.cs index d773d309f9..71171a686c 100644 --- a/src/Config/ObjectModel/DmlToolsConfig.cs +++ b/src/Config/ObjectModel/DmlToolsConfig.cs @@ -184,22 +184,4 @@ public static DmlToolsConfig FromBoolean(bool enabled) [JsonIgnore(Condition = JsonIgnoreCondition.Always)] [MemberNotNullWhen(true, nameof(ExecuteEntity))] public bool UserProvidedExecuteEntity { get; init; } = false; - - /// - /// Checks if a specific tool is enabled - /// - public bool IsToolEnabled(string toolName) - { - return toolName.ToLowerInvariant() switch - { - "all" => AllToolsEnabled, - "describe_entities" => DescribeEntities ?? AllToolsEnabled, - "create_record" => CreateRecord ?? AllToolsEnabled, - "read_records" => ReadRecords ?? AllToolsEnabled, - "update_record" => UpdateRecord ?? AllToolsEnabled, - "delete_record" => DeleteRecord ?? AllToolsEnabled, - "execute_entity" => ExecuteEntity ?? AllToolsEnabled, - _ => throw new ArgumentException($"Unknown tool name: {toolName}") - }; - } } From 54e1bc59e563ef0add0fe7b23d1fb44d13750f8a Mon Sep 17 00:00:00 2001 From: souvikghosh04 Date: Fri, 31 Oct 2025 14:22:03 +0530 Subject: [PATCH 4/9] set DML tools to be enabled by default if property is not specified or null --- src/Config/ObjectModel/McpRuntimeOptions.cs | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/Config/ObjectModel/McpRuntimeOptions.cs b/src/Config/ObjectModel/McpRuntimeOptions.cs index 73d695ee4a..8a4549c3d9 100644 --- a/src/Config/ObjectModel/McpRuntimeOptions.cs +++ b/src/Config/ObjectModel/McpRuntimeOptions.cs @@ -48,7 +48,15 @@ public McpRuntimeOptions( this.Path = DEFAULT_PATH; } - this.DmlTools = DmlTools; + // if DmlTools is null, set All tools enabled by default + if (DmlTools is null) + { + this.DmlTools = DmlToolsConfig.FromBoolean(true); + } + else + { + this.DmlTools = DmlTools; + } } /// From 4761b0c0143eea0821855a36aa1eaa3470cfdd44 Mon Sep 17 00:00:00 2001 From: souvikghosh04 Date: Fri, 31 Oct 2025 19:20:39 +0530 Subject: [PATCH 5/9] Fix snapshot verification failing tests --- src/Cli.Tests/ConfigGeneratorTests.cs | 12 ++++++++++-- ...estMethodsAndGraphQLOperations.verified.txt | 18 +++++++++++++++++- ...ityWithSourceAsStoredProcedure.verified.txt | 18 +++++++++++++++++- ...Tests.TestInitForCosmosDBNoSql.verified.txt | 18 +++++++++++++++++- ...estMethodsAndGraphQLOperations.verified.txt | 18 +++++++++++++++++- ...tionProviders_171ea8114ff71814.verified.txt | 18 +++++++++++++++++- ...tionProviders_2df7a1794712f154.verified.txt | 18 +++++++++++++++++- ...tionProviders_59fe1a10aa78899d.verified.txt | 18 +++++++++++++++++- ...tionProviders_b95b637ea87f16a7.verified.txt | 18 +++++++++++++++++- ...tionProviders_daacbd948b7ef72f.verified.txt | 18 +++++++++++++++++- ...utStartingSlashWillHaveItAdded.verified.txt | 18 +++++++++++++++++- .../InitTests.MsSQLDatabase.verified.txt | 18 +++++++++++++++++- ...utStartingSlashWillHaveItAdded.verified.txt | 18 +++++++++++++++++- ...alCharactersInConnectionString.verified.txt | 18 +++++++++++++++++- ...tationOptions_0546bef37027a950.verified.txt | 18 +++++++++++++++++- ...tationOptions_0ac567dd32a2e8f5.verified.txt | 18 +++++++++++++++++- ...tationOptions_0c06949221514e77.verified.txt | 18 +++++++++++++++++- ...tationOptions_18667ab7db033e9d.verified.txt | 18 +++++++++++++++++- ...tationOptions_2f42f44c328eb020.verified.txt | 18 +++++++++++++++++- ...tationOptions_3243d3f3441fdcc1.verified.txt | 18 +++++++++++++++++- ...tationOptions_53350b8b47df2112.verified.txt | 18 +++++++++++++++++- ...tationOptions_6584e0ec46b8a11d.verified.txt | 18 +++++++++++++++++- ...tationOptions_81cc88db3d4eecfb.verified.txt | 18 +++++++++++++++++- ...tationOptions_8ea187616dbb5577.verified.txt | 18 +++++++++++++++++- ...tationOptions_905845c29560a3ef.verified.txt | 18 +++++++++++++++++- ...tationOptions_b2fd24fab5b80917.verified.txt | 18 +++++++++++++++++- ...tationOptions_bd7cd088755287c9.verified.txt | 18 +++++++++++++++++- ...tationOptions_d2eccba2f836b380.verified.txt | 18 +++++++++++++++++- ...tationOptions_d463eed7fe5e4bbe.verified.txt | 18 +++++++++++++++++- ...tationOptions_d5520dd5c33f7b8d.verified.txt | 18 +++++++++++++++++- ...tationOptions_eab4a6010e602b59.verified.txt | 18 +++++++++++++++++- ...tationOptions_ecaa688829b4030e.verified.txt | 18 +++++++++++++++++- 32 files changed, 537 insertions(+), 33 deletions(-) diff --git a/src/Cli.Tests/ConfigGeneratorTests.cs b/src/Cli.Tests/ConfigGeneratorTests.cs index 58e006b75d..9f56d5964f 100644 --- a/src/Cli.Tests/ConfigGeneratorTests.cs +++ b/src/Cli.Tests/ConfigGeneratorTests.cs @@ -165,8 +165,16 @@ public void TestSpecialCharactersInConnectionString() }, ""mcp"": { ""enabled"": true, - ""path"": ""/mcp"" - }, + ""path"": ""/mcp"", + ""dml-tools"":{ + ""describe-entities"": true, + ""create-record"": true, + ""read-records"": true, + ""update-record"": true, + ""delete-record"": true, + ""execute-entity"":true + } + }, ""host"": { ""cors"": { ""origins"": [], diff --git a/src/Cli.Tests/Snapshots/EndToEndTests.TestAddingStoredProcedureWithRestMethodsAndGraphQLOperations.verified.txt b/src/Cli.Tests/Snapshots/EndToEndTests.TestAddingStoredProcedureWithRestMethodsAndGraphQLOperations.verified.txt index 4411b47348..12316672ab 100644 --- a/src/Cli.Tests/Snapshots/EndToEndTests.TestAddingStoredProcedureWithRestMethodsAndGraphQLOperations.verified.txt +++ b/src/Cli.Tests/Snapshots/EndToEndTests.TestAddingStoredProcedureWithRestMethodsAndGraphQLOperations.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: false, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/EndToEndTests.TestConfigGeneratedAfterAddingEntityWithSourceAsStoredProcedure.verified.txt b/src/Cli.Tests/Snapshots/EndToEndTests.TestConfigGeneratedAfterAddingEntityWithSourceAsStoredProcedure.verified.txt index 636d44805e..218d4b46e8 100644 --- a/src/Cli.Tests/Snapshots/EndToEndTests.TestConfigGeneratedAfterAddingEntityWithSourceAsStoredProcedure.verified.txt +++ b/src/Cli.Tests/Snapshots/EndToEndTests.TestConfigGeneratedAfterAddingEntityWithSourceAsStoredProcedure.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: false, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/EndToEndTests.TestInitForCosmosDBNoSql.verified.txt b/src/Cli.Tests/Snapshots/EndToEndTests.TestInitForCosmosDBNoSql.verified.txt index 081c5f8e55..d13807441c 100644 --- a/src/Cli.Tests/Snapshots/EndToEndTests.TestInitForCosmosDBNoSql.verified.txt +++ b/src/Cli.Tests/Snapshots/EndToEndTests.TestInitForCosmosDBNoSql.verified.txt @@ -19,7 +19,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: false, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/EndToEndTests.TestUpdatingStoredProcedureWithRestMethodsAndGraphQLOperations.verified.txt b/src/Cli.Tests/Snapshots/EndToEndTests.TestUpdatingStoredProcedureWithRestMethodsAndGraphQLOperations.verified.txt index 09007e27f8..92d6369214 100644 --- a/src/Cli.Tests/Snapshots/EndToEndTests.TestUpdatingStoredProcedureWithRestMethodsAndGraphQLOperations.verified.txt +++ b/src/Cli.Tests/Snapshots/EndToEndTests.TestUpdatingStoredProcedureWithRestMethodsAndGraphQLOperations.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: false, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_171ea8114ff71814.verified.txt b/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_171ea8114ff71814.verified.txt index 0af93023dc..db26433ea0 100644 --- a/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_171ea8114ff71814.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_171ea8114ff71814.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_2df7a1794712f154.verified.txt b/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_2df7a1794712f154.verified.txt index 9e77b24d74..1471284e3a 100644 --- a/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_2df7a1794712f154.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_2df7a1794712f154.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_59fe1a10aa78899d.verified.txt b/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_59fe1a10aa78899d.verified.txt index 32f72a7a54..6c6b6fa055 100644 --- a/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_59fe1a10aa78899d.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_59fe1a10aa78899d.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_b95b637ea87f16a7.verified.txt b/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_b95b637ea87f16a7.verified.txt index 24416a0d02..11f92aa0bb 100644 --- a/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_b95b637ea87f16a7.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_b95b637ea87f16a7.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_daacbd948b7ef72f.verified.txt b/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_daacbd948b7ef72f.verified.txt index 6c674a4772..5d24ae9d2f 100644 --- a/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_daacbd948b7ef72f.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.EnsureCorrectConfigGenerationWithDifferentAuthenticationProviders_daacbd948b7ef72f.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.GraphQLPathWithoutStartingSlashWillHaveItAdded.verified.txt b/src/Cli.Tests/Snapshots/InitTests.GraphQLPathWithoutStartingSlashWillHaveItAdded.verified.txt index b6aac13236..cd721f65d2 100644 --- a/src/Cli.Tests/Snapshots/InitTests.GraphQLPathWithoutStartingSlashWillHaveItAdded.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.GraphQLPathWithoutStartingSlashWillHaveItAdded.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.MsSQLDatabase.verified.txt b/src/Cli.Tests/Snapshots/InitTests.MsSQLDatabase.verified.txt index 8841c0f326..d304df7085 100644 --- a/src/Cli.Tests/Snapshots/InitTests.MsSQLDatabase.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.MsSQLDatabase.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.RestPathWithoutStartingSlashWillHaveItAdded.verified.txt b/src/Cli.Tests/Snapshots/InitTests.RestPathWithoutStartingSlashWillHaveItAdded.verified.txt index 68e4d231fd..ff7b282c32 100644 --- a/src/Cli.Tests/Snapshots/InitTests.RestPathWithoutStartingSlashWillHaveItAdded.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.RestPathWithoutStartingSlashWillHaveItAdded.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.TestSpecialCharactersInConnectionString.verified.txt b/src/Cli.Tests/Snapshots/InitTests.TestSpecialCharactersInConnectionString.verified.txt index 32f72a7a54..6c6b6fa055 100644 --- a/src/Cli.Tests/Snapshots/InitTests.TestSpecialCharactersInConnectionString.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.TestSpecialCharactersInConnectionString.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_0546bef37027a950.verified.txt b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_0546bef37027a950.verified.txt index 888466ab4a..397a36867b 100644 --- a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_0546bef37027a950.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_0546bef37027a950.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_0ac567dd32a2e8f5.verified.txt b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_0ac567dd32a2e8f5.verified.txt index 8841c0f326..d304df7085 100644 --- a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_0ac567dd32a2e8f5.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_0ac567dd32a2e8f5.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_0c06949221514e77.verified.txt b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_0c06949221514e77.verified.txt index d56e05c483..ff833e5198 100644 --- a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_0c06949221514e77.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_0c06949221514e77.verified.txt @@ -23,7 +23,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_18667ab7db033e9d.verified.txt b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_18667ab7db033e9d.verified.txt index bc31484242..faf59ef911 100644 --- a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_18667ab7db033e9d.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_18667ab7db033e9d.verified.txt @@ -15,7 +15,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_2f42f44c328eb020.verified.txt b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_2f42f44c328eb020.verified.txt index 888466ab4a..397a36867b 100644 --- a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_2f42f44c328eb020.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_2f42f44c328eb020.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_3243d3f3441fdcc1.verified.txt b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_3243d3f3441fdcc1.verified.txt index bc31484242..faf59ef911 100644 --- a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_3243d3f3441fdcc1.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_3243d3f3441fdcc1.verified.txt @@ -15,7 +15,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_53350b8b47df2112.verified.txt b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_53350b8b47df2112.verified.txt index 48f5e7a7c9..bc08f75e48 100644 --- a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_53350b8b47df2112.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_53350b8b47df2112.verified.txt @@ -15,7 +15,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_6584e0ec46b8a11d.verified.txt b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_6584e0ec46b8a11d.verified.txt index 8fa9677f1d..85e52e4e7f 100644 --- a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_6584e0ec46b8a11d.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_6584e0ec46b8a11d.verified.txt @@ -19,7 +19,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_81cc88db3d4eecfb.verified.txt b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_81cc88db3d4eecfb.verified.txt index e3108801f5..1bcf97c8d7 100644 --- a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_81cc88db3d4eecfb.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_81cc88db3d4eecfb.verified.txt @@ -23,7 +23,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_8ea187616dbb5577.verified.txt b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_8ea187616dbb5577.verified.txt index 59f6636fb2..9d14eb779f 100644 --- a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_8ea187616dbb5577.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_8ea187616dbb5577.verified.txt @@ -15,7 +15,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_905845c29560a3ef.verified.txt b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_905845c29560a3ef.verified.txt index 888466ab4a..397a36867b 100644 --- a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_905845c29560a3ef.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_905845c29560a3ef.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_b2fd24fab5b80917.verified.txt b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_b2fd24fab5b80917.verified.txt index 8fa9677f1d..85e52e4e7f 100644 --- a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_b2fd24fab5b80917.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_b2fd24fab5b80917.verified.txt @@ -19,7 +19,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_bd7cd088755287c9.verified.txt b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_bd7cd088755287c9.verified.txt index 8fa9677f1d..85e52e4e7f 100644 --- a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_bd7cd088755287c9.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_bd7cd088755287c9.verified.txt @@ -19,7 +19,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_d2eccba2f836b380.verified.txt b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_d2eccba2f836b380.verified.txt index 48f5e7a7c9..bc08f75e48 100644 --- a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_d2eccba2f836b380.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_d2eccba2f836b380.verified.txt @@ -15,7 +15,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_d463eed7fe5e4bbe.verified.txt b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_d463eed7fe5e4bbe.verified.txt index 59f6636fb2..9d14eb779f 100644 --- a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_d463eed7fe5e4bbe.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_d463eed7fe5e4bbe.verified.txt @@ -15,7 +15,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_d5520dd5c33f7b8d.verified.txt b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_d5520dd5c33f7b8d.verified.txt index 48f5e7a7c9..bc08f75e48 100644 --- a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_d5520dd5c33f7b8d.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_d5520dd5c33f7b8d.verified.txt @@ -15,7 +15,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_eab4a6010e602b59.verified.txt b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_eab4a6010e602b59.verified.txt index bc31484242..faf59ef911 100644 --- a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_eab4a6010e602b59.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_eab4a6010e602b59.verified.txt @@ -15,7 +15,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_ecaa688829b4030e.verified.txt b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_ecaa688829b4030e.verified.txt index 59f6636fb2..9d14eb779f 100644 --- a/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_ecaa688829b4030e.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.VerifyCorrectConfigGenerationWithMultipleMutationOptions_ecaa688829b4030e.verified.txt @@ -15,7 +15,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { From c83b741c6d5880cd0c94f41fa22e6a4d229dd96f Mon Sep 17 00:00:00 2001 From: souvikghosh04 Date: Sat, 1 Nov 2025 09:39:50 +0530 Subject: [PATCH 6/9] Fix failing snapshot verification tests --- ...ntityWithSourceWithDefaultType.verified.txt | 18 +++++++++++++++++- ...ddingEntityWithoutIEnumerables.verified.txt | 18 +++++++++++++++++- ...StoredProcedureWithRestMethods.verified.txt | 18 +++++++++++++++++- ...sts.CosmosDbPostgreSqlDatabase.verified.txt | 18 +++++++++++++++++- ...tReadingRuntimeConfigForCosmos.verified.txt | 18 +++++++++++++++++- ...stReadingRuntimeConfigForMySql.verified.txt | 18 +++++++++++++++++- ...dingRuntimeConfigForPostgreSql.verified.txt | 18 +++++++++++++++++- 7 files changed, 119 insertions(+), 7 deletions(-) diff --git a/src/Cli.Tests/Snapshots/EndToEndTests.TestConfigGeneratedAfterAddingEntityWithSourceWithDefaultType.verified.txt b/src/Cli.Tests/Snapshots/EndToEndTests.TestConfigGeneratedAfterAddingEntityWithSourceWithDefaultType.verified.txt index a77ecc134b..9ea6e5e143 100644 --- a/src/Cli.Tests/Snapshots/EndToEndTests.TestConfigGeneratedAfterAddingEntityWithSourceWithDefaultType.verified.txt +++ b/src/Cli.Tests/Snapshots/EndToEndTests.TestConfigGeneratedAfterAddingEntityWithSourceWithDefaultType.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: false, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/EndToEndTests.TestConfigGeneratedAfterAddingEntityWithoutIEnumerables.verified.txt b/src/Cli.Tests/Snapshots/EndToEndTests.TestConfigGeneratedAfterAddingEntityWithoutIEnumerables.verified.txt index a19694b688..2685db11db 100644 --- a/src/Cli.Tests/Snapshots/EndToEndTests.TestConfigGeneratedAfterAddingEntityWithoutIEnumerables.verified.txt +++ b/src/Cli.Tests/Snapshots/EndToEndTests.TestConfigGeneratedAfterAddingEntityWithoutIEnumerables.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: false, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/EndToEndTests.TestUpdatingStoredProcedureWithRestMethods.verified.txt b/src/Cli.Tests/Snapshots/EndToEndTests.TestUpdatingStoredProcedureWithRestMethods.verified.txt index fef1d83bf2..c1f5280277 100644 --- a/src/Cli.Tests/Snapshots/EndToEndTests.TestUpdatingStoredProcedureWithRestMethods.verified.txt +++ b/src/Cli.Tests/Snapshots/EndToEndTests.TestUpdatingStoredProcedureWithRestMethods.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: false, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.CosmosDbPostgreSqlDatabase.verified.txt b/src/Cli.Tests/Snapshots/InitTests.CosmosDbPostgreSqlDatabase.verified.txt index 42e0ff5e2f..496bf5f97c 100644 --- a/src/Cli.Tests/Snapshots/InitTests.CosmosDbPostgreSqlDatabase.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.CosmosDbPostgreSqlDatabase.verified.txt @@ -15,7 +15,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Service.Tests/Snapshots/ConfigurationTests.TestReadingRuntimeConfigForCosmos.verified.txt b/src/Service.Tests/Snapshots/ConfigurationTests.TestReadingRuntimeConfigForCosmos.verified.txt index 420977ed26..c135dffdb6 100644 --- a/src/Service.Tests/Snapshots/ConfigurationTests.TestReadingRuntimeConfigForCosmos.verified.txt +++ b/src/Service.Tests/Snapshots/ConfigurationTests.TestReadingRuntimeConfigForCosmos.verified.txt @@ -19,7 +19,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: false, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Service.Tests/Snapshots/ConfigurationTests.TestReadingRuntimeConfigForMySql.verified.txt b/src/Service.Tests/Snapshots/ConfigurationTests.TestReadingRuntimeConfigForMySql.verified.txt index 6c81c138ce..0f30634609 100644 --- a/src/Service.Tests/Snapshots/ConfigurationTests.TestReadingRuntimeConfigForMySql.verified.txt +++ b/src/Service.Tests/Snapshots/ConfigurationTests.TestReadingRuntimeConfigForMySql.verified.txt @@ -15,7 +15,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: false, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Service.Tests/Snapshots/ConfigurationTests.TestReadingRuntimeConfigForPostgreSql.verified.txt b/src/Service.Tests/Snapshots/ConfigurationTests.TestReadingRuntimeConfigForPostgreSql.verified.txt index 5e8631d46f..6a4f569a2a 100644 --- a/src/Service.Tests/Snapshots/ConfigurationTests.TestReadingRuntimeConfigForPostgreSql.verified.txt +++ b/src/Service.Tests/Snapshots/ConfigurationTests.TestReadingRuntimeConfigForPostgreSql.verified.txt @@ -15,7 +15,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: false, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { From 32084d9fecce295c25024b9319dc3fcca3077476 Mon Sep 17 00:00:00 2001 From: souvikghosh04 Date: Sat, 1 Nov 2025 10:48:41 +0530 Subject: [PATCH 7/9] Fix snapshot verification tests --- ...nitTests.CosmosDbNoSqlDatabase.verified.txt | 18 +++++++++++++++++- ...gConfigWithoutConnectionString.verified.txt | 18 +++++++++++++++++- ...stReadingRuntimeConfigForMsSql.verified.txt | 18 +++++++++++++++++- 3 files changed, 51 insertions(+), 3 deletions(-) diff --git a/src/Cli.Tests/Snapshots/InitTests.CosmosDbNoSqlDatabase.verified.txt b/src/Cli.Tests/Snapshots/InitTests.CosmosDbNoSqlDatabase.verified.txt index b3f63dd336..50e3aa35b8 100644 --- a/src/Cli.Tests/Snapshots/InitTests.CosmosDbNoSqlDatabase.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.CosmosDbNoSqlDatabase.verified.txt @@ -19,7 +19,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Cli.Tests/Snapshots/InitTests.TestInitializingConfigWithoutConnectionString.verified.txt b/src/Cli.Tests/Snapshots/InitTests.TestInitializingConfigWithoutConnectionString.verified.txt index 3c281ad6aa..6714b2a50d 100644 --- a/src/Cli.Tests/Snapshots/InitTests.TestInitializingConfigWithoutConnectionString.verified.txt +++ b/src/Cli.Tests/Snapshots/InitTests.TestInitializingConfigWithoutConnectionString.verified.txt @@ -18,7 +18,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: true, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { diff --git a/src/Service.Tests/Snapshots/ConfigurationTests.TestReadingRuntimeConfigForMsSql.verified.txt b/src/Service.Tests/Snapshots/ConfigurationTests.TestReadingRuntimeConfigForMsSql.verified.txt index b622552ef5..5b2a607817 100644 --- a/src/Service.Tests/Snapshots/ConfigurationTests.TestReadingRuntimeConfigForMsSql.verified.txt +++ b/src/Service.Tests/Snapshots/ConfigurationTests.TestReadingRuntimeConfigForMsSql.verified.txt @@ -23,7 +23,23 @@ }, Mcp: { Enabled: true, - Path: /mcp + Path: /mcp, + DmlTools: { + AllToolsEnabled: true, + DescribeEntities: true, + CreateRecord: true, + ReadRecords: true, + UpdateRecord: true, + DeleteRecord: true, + ExecuteEntity: true, + UserProvidedAllToolsEnabled: false, + UserProvidedDescribeEntities: true, + UserProvidedCreateRecord: true, + UserProvidedReadRecords: true, + UserProvidedUpdateRecord: true, + UserProvidedDeleteRecord: true, + UserProvidedExecuteEntity: true + } }, Host: { Cors: { From d178e01ff2d4eb2401f1be5fea42ca0b7e7bdb06 Mon Sep 17 00:00:00 2001 From: souvikghosh04 Date: Tue, 4 Nov 2025 12:03:31 +0530 Subject: [PATCH 8/9] Set tools to true by default in constructor --- .../Converters/DmlToolsConfigConverter.cs | 5 +-- src/Config/ObjectModel/DmlToolsConfig.cs | 43 ++++++------------- 2 files changed, 15 insertions(+), 33 deletions(-) diff --git a/src/Config/Converters/DmlToolsConfigConverter.cs b/src/Config/Converters/DmlToolsConfigConverter.cs index 9acef0f9b2..098bc64bc3 100644 --- a/src/Config/Converters/DmlToolsConfigConverter.cs +++ b/src/Config/Converters/DmlToolsConfigConverter.cs @@ -37,7 +37,7 @@ internal class DmlToolsConfigConverter : JsonConverter // Handle object format if (reader.TokenType is JsonTokenType.StartObject) { - // When using object format, unspecified tools default to true + // Start with null values - only set when explicitly provided in JSON bool? describeEntities = null; bool? createRecord = null; bool? readRecords = null; @@ -102,8 +102,7 @@ internal class DmlToolsConfigConverter : JsonConverter } } - // Create the config with specified values - // Unspecified values (null) will default to true in the DmlToolsConfig constructor + // Pass null for unspecified values - the constructor will handle defaults return new DmlToolsConfig( allToolsEnabled: null, describeEntities: describeEntities, diff --git a/src/Config/ObjectModel/DmlToolsConfig.cs b/src/Config/ObjectModel/DmlToolsConfig.cs index 71171a686c..a08fd8d176 100644 --- a/src/Config/ObjectModel/DmlToolsConfig.cs +++ b/src/Config/ObjectModel/DmlToolsConfig.cs @@ -71,41 +71,24 @@ public DmlToolsConfig( AllToolsEnabled = DEFAULT_ENABLED; } - if (describeEntities is not null) - { - DescribeEntities = describeEntities; - UserProvidedDescribeEntities = true; - } + // Set values with defaults and track user-provided status + DescribeEntities = describeEntities ?? DEFAULT_ENABLED; + UserProvidedDescribeEntities = describeEntities is not null; - if (createRecord is not null) - { - CreateRecord = createRecord; - UserProvidedCreateRecord = true; - } + CreateRecord = createRecord ?? DEFAULT_ENABLED; + UserProvidedCreateRecord = createRecord is not null; - if (readRecords is not null) - { - ReadRecords = readRecords; - UserProvidedReadRecords = true; - } + ReadRecords = readRecords ?? DEFAULT_ENABLED; + UserProvidedReadRecords = readRecords is not null; - if (updateRecord is not null) - { - UpdateRecord = updateRecord; - UserProvidedUpdateRecord = true; - } + UpdateRecord = updateRecord ?? DEFAULT_ENABLED; + UserProvidedUpdateRecord = updateRecord is not null; - if (deleteRecord is not null) - { - DeleteRecord = deleteRecord; - UserProvidedDeleteRecord = true; - } + DeleteRecord = deleteRecord ?? DEFAULT_ENABLED; + UserProvidedDeleteRecord = deleteRecord is not null; - if (executeEntity is not null) - { - ExecuteEntity = executeEntity; - UserProvidedExecuteEntity = true; - } + ExecuteEntity = executeEntity ?? DEFAULT_ENABLED; + UserProvidedExecuteEntity = executeEntity is not null; } /// From 76134b0b1b3cb6aa3c33749a217886134ade804e Mon Sep 17 00:00:00 2001 From: Souvik Ghosh Date: Tue, 4 Nov 2025 21:21:50 +0530 Subject: [PATCH 9/9] Update src/Config/ObjectModel/McpRuntimeOptions.cs Co-authored-by: Aniruddh Munde --- src/Config/ObjectModel/McpRuntimeOptions.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Config/ObjectModel/McpRuntimeOptions.cs b/src/Config/ObjectModel/McpRuntimeOptions.cs index 8a4549c3d9..3934c091bb 100644 --- a/src/Config/ObjectModel/McpRuntimeOptions.cs +++ b/src/Config/ObjectModel/McpRuntimeOptions.cs @@ -51,7 +51,7 @@ public McpRuntimeOptions( // if DmlTools is null, set All tools enabled by default if (DmlTools is null) { - this.DmlTools = DmlToolsConfig.FromBoolean(true); + this.DmlTools = DmlToolsConfig.FromBoolean(DmlToolsConfig.DEFAULT_ENABLED); } else {