About display names
When a new user signs up to your app, you may want KWS to generate a unique display name for that user, as shown here:
To enable this, you need to provide a list of nouns and a list of adjectives. When a new user signs up, KWS randomly chooses a noun and an adjective from these lists. It then concatenates them, along with a random numeric code, to form a unique display name; for example, ‘greentiger2738’.
Set up nouns and adjectives
To define the nouns and adjectives that will be used to generate random display names for your app’s users:
- Log into your KWS Control Panel and select the app for which you wish to set up the display name nouns and adjectives.
- Under the Settings submenu, click the Display Names tab.
- To add a new noun or adjective, enter it in the relevant box, followed by a space.
- For adjectives, you can choose whether the adjective should come before or after the noun by clicking the Before button.
- To test the display name generator, click Generate.
- Click Save.
Localise your app’s display names
If you wish to generate display names in multiple languages, see Localise display names.
Generate a display name in a custom authentication UI
If you are using KWS user account management, but have chosen to build your own custom authentication UI, you can still generate a display name from the nouns and adjectives defined in your Control Panel. To do this, call the random-display-name endpoint from your authentication UI at the time of user creation.
This endpoint returns a randomly generated display name based on the nouns and adjectives you have provided for the app. The display name is checked for availability against other user’s display names in the same app. If no words are set for the current language option, the endpoint attempts to return an English display name.