# Http in node cannot read params

**URL:** <https://discourse.nodered.org/t/http-in-node-cannot-read-params/45935>\
**Category:** General\
**Created:** [19 May 2021 16:39 UTC](https://discourse.nodered.org/t/http-in-node-cannot-read-params/45935 "2021-05-19T16:39:39Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![gspagoni](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/gspagoni/32/42059_2.png) [@gspagoni](https://discourse.nodered.org/u/gspagoni)\
**Post date:** [19 May 2021 16:39 UTC](https://discourse.nodered.org/t/http-in-node-cannot-read-params/45935/1 "2021-05-19T16:39:39Z")

</div>

Hello, I'm a newbie to nodered and I'm trying to use the HTTP in node to read the URL parameter of an external URL sent me by a service. the problem is that in the URL that I receive there is not a ? as for parameter but there is an (#)

ex: the external server calls [http://localhost:1880/redirect#access\_token=sghhdjkeòw](http://localhost:1880/redirect#access_token=sghhdjke%C3%B2w)  
I know that the correct way to read params should be [http://localhost:1880/redirect?access\_token=hjfkdsòahflak](http://localhost:1880/redirect?access_token=hjfkds%C3%B2ahflak)

in this case, I should find in the msg.payload.access\_token the result for the access\_token

do you have any idea how to solve this?

PS: I cannot modify the external URL format

thank you  
GS

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [19 May 2021 16:46 UTC](https://discourse.nodered.org/t/http-in-node-cannot-read-params/45935/2 "2021-05-19T16:46:26Z")

</div>

Hi @gspagoni

That is not possible to do. Browsers _never_ send the URL fragment (the bit after the #) to the server.

---

<div class="post-metadata">

**Author:** ![gspagoni](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/gspagoni/32/42059_2.png) [@gspagoni](https://discourse.nodered.org/u/gspagoni)\
**Post date:** [19 May 2021 16:50 UTC](https://discourse.nodered.org/t/http-in-node-cannot-read-params/45935/3 "2021-05-19T16:50:41Z")

</div>

thanks for the quick answer. what i'm trying to do is to make an authentication to a provider using OAuth2.0 flow. if i use the response\_type = code i need to make another call to the server, where if i set the response\_type = token i got back the token with one call  
so i would like avoiding to make 2 calls to get the token  
any hints?

thank you  
GS

---

<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:** [19 May 2021 16:58 UTC](https://discourse.nodered.org/t/http-in-node-cannot-read-params/45935/4 "2021-05-19T16:58:58Z")

</div>

If it is really sending you what you say, I think the full URL is in the response object somewhere, you will need to wade through the object to see where it is, I can never remember. Once you have it as a string, you can easily pull it apart and put the token into a header which is probably where it is needed for the next step I would think.

---

<div class="post-metadata">

**Author:** ![E1cid](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/e1cid/32/77971_2.png) [@E1cid](https://discourse.nodered.org/u/E1cid)\
**Post date:** [19 May 2021 17:35 UTC](https://discourse.nodered.org/t/http-in-node-cannot-read-params/45935/5 "2021-05-19T17:35:19Z")

</div>

Can you change the ex call to  
` http://localhost:1880/redirect/sghhdjkeòw`  
and use `/redirect/:access_token` as the http in url?

---

<div class="post-metadata">

**Author:** ![gspagoni](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/gspagoni/32/42059_2.png) [@gspagoni](https://discourse.nodered.org/u/gspagoni)\
**Post date:** [19 May 2021 17:37 UTC](https://discourse.nodered.org/t/http-in-node-cannot-read-params/45935/6 "2021-05-19T17:37:00Z")

</div>

Hi  
no i cannot change the format, i know the format is a bit strange but i cannot make any modification

---

<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:** [18 July 2021 17:37 UTC](https://discourse.nodered.org/t/http-in-node-cannot-read-params/45935/7 "2021-07-18T17:37:29Z")

</div>

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