ubd is Unbound’s command line tool, published on npm as @unbound-app/cli. It needs Bun.
--help for its flags and --json to print the raw result instead of the formatted transcript.
Commands that talk to the device
Commands that act on the running client, such aseval, push, reload and dev, go through the debugger bridge. Start it first with bunx @unbound-app/debugger and connect the device to it, as described in debugging. They use port 9090 unless you pass --port.
install, device and logs don’t need the bridge. They reach Discord directly: over adb on a rooted Android device or emulator, or through jb-p1lot on a jailbroken iPhone when you pass --ios or --udid. Use --serial to pick one of several Android devices.
Make an addon
1
Scaffold it
ubd create asks for anything you don’t pass as a flag.2
Build and hot reload it
Run these from the workspace.
build builds every addon once and reports which succeeded. dev watches every addon, rebuilds only the one whose files changed, and reloads it in the running client after each successful build.To send one plugin to the device without watching, use push. It builds the plugin, installs it if the device doesn’t have it yet, and hot reloads it. Pass --build=false to push the existing build.3
Install it for cold starts
install copies a built plugin into Discord’s plugin folder, so it loads on the next cold start. --restart restarts Discord right away.4
Publish it
Log in once by approving a code on the website, then submit the addon for review. Its build output must be committed and pushed.
publish takes --addon (required when the workspace has several addons), --ref (defaults to the tag on HEAD, otherwise its commit), and --repository (defaults to the origin remote). ubd logout deletes the stored credentials.Run code and reload
trace and hook record for --duration milliseconds (default 3000) and describe the first --samples calls (default 10).
Inspect native code
Logs and device state
ubd logs tails Discord’s log, filtered to Unbound, the JavaScript console and crashes. On Android it follows adb logcat for com.discord across restarts. On an iPhone it reads the unified log.
ubd device saves and restores Discord’s Unbound state, which is useful for testing from a known starting point:
AI clients
ubd mcp serves the bridge commands above, plus install and device, as tools of a stdio MCP server over one connection to the bridge, so an AI client can evaluate code, inspect views, and push plugins. build, dev, create, logs, login, logout and publish stay CLI only.
Two tools are also available from the command line under ubd mcp: ubd mcp route prints the focused navigation route with its params and navigator path, and ubd mcp open <screen> opens an Unbound or Discord settings screen from anywhere in the app.