Hi there, I am trying to get the callback/response of a post request sent from Roblox to my Webserver. You see, in Express, you can return a status code using return res.status(200)
under a app.post
function that receives post requests.
Is there a way where I could receive the status code returned from my Express app from a POST sent from Roblox? I could just use a pcall, except I’d like to know the EXACT status code returned as different codes can be sent and not just 401.
Lua
local http = game:GetService('HttpService')
local request = http:PostAsync('https://vxsqi.tk/ready','ready',Enum.HttpContentType.TextPlain,false)
-- print the status code returned here
Backend JS file from Webserver
app.post('/ready', (req, res) => {
return res.status(200).end()
});