Perhaps it was (relatively) easy. What made it easy was precisely that it was Apple: full & willing integration with the iOS ecosystem. A couple UI clicks/taps, if not outright automatic, and your AirPods are happily talking to the device you want to hear from.
All competitors have to cope with interface limitations and API inadequacies. Even one extra obligatory UI step can practically ruin the experience (as compared to AirPods).
Getting to the point where deep integration is easy ... is hard.
You will not believe how low key was that project. It could've easily been a design from an average if not a lower tier OEM.