node.js - request follow redirection without post data -
i'm using request.js http request in node.js. request({ method: 'post', uri: 'http://www.example.com/getdata', followallredirects: true, followoriginalhttpmethod: true, json: true, form: { id: 1, msg: 'test data', }, }, (err, res, body) => {}) let's when post { id: 1, msg: 'test data' } http://www.example.com/getdata , proxy redirect http://us.example.com/getdata . the codes above redirect http://us.example.com/getdata , how can set redirection post data? this hard if not impossible. if redirects done sending "301 moved permanently" or "302 found" http status code in practice works if "303 see other" sent, i.e. get request made with no data sent in body . see list of http status codes on wikipedia: this example of industry practice contradicting standard. http/1.0 specification (rfc 1945) required client perform temporary redirect (the original describing p...