类型错误:从 Devportal 中的 Swagger 控制台调用 API 时无法获取问题 [英] TypeError: Failed to fetch Issues when invoking API from the Swagger console in the Devportal
问题描述
从 Devportal 中的 Swagger 控制台调用 API 时,我遇到了一个问题
when invoking API from the Swagger console in the Devportal I am faced with a problem
TypeError: Failed to fetch Issues
但是,当我在 -insecure 中使用 Curl 调用时,它成功运行,那么 Devportal 中的 wagger 控制台有什么问题?这是浏览器控制台输出:
But, When I invoke with Curl in -insecure, it successfully works, so what is the problem with wagger console in the Devportal? this is browser console output :
但在邮递员 &删除端口号后卷曲,其工作原理如下:
But in postman & Curl after remove port number, it works as following :
推荐答案
根据共享的 cURL 输出,当您尝试使用 :8243
调用 API 时,它正在获取 Connection拒绝
.因此,您可以尝试在没有端口的情况下更新网关环境配置并尝试该场景吗?
As per the shared cURL outputs, when you are trying to invoke the API with :8243
, it is getting Connection Refused
. Therefore, can you try updating the Gateway Environment configuration without the port and try out the scenario?
下面给出的是没有为 https_endpoint
[[apim.gateway.environment]]
name = "Default"
...
http_endpoint = "http://localhost:${http.nio.port}"
# remove the port section
https_endpoint = "https://gw.am.wso2.com"
...
更新配置后,保存并重启服务器并尝试场景.
Once updating the configurations, save and restart the server and try out the scenario.
这篇关于类型错误:从 Devportal 中的 Swagger 控制台调用 API 时无法获取问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!