enable mcp for tool for all endpoints

This commit is contained in:
Tanmay Deep Sharma
2025-06-02 15:53:29 +05:30
parent 7808634432
commit 65ac19718f
6 changed files with 27 additions and 5 deletions
+7
View File
@@ -22,6 +22,10 @@ module SwaggerTaskActions
resolve_file_ref: true, # Uses CWD (swagger_dir) for resolving file refs
logging: true
)
# Add x-mcp property to the final build
final_build['x-mcp'] = { 'enabled' => true }
File.write(swagger_json_relative_path, JSON.pretty_generate(final_build))
# For user messages, provide the absolute path
@@ -86,6 +90,9 @@ module SwaggerTaskActions
tag_spec['paths'] = _filter_paths_for_tag_group(tag_spec['paths'], tags_in_current_group)
tag_spec['tags'] = _filter_tags_for_tag_group(tag_spec['tags'], tags_in_current_group)
# Add x-mcp property to the tag spec
tag_spec['x-mcp'] = { 'enabled' => true }
output_filename = _determine_output_filename(group_name)
File.write(output_dir.join(output_filename), JSON.pretty_generate(tag_spec))
end
+4 -1
View File
@@ -11851,5 +11851,8 @@
"CSAT Survey Page"
]
}
]
],
"x-mcp": {
"enabled": true
}
}
+4 -1
View File
@@ -10180,5 +10180,8 @@
"CSAT Survey Page"
]
}
]
],
"x-mcp": {
"enabled": true
}
}
+4 -1
View File
@@ -4959,5 +4959,8 @@
"CSAT Survey Page"
]
}
]
],
"x-mcp": {
"enabled": true
}
}
+4 -1
View File
@@ -4366,5 +4366,8 @@
"CSAT Survey Page"
]
}
]
],
"x-mcp": {
"enabled": true
}
}
+4 -1
View File
@@ -5139,5 +5139,8 @@
"CSAT Survey Page"
]
}
]
],
"x-mcp": {
"enabled": true
}
}