【发布时间】:2022-01-10 11:43:24
【问题描述】:
我有脚本:
<set-variable value="#[attributes.headers['Authorization']]" doc:name="apikey" doc:id="69f6509e-8c0c-4832-854e-d7c07675cb49" variableName="apiKey"/>
<http:request method="GET" doc:name="Request" doc:id="86d51474-a71e-438c-bb24-59471424c4f9" config-ref="HTTP_Request_configuration">
<http:headers ><![CDATA[#[output application/java
---
{
Authorization : vars.apiKey
}]]]></http:headers>
</http:request>
在邮递员中我有 Headers Key: Authorization 和 value the apiKey。
在 Postman 中调用后,我在 AS 中收到此消息: 对资源的 HTTP GET 失败:错误请求 (400)
为什么我的要求不好?
【问题讨论】:
-
请提供有关问题的更多详细信息、您在做什么、有关错误和 HTTP 请求以及整个流程的更多详细信息。有关如何改进问题的指导,请参阅 stackoverflow.com/help/how-to-ask。
标签: mule anypoint-studio