Node.JS Servicecallout Policy documentation

Is there any examples describing how to use the Node.JS ServiceCallout policy option?

<ServiceCallout async="false" continueOnError="false" enabled="true" name="Token-Callout">
    <DisplayName>Token-Callout</DisplayName>
    <Properties/>
    <Request clearPayload="true" variable="myRequest">
        <IgnoreUnresolvedVariables>false</IgnoreUnresolvedVariables>
    </Request>
    <Response>calloutResponse</Response>
    <ScriptTarget>
        <ResourceURL/>
    </ScriptTarget>
</ServiceCallout>

Any pointer appreciated.

Michael McD.

0 4 603
4 REPLIES 4

Not applicable

Hi @michaelmcdowell

Node JS can be used only as target end points not in the service callout policy. If you want to use node js in service callout policy what you can do is create a separate proxy with Node JS as a target endpoint and then use this newly created proxy in your service callout policy with LocalTargetConnection element.

<LocalTargetConnection>
   <APIProxy/>
   <ProxyEndpoint/>
   <Path/>
</LocalTargetConnection>

To know more about use of nodejs in APIGEE edge Click here

Hope it helps !!

... and here's the direct link to the service callout policy docs: http://docs.apigee.com/api-services/reference/service-callout-policy for additional reference.

Hi @Vipul Agarwal, @Carlos Eberhardt

Thanks for getting back. This is the Node JS Service Callout option I was after some documentation on:

4182-apigee-service-callout.png

For example, how it can be used (if at all) with the Assign Message and Extract Variables policies.

Thanks again,

Michael

Ps In the mean time I've taken Vipul's suggestion to create a separate proxy with Node JS...

@michaelmcdowell I see what you are saying.

Looks like you can select the node.js target for your service callout from the UI but I don't think it is supported as I cannot deploy using that option.

I don't see any documentation related to that which makes me think it is a UI bug.

cc @Stephen Gilson