Trying to see if this is possible.
When using the GatewayScript policy can the script reference external GatewayScript libraries to call standard utility functions? Since I need to write GatewayScript policies it would be useful to reference standard functions that are reused across API definitions and not embedded into each API specification file.
Example:
GatewayScript Policy:
var apim = require('apim');
var utils = require('local://common_utility.js');
apim.setvariable('message.headers.SOME-HEADER', utils.getSomeValue());
I have tried a couple of times to get this to work, but have been getting 500 errors.
-
result: "500 Internal Server Error"
-
error-code: "0x00c30044"
-
error-subcode: "0x00c30044"
------------------------------
Steve Ruscik
------------------------------