How do I set multiple headers in javascript httpclient request? I have the below code it doesnt set the values properly.
var headers = {'Content-Type':'application/json', 'Accept':'application/json', 'Cache-Control':'no-cache'};
var auditors = new Request();
auditors.url = "https://demo.api.confirmation.com/auditor";
auditors.headers = headers;
var auditor = httpClient.send(auditors);
context.setVariable("auditorsResponse",auditor.code);
I get the auditorsResponse as org.mozilla.javascript.Undefined@25ef85d5