@@ -82,12 +82,21 @@ def create_mcp_proxy():
8282 inputs_to_prompt = input_ids .intersection (existing_input_ids )
8383 inputs_to_prompt .update (input_ids ) # Add any undiscovered-by-config inputs
8484
85+ input_configs = []
8586 for input_id in inputs_to_prompt :
8687 input_def = next ((d for d in mcp_config .get ("inputs" , []) if d ["id" ] == input_id ), {})
8788 inputs [input_id ] = click .prompt (
8889 input_def .get ("description" , input_id ),
8990 hide_input = input_def .get ("password" , False ),
9091 )
92+ # Create InputParameters config entry
93+ input_configs .append (InputParameter (
94+ name = input_def .get ("name" , input_id ),
95+ type = input_def .get ("type" , "string" ),
96+ required = input_def .get ("required" , True ),
97+ key = input_id ,
98+ description = input_def .get ("description" , "" )
99+ ).__dict__ )
91100
92101 # Replace input tokens in args
93102 processed_args = [
@@ -103,7 +112,11 @@ def create_mcp_proxy():
103112
104113 # Execute with processed parameters
105114 output = asyncio .run (list_tools (command = server_config ["command" ], args = processed_args , env = processed_env ))
106- output_with_name = {"name" : server_name , ** output }
115+ output_with_name = {
116+ "name" : server_name ,
117+ "config" : input_configs ,
118+ ** output
119+ }
107120 click .echo (json .dumps (output_with_name , indent = 2 ))
108121
109122
0 commit comments