Giving the Limited Grant #
There are several circumstances where players might be granted a one-time reward:
- new player bonus
- returning player incentives
- seasonal or event reward (such as logging in at least once during an event)
For demonstration purposes, we’ll be manually simulating service calls with Postman. This guide currently covers a basic reward scenario where the player is granted items shortly after logging in.
Start Pragma Engine #
Run Pragma Engine via one of the following methods.
Once the engine has started successfully, it prints the message [main] INFO main - Pragma server startup complete
.
Grant the reward #
- Log in using Postman by sending
PragmaDev ➨ Public ➨ Player - AuthenticateOrCreateV2
. - Verify the player’s inventory is empty with
PragmaDev ➨ Game ➨ RPC - Player ➨ Inventory ➨ getInventoryV2
. - Send
PragmaDev ➨ Game ➨ RPC - Player ➨ GameData ➨ getLoginDataV2
which will process limited grants. Any limited grants issued can be seen in the body of the response underresponse.payload.loginData.issuedLimitedGrantTrackingIds
. You should see the list containsStarterPack
but does not containNewYear2023Grant
as the window for this grant has already passed. This endpoint will also fetch the player’s full inventory. You should see 50coins
underresponse.payload.loginData.inventory
. - Resend
PragmaDev ➨ Game ➨ RPC - Player ➨ GameData ➨ getLoginDataV2
. Confirm thatloginData.issuedLimitedGrantTrackingIds
is empty which indicates no limited grants were issued on this login. You can also confirm the user still has 50coins
underresponse.payload.loginData.inventory
.