admin08077 commited on
Commit
8066e02
·
verified ·
1 Parent(s): 65fe9b3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -1
app.py CHANGED
@@ -145,7 +145,12 @@ with gr.Blocks(theme=gr.themes.Default(primary_hue="blue")) as demo:
145
 
146
  res_choice.change(get_methods, inputs=res_choice, outputs=method_choice)
147
  method_choice.change(generate_payload, inputs=[res_choice, method_choice], outputs=params_input)
148
- run_btn.click(execute, inputs=[res_choice, method_choice, params_input], outputs=output_display)
 
 
 
 
 
149
 
150
  if __name__ == "__main__":
151
  demo.launch(server_name="0.0.0.0", server_port=7860)
 
145
 
146
  res_choice.change(get_methods, inputs=res_choice, outputs=method_choice)
147
  method_choice.change(generate_payload, inputs=[res_choice, method_choice], outputs=params_input)
148
+ run_btn.click(
149
+ run_api,
150
+ inputs=[res_choice, method_choice, params_input],
151
+ outputs=output_display,
152
+ api_name="run_api" # <--- THIS IS THE FIX
153
+ )
154
 
155
  if __name__ == "__main__":
156
  demo.launch(server_name="0.0.0.0", server_port=7860)