Get data from WordPress into Auth0 user_meta

I have Auth0 plugin installed on my WordPress site and I’m using it to log users into WordPress. Once the user is logged into WordPress, they can select which business of theirs they want to manage. So their “current business ID” can change and is only known within WordPress.

What I need to do is send the “current business ID” number to Auth0 at the moment they try to login to a third party app.

Right now the user logs into WP, but I have to manually set the “current business ID” in Auth0 (under User Management > Users > individual user > set the “current business ID” in user_metadata). Then in WP the user can click to log into third party app and it works.

But what I need is to get the “current business ID” at the moment the user clicks to go to the third party app, because it changes and is only known in WP at the moment of click.