The site responds correctly from the same browser with http://192.168.2.201:80/27/on
I tried running from the node-red extension (latest) of the HomeAssistant.io running on raspberryPi 4 and also from the latest docker node-red container. Both behave the same.
Also, have you tried a different browser to see if credentials are requested (to rule out cached browser credentials)
Some tips to make things a little easier:
When copying debug logs, please use the copy value tool node-red provides....
Pay particular attention to the part about the buttons that appear under your mouse pointer when you over hover a debug message property in the sidebar.
When posting code and logs please format them to help us read the data and prevent forum corruption...
In order to make code readable and usable it is necessary to surround your code with three backticks (also known as a left quote or backquote ```)
```
code goes here
```
You can edit and correct your post by clicking the pencil icon.
It's important to remember that the node-red code does NOT run in the browser you are using to edit the flow.
It runs in the backend NodeJS process, it does not have access to any cookies or pre-cached credentials that the browser does. Just because that browser can access something does not mean that the NodeJS process can.
As Steve suggested, try a different browser (not just a different window or tab from the same browser) or a command line tool like curl (which is included in nearly all OSes these days including Windows)
Thank you much. You were right about the credentials. I was experimenting with ESP32 hosted webserver and had forgotten that I recently added the authentication code. And I am glad you pointed me to the right direction.
Also thanks for the recommendation about including code in backticks.
Slow learner but I learn.