Nginx Proxy + Token redirect without login

Hi,
I am deploy Home Assistant for my company for all user can use this with own dashboard.

for security, I need to use Nginx as reverse proxy and it will redirect to the right dashboard, so I my idea something like image below

Can Nginx and HA authenticate like this?
for testing I user basic auth on Nginx to test. but in future I will intergate Nginx with ldap auth for Single Sign On solution.

Thanks for help!