game / pragma.inventory / InventoryService / applyInventoryOperationsOperatorV1 /

applyInventoryOperationsOperatorV1 #

suspend fun applyInventoryOperationsOperatorV1(session: OperatorSession, request: InventoryRpc.ApplyInventoryOperationsOperatorV1Request): InventoryRpc.ApplyInventoryOperationsOperatorV1Response

processes collections of inventory data operations: grants, updates, destroy, rewards for stackable and instanced items


  • InstancedItemPlugin.newInstanced for InstancedItemServerGrants
  • InstancedItemPlugin.update called for ServerInstancedItemUpdates
  • StackableItemPlugin.onUpdate for stackable item grants and updates


  • IllegalStateException - If an item destroy does not have a specific item set on it.
  • PragmaError.InventoryService_PlayerIdNotFound - If player ID not found.
  • PragmaError.InventoryService_CatalogIdNotFound - When update entry has a catalog ID that does not exist.
  • PragmaError.InventoryService_InstanceNotFound - When the item to update is not found in the player’s inventory.
  • PragmaError.InventoryService_RequirementsNotMetError - If update entry needs instance items and the user did not provide enough.
  • PragmaError.InventoryService_RequirementsNotMetError - If user passed in an instanced item not part of the update entry.
  • PragmaError.InventoryService_GrantError - When db errors.
  • PragmaError.InventoryService_GetError - When db retrieve fails.
  • PragmaError.InventoryService_Overflow - If requested more than a long.
  • PragmaError.InventoryService_StackLimitExceeded - If asked more than stackable limit.