Shravan
Shravan

Reputation: 2919

Custom username in Keycloak

I want usernames (created using an algorithm) to be automatically assigned to users and want to allow login using both this username and email address. How do I do that in Keycloak?

Upvotes: 1

Views: 1201

Answers (1)

andrija
andrija

Reputation: 1192

  1. You can use rest api to create user. This way you can use alghoritm to generate username. Documentation is here: https://www.keycloak.org/docs-api/10.0/rest-api/index.html#_users_resource

  2. In the realm settings go to Login tab and enable Login with email enter image description here

Upvotes: 3

Related Questions