# Http Request with etag Support

**URL:** <https://discourse.nodered.org/t/http-request-with-etag-support/2287>\
**Category:** General\
**Created:** [14 August 2018 19:32 UTC](https://discourse.nodered.org/t/http-request-with-etag-support/2287 "2018-08-14T19:32:04Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![little.yoda](https://avatars.discourse-cdn.com/v4/letter/l/ce7236/32.png) [@little.yoda](https://discourse.nodered.org/u/little.yoda)\
**Post date:** [14 August 2018 19:32 UTC](https://discourse.nodered.org/t/http-request-with-etag-support/2287/1 "2018-08-14T19:32:04Z")

</div>

i wonder if there is an http request function with [etag](https://en.wikipedia.org/wiki/HTTP_ETag) support.

My goal is that the file will only be downloaded if the etag changes.

in principle the node must save the etag value after the first download and then perform the request with an "If-None-Match" header.

Any help is welcome.

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [14 August 2018 21:30 UTC](https://discourse.nodered.org/t/http-request-with-etag-support/2287/2 "2018-08-14T21:30:46Z")

</div>

You can set the headers using `msg.header` - does that help? You would have to form the etag header yourself of course.

---

<div class="post-metadata">

**Author:** ![bbigras](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/bbigras/32/34750_2.png) [@bbigras](https://discourse.nodered.org/u/bbigras)\
**Post date:** [22 January 2021 15:32 UTC](https://discourse.nodered.org/t/http-request-with-etag-support/2287/3 "2021-01-22T15:32:36Z")

</div>

Sorry to post on an old thread, but I would like etag support too.

I was able to test caching the `etag` myself but if the default http request would support etag and maybe caching.

If the default http request would do that, maybe it would be lighter on the target website since we would just get a `304 Not Modified` code instead of the full reply and maybe in node-red we could have something like "only go to the next step if the value changed".
