Only allow specific emails to register.
Using user profile capabilities of keycloak you can define a Regexp on the email field that will only allow certain domails to register.
The Regexp should look something like this and can be generated easily with this helper.
Find the source code of the register page showed in the video here.
The legacy way of doing it would be with this plugin and usingkcContext["authorizedMailDomains"]
to validate in realtime.