403 Forbidden error when accessing the webthing ( webthing-node) via Nginx reverse proxy or from public cloud

Hi Team,
I have few custom webthings running on my local sever and my webthings gateway is running on cloud. The idea is to use Nginx as a reverse proxy to server all the custom webthings under different URL and do a port forwarding from my router and add the custom webthings to my gateway running in cloud. I am doing this for a quick demo, I can access the webthing description locally but when I try to access the proxied webthings I am getting “403 Forbidden” error and also when I try to run a webthing in public cloud , I am facing the same issue . Any way to fix it ?

You need to make sure you provide the right hostname argument when creating your WebThingServer instance.