One sort point, two views. What moves between the systems, and the race the answer has to win.
Needed to make the correct decision. A barcode, a weight, a destination code, an order status.
The source of that information. Embedded in the barcode at the machine, or a lookup from a higher system through middleware.
Who makes the call. The PLC on local logic, or a request up to the WCS or WMS and a wait for the answer.
The PLC reads the identification and sends it up through middleware with a request for routing.
The WCS or WMS looks up the item, picks the destination, and returns the routing instruction.
The PLC executes the divert and reports back that the item reached its assigned destination.