Custom Header with Auth Service Provider

Options

Our company is trying to implement custom authentication mechanism using photon fusion (Auth0 is our Identity Provider). Unfortunately we hit a wall as our API requires providing API key as http header which is not possible while configuring auth using your dashboard. I wanted to ask whether there is a way to implement custom authentication that’d allow us to set custom headers?

If this is not a viable solution, could we just bypass the built-in authentication and roll out own before initializing and connecting to Photon? Like reaching auth endpoint from unity and safely loading user data into game state. What do you think about security of this solution?  I also wanted to ask whether there is a way to set eg. UserId while authenticating so it cannot be changed later (as custom authentication does)? We’d really appreciate if you could guide us of how to load user data safely from endpoint secured with http header api key.