There is a website which when you get to it you have to type in the pin and submit it. After you've done that, the website shows "another" website with the same link.
When I try to make it with a post, it returns the content of the website in which you have to type the pin and not the other website.
So I think there should be a way to send a post request which transfers the pin and then keeps the connection and responds the "other" website content after that.
Code:
const axios = require('axios');
const https = require('https');
const httpsAgent = new https.Agent({ keepAlive: true })
var url = "https://www.google.com" //just an example
var userPin = 2345 //just an example
// Send a POST request
axios
.post(url, {
httpsAgent,
data: {
pin: userPin
}
})
.then((response) => {
console.log(response.data)
})
.catch(err => console.log(err))