Adding player and admin users for the Meme Game
Learn how to add users and groups in PingOne and use them for API access control.
Before you begin
Complete Tutorial 1: Controlling access to APIs managed by an API service to ensure you have:
-
Configured the authorization plugin to connect PingOne to Kong Gateway
-
Defined a managed API service for the Meme Game
-
Authorized Postman, acting as the game client, to access the Meme Game API
About this task
As the first step in controlling which users can review submitted memes, you’ll create users in PingOne for the Meme Game administrator and the game player. Then, you’ll create an administrator group that you’ll use later to manage access to the API operation for reviewing memes.
Steps
-
Add users:
-
In PingOne, go to Directory → Users and click the icon next to Users.
First, you’ll add the player.
-
For Username, enter
gameplayer
. -
For Population, select Default, if it is not already selected.
-
Click Generate Password, then click the Eye icon and copy the password to a convenient location. You’ll need it later.
-
Click Save.
Next, you’ll add the administrator.
-
Click the icon next to Users.
-
For Username, enter
gameadmin
. -
Make sure the Population is Default.
-
Click Generate Password, then click the Eye icon and copy the password to a convenient location.
-
Click Save.
Result:
The Users page shows your users.
Next, you’ll create a group for game administrators and add the gameadmin user to this group. Groups provide a way to organize a collection of users, making it easier to manage access to applications and operations.
-
-
Add a group:
-
Go to Directory → Groups and click the icon next to Groups.
-
For the Group Name, enter
Meme Game Admins
, and then click Save. -
Click the Users tab and then click Add Individually.
Result:
The All Users tab shows all available users.
-
Select the gameadmin check box.
-
Click Save.
Result:
The gameadmin user is now a member of the Meme Game Admins group.
-
Result
You’ve set up users and a group.
Next steps
Use the group in a rule to control access to an API operation.