hi All,
I have two service callouts to internal API Proxy. They both are placed in the request flow. When they run, the first call resource path gets appended to the second, e.g. 1st /test and then the second gets to become /another_resource/test
I have tried solving it using, the context.setVariable("target.copy.pathsuffix", false) using a JS Policy, as well as on AssignMessage in the <Set> section, but it does not seem to fix it.
Can you help.
Thanks
Someone here may be able to help. Can you show the configuration of the ServiceCallout policies?
Answer by Nkcubeko Jamela · Nov 01, 2017 at 10:39 AM
@Jared, Your question is not that clear but please check the following proxy
may be it might help
How this proxy works:
1st I have an assign message that attaches my api proxy base path to the service callout policy(s),
both of my targeted proxies have different target endpoint mock target and httpbin
and after i receive my response use extract variable and assign message policy to get the values I require.
Sorry i am not that good at explanations.Find attached my proxy.
@nkcubeko I figured what the problem is.
When I created the Service Callout services, I have forgotten to change the variable on the Service callout, and i ended up with unwanted uri, when I renamed it to unique name, it fixed the problem,
Thanks
Thanks. I faced the same and fixed by renaming the variable here . <Request clearPayload="true" variable="requestVar">
Unable to make HTTP request via httpClient or ServiceCallout policy 6 Answers
Issue calling target from Service call out policy 1 Answer
How can I avoid proxy.basepath copy in service callout LocalTargetConnection? 1 Answer
Access JSON response from Service Callout in Javascript 1 Answer
Service Callout policy getting timed out and unable to forward response to client 1 Answer