For developers
Switchbar API
Switchbar has a URL-based API. Open a specially formatted URL and Switchbar springs into action — sending a link to the right browser or email client, or prompting you to pick one.
How it works
switchbar://open/<link>Web and email links
Pass any
https://,http://, ormailto:link.Your rules apply
The link goes through your rules and link settings, just like a click. If no rule matches, Switchbar asks where to open it.
No encoding needed
Add the link as-is after
switchbar://open/, without percent-encoding it.
Examples
Terminal
# macOS
open "switchbar://open/https://example.com"
open "switchbar://open/mailto:hello@example.com"
# Windows
start "" "switchbar://open/https://example.com"AppleScript
open location "switchbar://open/https://example.com"JavaScript
window.location.href = "switchbar://open/https://example.com";Swift
let url = URL(string: "switchbar://open/https://example.com")!
NSWorkspace.shared.open(url)Works with Choosy URLs
Switchbar also opens Choosy API links, so scripts and tools built for Choosy work without changes.
x-choosy://open/
x-choosy://prompt.all/
x-choosy://prompt.running/
x-choosy://best.all/
x-choosy://best.running/