So for a folder on macOS, you’re looking for “path”.
For this, you’d want to make a link with file:///
Example: [Downloads folder](file:////Users/yourusername/Downloads) but replace yourusername with your Mac user name.
Pro tip: this can be copied easily from Finder if you right-click the file, and hold down Option when hovering over Copy. This changes it to Copy 'File or folder name' as Path and then you add the file:/// when pasting.
For the other, that’s called a URL or URI scheme.
For something like DEVONthink, I just copy it directly from DT, and paste it into my Obsidian.
Example: [User Guide](x-devonthink-item://0EB90F63-C123-4CBB-9D35-DB8D9F1B89BE)
There are a number of macOS/iOS apps that support it, including OmniFocus, Fantastical, CardHop… you’ll want to search by app. Not all apps support this.
I’ve been starting a log of common ones I use here: URI or URL Schemes - Obsidian Publish