I am trying to create an app that can communicate and send data between multiple nearby devices (likely around 2-6 devices at a time) without already being connected to the same network. This would function similarly to Apple's AirDrop and Nintendo's DS networking.
Compatibility between multiple operating systems is important. I would like to support the latest versions of Linux/Android/Windows at a minimum and preferably iOS/MacOS as well (if possible).
The app shouldn't interfere with an existing Wi-Fi or Internet connection if there is one, so solutions like FlyingCarpet (connects to a hotspot hosted by one device, disconnecting from Wi-Fi in the process) wont work.
Connecting devices should be simple; something like a permission popup is fine but the user shouldn't have to modify their settings for it to work.
Options I've looked at
I already tried to implement this using Bonjour. According to this thread, AirDrop uses it internally. Unfortunately the documentation is outdated and P2P doesn't appear to work anymore with the C api. I also could not find any documentation for P2P in the Linux implementation, Avahi.
Wi-Fi Direct seems like it may be an option, but I couldn't find a clear answer as to whether or not this would require some kind of authentication and pairing sequence prior to connecting.
Wi-Fi Aware/Neighbor Awareness Networking looks like it would fit well except that it seems to only be supported on select Android devices and not Linux nor Windows
OpenWirelessLink was another option I looked at, although it appears to be unmaintained since 2020