Peterson9244 I might have a better approach since you're using your site as the source of truth for user accounts.
The best bet, in my opinion, is to disable registrations on your flarum forum and build an SSO bridge from your main site to Flarum.
This will allow you to fine tune and sync memberships from the site to Flarum. Keeping things refined and simple. Signups and registrations can be redirected to the main site, and after auth, get sent back to the forum.
I've done this on several sites before. It's a decent sized project, but well worth it in my opinion. This allowed seemless logins between the two platforms instead of having to re-auth, which is the direction you would have gone with the other suggestion. It's still a valid input for sure, but not what you were asking specifically.