How to perform a POST request with session data to an endpoint within the server node js <p>I am working on <code>express</code> and I need to perform a POST request to an endpoint within the server. My code for this is :</p> <pre><code>request({ url : 'http://localhost:3000/api/oauth2/authorize', qs:{ transaction_id:req.oauth2.transactionID, user:req.user, client : req.oauth2.client }, headers:{ 'Authorization':auth, 'Content-Type':'application/x-www-form-urlencoded' }, method:'POST' },function(err,res,bo){ console.log("Got response with body :"+bo); }); </code></pre> <p><code>localhost</code> is the current server, this works properly but the session data is lost when i perform the POST request.<br> Is there any other way to perform a POST within the same server or to save the session data such that it is maintained after the POST?</p>