# Http request returning a partial response

**URL:** <https://discourse.nodered.org/t/http-request-returning-a-partial-response/48981>\
**Category:** General\
**Created:** [27 July 2021 20:17 UTC](https://discourse.nodered.org/t/http-request-returning-a-partial-response/48981 "2021-07-27T20:17:04Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![brunoamaral](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/brunoamaral/32/16112_2.png) [@brunoamaral](https://discourse.nodered.org/u/brunoamaral)\
**Post date:** [27 July 2021 20:17 UTC](https://discourse.nodered.org/t/http-request-returning-a-partial-response/48981/1 "2021-07-27T20:17:04Z")

</div>

I'm using the HTTP Request node with some custom headers such as these:

```auto
  msg.headers['Connection'] = 'keep-alive'
  msg.headers['Pragma'] = 'no-cache' 
  msg.headers['Cache-Control'] = 'no-cache' 
  msg.headers['Accept'] = 'application/xml, text/xml, */*; q=0.01' 
  msg.headers['DNT'] = '1' 
  msg.headers['X-Requested-With'] = 'XMLHttpRequest' 
  msg.headers['Faces-Request'] = 'partial/ajax' 
  msg.headers['User-Agent'] = 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/92.0.4515.107 Safari/537.36' 
  msg.headers['Content-Type'] = 'application/x-www-form-urlencoded; charset=UTF-8' 

```

It works as expected, but the app is returning a partial response:

```auto
<partial-response><changes><update id="javax.faces.ViewState"><![CDATA[4972884326740660624:7593340223392667437]]></update></changes></partial-response>

```

This being a javaX app, I am guessing I should wait to get the full response. How could I do that in node-red? Or would it be better to make the request in the function node?

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [25 September 2021 20:17 UTC](https://discourse.nodered.org/t/http-request-returning-a-partial-response/48981/2 "2021-09-25T20:17:14Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
