TPP Workflow (API Basic Flow)
API Pipeline
1. Search Products
POST /products/search2. Create Player
POST /players3. Credit Coins
PUT /coins4. Reserve Product
POST /orders/{playerId}/reservation5. Shipping Data
POST /orders/{playerId}/send/{transactionId}-
Download products
- Use paginated
POST /products/searchto retrieve the available catalog. - The response includes product data and values you must save in in your system and will use in the next steps.
- Use paginated
-
Create player
- Create the player in TPP with
POST /players. - Keep the returned
playerIdto continue the flow.
- Create the player in TPP with
-
Add coins equal to product value
- Credit the player using
PUT /coinswith the amount equivalent to the selected product value. - Although this may look as an extra step, this step is required for tracking and audit purposes.
- Credit the player using
-
Reserve the product
- Execute the reservation with
POST /orders/{playerId}/reservation. - This reserves the selected product for that player.
- Execute the reservation with
-
Send shipping information
- Complete shipping details with
POST /orders/{playerId}/send/{transactionId}. - Use the
transactionIdgenerated during the reservation step.
- Complete shipping details with
-
Logistics email communication
- Players will receive logistics emails with updates regarding their order status.