# Http request node stopped working after update to node red 2.1 - but only for https://tesla.com (solved)

**URL:** <https://discourse.nodered.org/t/http-request-node-stopped-working-after-update-to-node-red-2-1-but-only-for-https-tesla-com-solved/56681>\
**Category:** General\
**Tags:** http-request\
**Created:** [15 January 2022 01:16 UTC](https://discourse.nodered.org/t/http-request-node-stopped-working-after-update-to-node-red-2-1-but-only-for-https-tesla-com-solved/56681 "2022-01-15T01:16:37Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![MAK](https://avatars.discourse-cdn.com/v4/letter/m/dc4da7/32.png) [@MAK](https://discourse.nodered.org/u/MAK)\
**Post date:** [15 January 2022 01:16 UTC](https://discourse.nodered.org/t/http-request-node-stopped-working-after-update-to-node-red-2-1-but-only-for-https-tesla-com-solved/56681/1 "2022-01-15T01:16:37Z")

</div>

Hi,

after updating to node red 2.1.5 (from a 1.2 install on an ubuntu server) I've troubles with the http-request node. The node is requesting the page, but gets "no response from server". Log says ""TimeoutError: Timeout awaiting 'request' for 120000ms : BUT ONLY from the [tesla.com](http://tesla.com) domain.

Background

- I have a simple flow to pull the page from [https://shop.tesla.com/de\_de/product/model-y-dachgepacktrager](https://shop.tesla.com/de_de/product/model-y-dachgepacktrager) (this is the german shop page for a roof rack - which is currently not available). I process the result and alert myself in the case the part gets available. I trigger the flow every 15 minutes.
- This worked fine on node red 1.2. Since the upgrade to node red 2.1.5 the node runs into a timeout - no response from server

After some testing I found

- every request to [tesla.com](http://tesla.com) runs into a timeout
- every request to another domain I tried still works fine (e.g. [https://google.com](https://google.com))

The node is pretty basic. Just GET url without any options. Testcase with two http response nodes:

```auto
[{"id":"9bb9d33057185e78","type":"http request","z":"e8931623.4900e8","name":"","method":"GET","ret":"txt","paytoqs":"ignore","url":"https://tesla.com","tls":"","persist":false,"proxy":"","authType":"","senderr":false,"credentials":{},"x":350,"y":2040,"wires":[["214501b94e6783b6"]]},{"id":"88e3a696b234bae7","type":"http request","z":"e8931623.4900e8","name":"","method":"GET","ret":"txt","paytoqs":"ignore","url":"https://google.com","tls":"","persist":false,"proxy":"","authType":"","senderr":false,"x":350,"y":2100,"wires":[["4bd6bcf8c756fcc1"]]},{"id":"e3d4d18be09531d2","type":"inject","z":"e8931623.4900e8","name":"Start","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":130,"y":2100,"wires":[["88e3a696b234bae7"]]},{"id":"f1783bf702adc595","type":"inject","z":"e8931623.4900e8","name":"Start","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":130,"y":2040,"wires":[["9bb9d33057185e78"]]},{"id":"214501b94e6783b6","type":"debug","z":"e8931623.4900e8","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":550,"y":2040,"wires":[]},{"id":"4bd6bcf8c756fcc1","type":"debug","z":"e8931623.4900e8","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":550,"y":2100,"wires":[]}]

```

The first http request ([tesla.com](http://tesla.com)) runs into timeout. The second ([google.com](http://google.com)) works fine...

I also tried to pull [tesla.com](http://tesla.com) (via wget [https://tesla.com](https://tesla.com)) on the server which running node-red, this still works fine, so it doesnt look by server is blacklisted or such things... node red install is simple ubuntu (via sudo npm install -g --unsafe-perm node-red)

Any ideas where to start diagnosis?

---

<div class="post-metadata">

**Author:** ![UnborN](https://avatars.discourse-cdn.com/v4/letter/u/4491bb/32.png) [@UnborN](https://discourse.nodered.org/u/UnborN)\
**Post date:** [15 January 2022 06:00 UTC](https://discourse.nodered.org/t/http-request-node-stopped-working-after-update-to-node-red-2-1-but-only-for-https-tesla-com-solved/56681/2 "2022-01-15T06:00:02Z")

</div>

Hello Mak,

Try to put a Function node before the http-request to set a couple of headers.

**Example flow**

```auto
[{"id":"9bb9d33057185e78","type":"http request","z":"54efb553244c241f","name":"","method":"GET","ret":"txt","paytoqs":"ignore","url":"https://shop.tesla.com/de_de/product/model-y-dachgepacktrager","tls":"","persist":false,"proxy":"","authType":"","senderr":false,"x":670,"y":1180,"wires":[["214501b94e6783b6"]]},{"id":"f1783bf702adc595","type":"inject","z":"54efb553244c241f","name":"Start","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":false,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":310,"y":1180,"wires":[["55012c8f0d15df7f"]]},{"id":"214501b94e6783b6","type":"debug","z":"54efb553244c241f","name":"","active":true,"tosidebar":true,"console":true,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":880,"y":1180,"wires":[]},{"id":"55012c8f0d15df7f","type":"function","z":"54efb553244c241f","name":"","func":"msg.headers = {\n \"User-Agent\": \"PostmanRuntime/7.28.4\",\n \"Accept\": \"text/html; charset=UTF-8\",\n \"Cache-Control\": \"no-cache\",\n \"Connection\": \"keep-alive\"\n}\n\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":480,"y":1180,"wires":[["9bb9d33057185e78"]]}]

```

---

<div class="post-metadata">

**Author:** ![MAK](https://avatars.discourse-cdn.com/v4/letter/m/dc4da7/32.png) [@MAK](https://discourse.nodered.org/u/MAK)\
**Post date:** [15 January 2022 08:57 UTC](https://discourse.nodered.org/t/http-request-node-stopped-working-after-update-to-node-red-2-1-but-only-for-https-tesla-com-solved/56681/3 "2022-01-15T08:57:19Z")

</div>

That did it!

Thanks UnborN!!!

---

<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:** [29 January 2022 08:57 UTC](https://discourse.nodered.org/t/http-request-node-stopped-working-after-update-to-node-red-2-1-but-only-for-https-tesla-com-solved/56681/4 "2022-01-29T08:57:38Z")

</div>

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