Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

How to use some external modules in javascript policy or node.js

Hi Team,

Please advise, how we can use xmlhttprequest() or fetch() or some other modules directly in javascript policy ? I am getting error, If I define like bellow in javascript

var XMLHttpRequest = require("xmlhttprequest").XMLHttpRequest;

var xhr = new XMLHttpRequest();

 Do I need to install and import packages for those from local to apigee cloud

0 1 215
1 REPLY 1