Skip to content

Add built-in plugin pages to the public marketplace - #4938

Merged
SawyerHood merged 9 commits into
mainfrom
bb/builtin-marketplace-pages-thr_9m2uiwiv73
Oct 5, 2026
Merged

SawyerHood merged 9 commits into
mainfrom
bb/builtin-marketplace-pages-thr_9m2uiwiv73

Conversation

@SawyerHood

Copy link
Copy Markdown
Collaborator

Human comments

What was wrong

getbb.app/marketplace only listed community plugins. The plugins that ship with bb (Memory, Tasks, Docs, Automations, Plugin Guide and others) had no public page, so links like /marketplace/memory returned 404 and search engines could not find them.

This carries #4608 forward on current main with a smaller diff and three fixes.

What changed

Every user-facing built-in plugin now has a marketplace page, and a "BB Official" shelf leads /marketplace.

Pages and shelf

  • The "BB Official" shelf comes first, above New & notable. "View all" expands it in place.
  • Cards use the bb mark as the author avatar.
  • Badges follow the shared install rule:
    • Plugins installed with bb by default say "Built in" on cards and "Included with bb" on detail pages.
    • Opt-in official plugins (Tasks, GitHub, Docs, Memory and others) show their install counts.
  • Detail pages show the right setup step:
    • bb plugin install <name> for official plugins installed on request
    • bb plugin enable <id> for built-ins that are off by default
    • no command for built-ins that are always on
  • "View source" links to get-bb/bb/tree/main/plugins/<name>.
  • Internal and adapter plugins stay unlisted: account-pool, agent-annotations, the environment-* checkouts, plugin-api-tester and the provider-* adapters.
  • Built-ins join the sitemap and get share cards.

Ids and URLs

  • A built-in's page URL is its plugin id, the same id install counts and the app use.
  • Built-in ids cannot clash with community ids: Reserve bb-- plugin ids and move provider-usage to bb--provider-usage #4576 moved the one clash to bb--provider-usage, and the marketplace registry rejects reserved ids.
    • /marketplace/provider-usage is the community Provider Usage plugin (unchanged).
    • /marketplace/bb--provider-usage is the built-in.
  • If a clash ever appears, the community page stays and the built-in is left off the site.

Data and build

  • apps/web imports the bundled catalog that @bb/server#generate:bb-official-marketplace already generates and merges it into the community manifest after parsing.
  • Only the bundled catalog may use a { bundled: { plugin } } source. A fetched community manifest with one is rejected, so a community entry cannot present itself as built in.
  • Local SVG icons are served as Vite asset URLs, including when Vite inlines them as data: URLs.
  • @bb/web#build depends on the catalog generator through topo. deploy-web.yml also triggers on every generator input and on plugin icons.

Differences from #4608

  • Removed the compact-slug rename (/marketplace/providerusage). It no longer ran, because the ids no longer clash.
  • bb account, bb cloud AI and bb connect rendered the generic puzzle icon; they now have icons.
  • The enable command uses the plugin id instead of the source name.
  • The bundled-source check runs after the shared parse instead of through a second copy of the manifest schema.
  • Formatting-only hunks are reverted.

Things to know

  • Adding a bundled plugin that is opt-in or off by default fails bundled-marketplace.test.ts until it is added to the lists in bundled-marketplace.ts. The failure names the plugin.
  • A listed built-in whose icon name has no entry in marketplace-icons.ts fails the same test file.
  • The deploy job uses a shallow clone, so built-ins have no publish dates on getbb.app. They sort last under "New" and never show the "New" badge.
  • Provider usage and Modal Sandbox have no overview text yet, so their Overview section is empty.

How you verified

  • pnpm exec turbo run build typecheck test lint --filter=@bb/web passes on this branch (25 files, 170 tests).
  • bundled-marketplace.test.ts covers the clash rule, the unlisted filter, shelf order, category merging, icon fallback, a drift check against the server's plugin registry, and a check that every listed built-in has a web icon. Removing two icon entries made that last test fail and name both plugins.
  • marketplace-v2.test.ts: the community catalog rejects bundled sources; the bundled catalog accepts them.
  • public-marketplace.test.tsx: only default-installed bundled plugins render "Built in"; an opt-in one renders its count.
  • Browser checks in headless Chrome at 1280×900, against a local build with a local R2 bucket holding a full 327-plugin community catalog and the live install counts. These ran on a local branch that also carried Follow the marketplace category order in the app #4671; its apps/web differs from this PR by one shelf subtitle string.
    • /marketplace: BB Official shelf first with 30 plugins; "View all" expands to all 30 and the link disappears.
    • bb account, bb cloud AI and bb connect show their own icons.
    • /marketplace/bb--provider-usage shows the built-in with "Included with bb" and no command; /marketplace/provider-usage still shows the community plugin with its install command; /marketplace/providerusage is 404.
    • /marketplace/simple-notes shows bb plugin install docs; /marketplace/workflows shows bb plugin enable workflows; /marketplace/bb-guide shows no command.
  • Production build under vite preview: Plugin Guide and Modal Sandbox render their SVG icons on the page and on the share card (/marketplace/og/<id>); the sitemap lists the built-in pages; no console errors.

🤖 Generated with Claude Code

AGENT GENERATED

brsbl and others added 9 commits September 25, 2026 19:28
…ketplace-pages

# Conflicts:
#	apps/web/src/marketplace/marketplace-v2.test.ts
#	apps/web/src/marketplace/marketplace-v2.ts
Resolves the conflicts with #4786 (icons moved to marketplace-icons.ts)
and #4791 (shared install badge). Only plugins installed by default now
show "Built in"; opt-in official plugins like Tasks show their install
counts, matching the in-app plugin store.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
marketplaceAssetUrl now keeps root-relative paths for bundled icons, so
the server-rendered share card resolves them against getbb.app before
fetching.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
…handling

Built-in ids no longer clash with community ids since #4576 moved
provider-usage to bb--provider-usage and the marketplace rejects reserved
ids, so the compact-slug rename is gone; a clash keeps the community page
and leaves the built-in off. bb account, bb cloud AI, and bb connect had
no web icon, and a drift test now names any listed plugin without one.
The bundled-source check runs after the shared parse instead of through a
second copy of the manifest schema, the enable command uses the plugin id,
the deploy triggers cover every catalog generator input, and
formatting-only hunks are reverted.

Co-Authored-By: Claude Code <[email protected]>
@SawyerHood
SawyerHood marked this pull request as ready for review October 5, 2026 20:51
@SawyerHood
SawyerHood merged commit 53e0675 into main Oct 5, 2026
33 of 34 checks passed
@SawyerHood
SawyerHood deleted the bb/builtin-marketplace-pages-thr_9m2uiwiv73 branch October 5, 2026 20:54
ymichael added a commit that referenced this pull request Oct 5, 2026
…rketplace

The public marketplace test added in #4938 requires every disabled-by-default
builtin plugin to appear in OFF_BY_DEFAULT_BUNDLED_PLUGINS so its page shows
`bb plugin enable` instead of "included".

Co-Authored-By: Claude Opus 5.5 <[email protected]>
brsbl added a commit that referenced this pull request Oct 5, 2026
## Human comments

## What was wrong

The public Plugin Guide linked every "Used by" plugin to GitHub, even
though #4938 gave built-ins marketplace pages. A built-in's marketplace
id can differ from its folder name. Whether it is listed depends on the
live catalog, so the Guide can't hard-code `/marketplace/<id>`.

## What changed

- "Used by" names now open the plugin's marketplace page.
- Built-ins the marketplace doesn't list still open their GitHub source.
- The new `/marketplace/builtin/<plugin>` route looks up the live
catalog and redirects.

Clicking Docs under "Used by" (left) lands on its marketplace page,
`/marketplace/simple-notes` (right):

| Guide card | Destination |
|---|---|
| ![Full-page panels card with Used by
links](https://github.com/user-attachments/assets/5091aa73-0484-41f8-8399-9683115e4977)
| ![Docs marketplace
page](https://github.com/user-attachments/assets/8d9b57e2-b98f-4a1a-ae6e-0067dede13c6)
|

## How you verified

- **Remote CI:** passed on `6878b86b40` (rebased onto #4948).
- **Every link (branch web app, local R2 seeded from the production
catalog):** all 38 distinct "Used by" plugins return a 307 and land on a
200 page.
- 29 land on a marketplace page; `docs` lands on
`/marketplace/simple-notes`.
  - 9 unlisted built-ins land on their GitHub source.
- **Rendered Guide (Chrome for Testing):** on every slide, all "Used by"
links point to `/marketplace/builtin/…`.
- **Click-throughs:** Memory landed on its marketplace page; Account
Pooler landed on its GitHub folder.
- **Unit test:** an unavailable marketplace falls back to GitHub.
- **Slop Cop review of `19ba9c3802`:** no P0 or P1 findings. The rebase
only resolved #4948's move of the link helper.

## Follow-ups (P2)

- Return the site's 404 for unknown plugin names instead of redirecting
to a GitHub 404.

BB-Thread: [Public Plugin Guide on
getbb.app](https://brsbl.getbb.app/projects/proj_khiw2za95v/threads/thr_ptdzpsxqum)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

> AGENT GENERATED

Co-authored-by: Claude Opus 5.5 <[email protected]>
ymichael added a commit that referenced this pull request Oct 5, 2026
## Human comments

## What was wrong

Reusable prompts had no bundled picker for searching history, previewing
a full prompt, and keeping favorites. B1–B3 provide the paged history
API, popup host, and composer command path; this slice supplies their
Prompt Library consumer.

## What changed

Adds the forkable Prompt Library plugin: **Ctrl+R** or **+ → Prompts…**,
fuzzy search with Thread/Project/All scopes, Markdown preview,
persistent starred text and mentions, and insertion at the retained
caret. Empty drafts restore history text, mentions, and attachment
objects; nonempty drafts receive text and mentions. Insertion never
sends a message.

**Disabled by default.** Enable Prompt Library in Settings → Plugins or
run `bb plugin enable bb--prompt-library` to review it. Includes `bb
prompts search|list|star|unstar`, typed plugin RPC, the plugin skill,
CLI guide/configuration documentation, and bundled marketplace wiring.
Uses B1's `experimental_promptHistory.list`, B2's `experimental_popups`
registrations, and B3's composer command API; no new SDK surface or
daemon wire change.

History attachment fields pass through the mapper and RPC, including
unknown extension fields. The attachment schema follows main's mutually
exclusive project/host ownership contract and accepts unknown sizes.
Starred prompts store text and mentions only. The standalone Vitest
configuration keeps forks independent of monorepo test tooling.

## How you verified

- Rebased onto `origin/main` at
`95750b88485a882bf9ea954c1655797002f60836`; preserved main's diagnostics
documentation when resolving the only conflict.
- Merged `main` at `1904796758` (picks up #4933's workspace bundle
budget, which fixed the `Checks` failure). Main's new public-marketplace
test from #4938 then required off-by-default builtins to be listed, so
`prompt-library` is added to `OFF_BY_DEFAULT_BUNDLED_PLUGINS` in
`apps/web`; the marketplace page now shows `bb plugin enable
bb--prompt-library`. `turbo run test typecheck lint --filter=@bb/web`
passes.
- `pnpm exec turbo run typecheck lint test
--filter=bb-plugin-bb--prompt-library --concurrency=4`: all 9 tasks
passed, including 25 tests. Restore cases cover file/image attachments
with project or host ownership and preservation of unknown extension
fields.
- `env -u BB_CLI -u BB_SERVER_URL -u BB_ACCOUNT_POOL_PARENT_URL pnpm
exec turbo run test --filter=@bb/server --
test/services/plugins/builtin-plugins.test.ts`: all 28 tests passed.
- `node scripts/check-plugin-forks.mjs plugins/prompt-library
--concurrency=1`: independent install, typecheck, tests, and plugin
build passed.
- Earlier UI verification passed in desktop Chromium, 390px
coarse-pointer Chromium, and iPhone 16 / iOS 18.4 Simulator Safari:
preview, Back, insertion without sending, and starring. Rebase changes
are limited to documentation resolution and attachment compatibility.
- SDK generation dependencies remain explicit in Turbo, preserving the
clean-CI fix.
- Product path on the merged head (`pnpm start:worktree`, headless
Chromium → server → daemon → real providers): Ctrl+R in follow-up and
new-thread composers; Thread/Project/All and Project/All scopes with
per-composer persistence across reload; fuzzy search; Cmd+S star/unstar
and Star current draft; insertion at the caret without sending;
empty-composer restore of an image; starred insert dropping attachments.
Attachment ownership from #4685 was sent through real providers: a
project A image restored into a project B new thread was copied
byte-identically and described correctly, and an API-seeded
absolute-path file restored with its `hostId` was read by the provider.
Unknown sizes stay `0`, which the SDK documents as unknown; the file
chip shows no size. Not re-run on this head: compact drawer / iOS
Simulator (earlier pass above), host-mismatch rejection (single
machine).
- Mention round-trip on the same server: workspace-file, cross-project
thread and Agent Annotations plugin mentions keep identical resources
(plugin `itemId` included) through empty, at-caret and starred recall.
Re-sent prompts store the same resources at shifted offsets, and real
providers resolved each target.
- Known core race, not changed here: if Ctrl+R arrives within ~16 ms of
an arrow-key caret move, ProseMirror has not yet synced the selection,
so the prompt is inserted at the previous caret. It was reproduced only
at automation speed and nothing is sent. The fix belongs in core's
composer popup/selection handling.

Reviewer checklist (run CLI commands against the worktree instance):

1. Confirm Prompt Library is initially disabled, then enable it through
Settings → Plugins or `bb plugin enable bb--prompt-library`.
2. Run `bb prompts star 'Review the release notes before merging'
--json`, then `bb prompts search 'rls nts' --json`. Expect one
fuzzy-matched starred prompt with highlighted characters.
3. Open a new-thread composer, press Ctrl+R, and search `rls nts`.
Expect a starred result and full preview. Select Insert: the picker
closes and the draft fills without sending.
4. With an existing draft, reopen the picker and insert a result. Expect
text and mentions at the retained caret, preserving existing content.
Arrow keys move selection, Tab changes scope, and Cmd/Ctrl+S toggles
starring.
5. At a compact touch width or in Simulator Safari, choose **+ →
Prompts…**. Expect the shared bottom drawer. Tap a row to preview it,
use Back to return, then Insert to populate the draft and close. The app
root retains neither `inert` nor `aria-hidden` in the Chromium check.

> AGENT GENERATED

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>
brsbl added a commit that referenced this pull request Oct 9, 2026
## Human comments

## What was wrong

Agent Annotations had no public marketplace page:
getbb.app/marketplace/agent-annotations returned 404. #4938 put it in
the unlisted set with internal and adapter plugins. But it's a
user-facing plugin that ships turned off, so people need a page that
explains it and how to switch it on.

## What changed

- Agent Annotations is listed in the public marketplace, labeled
"Included with bb", with `bb plugin enable agent-annotations`.
- It moves from the unlisted set to the off-by-default set, and its
`MessageSquarePlus` icon is mapped for the web.
- The plugin gets a `PLUGIN_OVERVIEW.md`, so its page explains what it
does and how to turn it on.

## How you verified

- Branch web app with the public catalog seeded into local R2:
`/marketplace/agent-annotations` returns 200 and renders the page. On
main it shows "Page not found".
- Remote CI: pending. `bundled-marketplace.test.ts` checks the
off-by-default set against the server registry and that every listed
built-in has a web icon.

Before: `ff94848832` (main) · After: `9619b9ab75` · Captured at 2×

| Screen / state | Viewport | Before | After |
| --- | --- | --- | --- |
| /marketplace/agent-annotations | Desktop · 1440×900 | ![Before: Page
not
found](https://github.com/user-attachments/assets/984de6f5-3b3e-45de-a6e4-a9f52b01cbfa)
| ![After: Agent Annotations page with
overview](https://github.com/user-attachments/assets/e47fbd4f-5140-4251-a398-2961cc640044)
|
| /marketplace/agent-annotations | Mobile · 390×844 | ![Before: Page not
found on
mobile](https://github.com/user-attachments/assets/b476ff36-88a2-400b-b70a-a23bc8b5d3f5)
| ![After: Agent Annotations page on
mobile](https://github.com/user-attachments/assets/756bd8f8-f985-455e-b57d-7aeef532009c)
|

BB-Thread: [🔥🔥 𝒃𝒃 ad landing pages and
guides](https://brsbl.getbb.app/projects/proj_khiw2za95v/threads/thr_46gxq5dyzh)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

> AGENT GENERATED

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>
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.

2 participants