auth0 / passport-windowsauth

Windows Authentication strategy for Passport.js
MIT License
179 stars 51 forks source link

How to use authentication in internal requests? #63

Open lubochka opened 4 years ago

lubochka commented 4 years ago

Hi I am interested to use this library to send an internal request to another API endpoint. Someone has tryied it already? Maybe some code example?

var http = require('http');
        var proxyRequest = http.request({
            host: 'hhamlsittstsrv',//TODO:fix to our hostname
            method: 'POST',
            path: '/ChatBotAPI/api/PostDataFromCB',//TODO:fix to Rami endpoint
            data: user
        },
        function (proxyResponse) {
            proxyResponse.on('data', function (chunk) {

            });
        });
        return '';