Try removing that function onRejected. Everything ...
# suitescript
j
Try removing that function onRejected. Everything I've ever seen looks more like:
Copy code
https.request.promise({
    method: https.Method.GET,
    url: '<https://www.testwebsite.com>'
})
    .then(function(response){
        log.debug({
            title: 'Response',
            details: response
        });
    })
    .catch(function(reason) {
        log.debug({
            title: 'Invalid Request: ',
            details: reason
        });
    })