Hi Guys . Gud morning . I am trying to call below url by passing token value. But getting error response code 406. But while testing in rest url testing client like postman it is giving me valid response . I am passing the correct content type as well . Can some one please tell if below code is correct . Thanks in advance .
var sURL = "REST URL";
var header = { "Authorization": "Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6Ikp",
"Content-Length": "0",
"Content-Type": "application/json" };
var request = https.get({
url: sURL,
headers: header
});
log.debug('req',request);`