How do you detect an Apple Watch's distance from the Mac?

Has anyone been able to successfully create a connection between watchOS and macOS, such as using an Apple Watch to unlock a Mac? I know there's WC Session between iOS and WatchOS and then there's nearby interaction between two iOS devices. However, I want to know if any of you have been successfully able to do any kind fo interaction between watchOS and macOS.

For instance, here it says that Apple uses Wifi technology to approximate the distance between the mac and the watch: https://security.stackexchange.com/questions/158100/how-does-unlock-your-mac-with-apple-watch-work-what-should-i-consider-in-the

But I cannot find any concrete SwiftUI approach on it. Would appreciate if you know if any kits or methods to achieve any sort of interaction between the watch and the computer.

Hence the reason why they are called private APIs.

How do you detect an Apple Watch's distance from the Mac?
 
 
Q