You could use ESP-NOW to send messages from one ESP32 to the other. Best way is to use MicroBlocks to program the ESP32 and the MicroBlocks extension to communicate with the boards from App Inventor.
This is the ESP-NOW library
MicroBlocks supports around 100 boards and a lot of different ESP32 boards


