+1 Also trying to wrap my head around this. Only way I could think of would be scanning the namespace and lookup stored data for every id…
This is the correct answer.
…but seems highly inefficient
Not as inefficient as you would think. An application that wanted to implement a user discovery service can easily determine where everyone’s profile data is hosted, since a Blockstack Core node already does this. From there, an indexing service can be written to fetch each user’s profile, and for each profile, determine whether or not the use the application (by inspecting the profile).
The nice thing about this design pattern is that anyone can run an indexing service for any application, since all it’s doing is crawling users. The index is soft state, and can be reconstructed at any time. This means that if you don’t want to run an index yourself, you should have no problem finding one you can trust. Also, even if the application developer abandons your app, the fact that anyone can start up a user index for it means that apps will remain usable on as long as people want them to.