Can 2 Android devices send data through their USB port?

I'm trying to send just a few characters (like a command) from one Android device to another. On the Android developer's website, there was a section in the developer's manuals for the USB communication that showed that an Android device can act either as a host or as an accessory when a device is connected to the USB port. NOW is the question: Can both sides be Android devices? I mean, one who declares himself host and the other accessory.

I did the data transfer before I used the nearby API that uses Bluetooth and Wi-Fi to discover a nearby device and connect to it.

I would be glad if you share your knowledge. I'm just looking forward to see if a similar scenario to the nearby API fits the USB port or not. AND is there any hope to achieve this? Is the time I spend on it worthwhile?