Skip to content

Commit eeac569

Browse files
committed
updated the describe-entties to describe_entities
1 parent 3354db0 commit eeac569

6 files changed

Lines changed: 12 additions & 12 deletions

File tree

schemas/dab.draft.schema.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -264,9 +264,9 @@
264264
"description": "Individual DML tools configuration",
265265
"additionalProperties": false,
266266
"properties": {
267-
"describe-entities": {
267+
"describe_entities": {
268268
"type": "boolean",
269-
"description": "Enable/disable the describe-entities tool.",
269+
"description": "Enable/disable the describe_entities tool.",
270270
"default": false
271271
},
272272
"create-record": {

src/Azure.DataApiBuilder.Mcp/BuiltInTools/DescribeEntitiesTool.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,19 +23,19 @@ public class DescribeEntitiesTool : IMcpTool
2323
public ToolType ToolType { get; } = ToolType.BuiltIn;
2424

2525
/// <summary>
26-
/// Gets the metadata for the describe-entities tool.
26+
/// Gets the metadata for the describe_entities tool.
2727
/// </summary>
2828
public Tool GetToolMetadata()
2929
{
3030
return new Tool
3131
{
32-
Name = "describe-entities",
32+
Name = "describe_entities",
3333
Description = "Lists and describes all entities in the database, including their types and available operations."
3434
};
3535
}
3636

3737
/// <summary>
38-
/// Executes the describe-entities tool, returning metadata about all configured entities.
38+
/// Executes the describe_entities tool, returning metadata about all configured entities.
3939
/// </summary>
4040
public Task<CallToolResult> ExecuteAsync(
4141
JsonDocument? arguments,

src/Cli/Commands/ConfigureOptions.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ public ConfigureOptions(
183183
[Option("runtime.mcp.dml-tools.enabled", Required = false, HelpText = "Enable DAB's MCP DML tools endpoint. Default: true (boolean).")]
184184
public bool? RuntimeMcpDmlToolsEnabled { get; }
185185

186-
[Option("runtime.mcp.dml-tools.describe-entities.enabled", Required = false, HelpText = "Enable DAB's MCP describe entities tool. Default: true (boolean).")]
186+
[Option("runtime.mcp.dml-tools.describe_entities.enabled", Required = false, HelpText = "Enable DAB's MCP describe entities tool. Default: true (boolean).")]
187187
public bool? RuntimeMcpDmlToolsDescribeEntitiesEnabled { get; }
188188

189189
[Option("runtime.mcp.dml-tools.create-record.enabled", Required = false, HelpText = "Enable DAB's MCP create record tool. Default: true (boolean).")]

src/Cli/ConfigGenerator.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1042,7 +1042,7 @@ private static bool TryUpdateConfiguredMcpValues(
10421042
{
10431043
describeEntities = (bool)updatedValue;
10441044
hasToolUpdates = true;
1045-
_logger.LogInformation("Updated RuntimeConfig with runtime.mcp.dml-tools.describe-entities as '{updatedValue}'", updatedValue);
1045+
_logger.LogInformation("Updated RuntimeConfig with runtime.mcp.dml-tools.describe_entities as '{updatedValue}'", updatedValue);
10461046
}
10471047

10481048
updatedValue = options?.RuntimeMcpDmlToolsCreateRecordEnabled;

src/Config/Converters/DmlToolsConfigConverter.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ internal class DmlToolsConfigConverter : JsonConverter<DmlToolsConfig>
6464

6565
switch (property?.ToLowerInvariant())
6666
{
67-
case "describe-entities":
67+
case "describe_entities":
6868
describeEntities = value;
6969
break;
7070
case "create-record":
@@ -90,7 +90,7 @@ internal class DmlToolsConfigConverter : JsonConverter<DmlToolsConfig>
9090
else
9191
{
9292
// Error on non-boolean values for known properties
93-
if (property?.ToLowerInvariant() is "describe-entities" or "create-record"
93+
if (property?.ToLowerInvariant() is "describe_entities" or "create-record"
9494
or "read-records" or "update-record" or "delete-record" or "execute-entity")
9595
{
9696
throw new JsonException($"Property '{property}' must be a boolean value.");
@@ -154,7 +154,7 @@ public override void Write(Utf8JsonWriter writer, DmlToolsConfig? value, JsonSer
154154

155155
if (value.UserProvidedDescribeEntities && value.DescribeEntities.HasValue)
156156
{
157-
writer.WriteBoolean("describe-entities", value.DescribeEntities.Value);
157+
writer.WriteBoolean("describe_entities", value.DescribeEntities.Value);
158158
}
159159

160160
if (value.UserProvidedCreateRecord && value.CreateRecord.HasValue)

src/Config/ObjectModel/DmlToolsConfig.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ public record DmlToolsConfig
2222
public bool AllToolsEnabled { get; init; }
2323

2424
/// <summary>
25-
/// Whether describe-entities tool is enabled
25+
/// Whether describe_entities tool is enabled
2626
/// </summary>
2727
public bool? DescribeEntities { get; init; }
2828

@@ -139,7 +139,7 @@ public static DmlToolsConfig FromBoolean(bool enabled)
139139
public bool UserProvidedAllToolsEnabled { get; init; } = false;
140140

141141
/// <summary>
142-
/// Flag which informs CLI and JSON serializer whether to write describe-entities
142+
/// Flag which informs CLI and JSON serializer whether to write describe_entities
143143
/// property/value to the runtime config file.
144144
/// </summary>
145145
[JsonIgnore(Condition = JsonIgnoreCondition.Always)]

0 commit comments

Comments
 (0)