Big Sur and Finder sidebar in Swift

I'm updating a utility which mounts a virtual drive; I want that drive link to be available in Finder's Favourites sidebar when it's open, the same way that the Dropbox folder's link displays.

Under OSX, I was able to use LSSharedFileListInsertItemURL, but this has long since been deprecated.

What's the current best-practice way to add something to that sidebar programmatically at runtime, using Swift? (If best practice is just not to do it -- how does Dropbox get away with it?)

I was able to use LSSharedFileListInsertItemURL, but this has long
since been deprecated.

Indeed. But does it still work?

What's the current best-practice way to add something to that sidebar
programmatically at runtime … ?

My understanding is that the shared file list mechanism (kLSSharedFileListFavoriteVolumes and kLSSharedFileListFavoriteItems) was deprecated without a replacement, meaning that this question has no answer )-:

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@apple.com"
Oh dear. Thanks for that.

But the thing is, Dropbox can clearly still add itself to Favourites without user intervention... Are they doing something naughty behind the scenes?

(klsSharedFileListFavoriteItems isn't working at the moment for me, but that may be because another part of my utility is broken!)
Big Sur and Finder sidebar in Swift
 
 
Q