Skip to content

Add plugin entry: server-switcher - #386

Closed
rebryk wants to merge 2 commits into
get-bb:mainfrom
rebryk:submit-server-switcher
Closed

rebryk wants to merge 2 commits into
get-bb:mainfrom
rebryk:submit-server-switcher

Conversation

@rebryk

@rebryk rebryk commented Sep 26, 2026

Copy link
Copy Markdown
Contributor

What this plugin does

Server Switcher adds a Change Server button to the sidebar footer. In a browser, each click opens the next online server on the user's bb connect account at its home page, in the same tab. Servers follow alphabetical handle order, offline ones are skipped, and the last one wraps around to the first. A toast says when no other server is online, the session has expired, or the page isn't on a bb connect address.

In the BB mobile app a tap opens This device, where Servers lists the app's saved servers, because the mobile bridge has no message that switches servers for a page. BB Desktop changes servers only from its native Window → Server menu, so the plugin registers no button there.

Release source

  • Source: https://github.com/rebryk/bb-plugins.git, subdir: server-switcher
  • Range: ^0.1.0 with tagPrefix: server-switcher/
  • Release tag: server-switcher/v0.1.0
  • Release commit: 8136e8196f8b6ad945a8c90d51d15572a6682d2e

Plugin checks

  • npm test (23 tests: server order and wrap-around, handle validation, response parsing, the server list request and destination, error messages, browser/mobile/desktop detection, the mobile bridge, and a public SDK import scan)
  • npm run typecheck
  • npm run build (bb plugin build; the app bundle is 3.8 KB, with no runtime dependencies)
  • A fresh clone of the server-switcher/v0.1.0 tag builds after npm install --omit=dev --omit=optional, as a Git install does.
  • bb plugin types --check: the SDK pin (0.5.9) matches BB 0.43.4. The command still exits 1 because it asks for type-only devDependencies of UI shims that the plugin doesn't import (Radix primitives, vaul, clsx, and others). The plugin imports only @get-bb/plugin-sdk/app and sonner.
  • Secret scan of the plugin source found no credentials, private paths, or internal URLs.
  • Live BB 0.43.4 check: installed from Git on two servers. The button renders in the sidebar footer with its tooltip, and a click on a direct (non bb connect) address shows the "Open BB through bb connect" toast without requesting the server list.

Marketplace checks

  • npm ci --ignore-scripts
  • npm run build
  • npm test
  • npm run gate:v1 (one new entry)
  • npm run check

Permissions and services

Needs a bb connect account. The button switches servers when BB is open at https://<handle>.getbb.app, and each server needs the plugin installed for the button to be there after a switch.

A click makes one same-origin GET to /api/connect/servers with the page's existing session (credentials: "same-origin", redirect: "error", 8-second timeout). Destinations are built only from validated server handles (https://<handle>.getbb.app/), never from URLs in the response. The plugin copies, stores, and sends no tokens or credentials. It has no settings or storage, and its server entry registers nothing: no RPC methods, agent tools, skills, or CLI commands. In the mobile app it posts { type: "open-native", screen: "device-settings" } through window.bb.native. In BB Desktop it registers nothing.

Screenshots and overview

  • screenshots/server-switcher/footer.png: the sidebar footer of a live BB 0.43.4 with the Change Server button hovered and its tooltip. The other footer items belong to BB and another installed plugin. The thread list above the footer was hidden for the capture, so no thread titles appear.
  • overview/server-switcher.md was copied from the plugin repository's PLUGIN_OVERVIEW.md.

🤖 Generated with Claude Code

rebryk and others added 2 commits September 25, 2026 17:40
@rebryk rebryk closed this Sep 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant