【发布时间】:2022-06-13 22:57:25
【问题描述】:
在为 Power Automate 创建自定义连接器时,我大摇大摆地收到以下错误(没有发生验证错误,我已通过多个编辑器进行了检查),
The request failed with client error: '{"Code":"","Message":"GET https://power-apim-europe-001.management.azure-api.net/subscriptions/873e5639-9775-4e58-ac59-935e3f7dbc6c/resourceGroups/apim-power-europe-001/providers/Microsoft.ApiManagement/service/power-apim-europe-001/apis/smartsheet-20api-5f83fde20557d336df-5f8f194df2cac2ec5c?import=true&protocols=https&path=apim%2fsmartsheet-20api-5f83fde20557d336df-5f8f194df2cac2ec5c&api-version=2019-01-01&asyncId=623a42ef47fc0015e44853aa&asyncCode=201 failed with BadRequest, content={\"error\":{\"code\":\"ValidationError\",\"message\":\"One or more fields contain incorrect values:\",\"details\":[{\"code\":\"ValidationError\",\"target\":\"value[121].urlTemplate\",\"message\":\"URL template is invalid\"}]}}","Target":null,"Details":[],"Innererror":null}'. The correlation Id is '7eabc939-4c3f-484e-bdbd-b4568844c321'.
Pastebin - Swagger File (由于问题正文的 SO 字符限制,粘贴到 pastebin)
我现在似乎正在用头撞砖墙,因为错误消息根本没有帮助。谁能发现这里有什么问题?
【问题讨论】:
-
我不知道那个巨大的 URL 是怎么回事,但那个招摇的文件在最新版本的 Swagger codegen CLI 上运行良好。
-
@stdunbar 这就是问题所在,我已经通过包括 Swagger Hub 在内的多个编辑器验证了文件,但是“一个或多个字段包含不正确的值”......我什至求助于手动尝试验证文件,但到目前为止什么都没有。
标签: swagger-2.0 power-automate connector