Show Player Points Balance

In some scenarios, you may need to show the player's points balance to your users with your experience. This will help them know their current points balance and its equivalent monetary value so that they are motivated to earn and collect more.
Generally the player's point balance can be retrieved either by Player Balance API or Player Progress API. In this tutorial we will be discussing Player Balance API.
​Player Balance API is a GET request that takes the playerUniqueId in its path as below{playerUnqiueId}/balance
The API is comprehensive and returns a full view of the current player balance status. It return the the total points currently in the player's balance in pointsBalance attribute and its monetary value in pointsValue attribute.
In case you have configure a return window for cashback pending points are also shown within the response in pendingPoints attribute and pendingPointsValue respectively.
"pointsBalance": 11500,
"pointsValue": 115,
"pendingPoints": 200,
"pendingPointsValue": 2,
"currency": "USD",
"pointsName": "Points"
The points that are available to use can be derived by
Total Points - Pending Points = Points available to be used
In addition to points balance information. The API returns the selected system currency and the configured name for points to easily rendered them in the UI element.