Repository navigation
Move first-party plugin API calls onto useSdk() - #4033
Merged
SawyerHood merged 1 commit intoSep 22, 2026
Merged
Conversation
SawyerHood
force-pushed
the
thread-list/6-first-party-use-sdk
branch
from
September 21, 2026 23:57
2504c64 to
08d9a48
Compare
plugin-api-docs read installed plugins and the catalog with hand-rolled fetches; side-chat proxied a queued-message create through its own RPC. Both now call the public client directly, and the RPC method plus its contract entry are deleted. The testing harness's sdk fakes learn nested sub-areas so threads.queuedMessages.create can be faked, and the guide's composer example spawns from the frontend. Co-Authored-By: Claude Fable 5.1 <[email protected]>
SawyerHood
force-pushed
the
thread-list/6-first-party-use-sdk
branch
from
September 22, 2026 00:08
08d9a48 to
21c33ed
Compare
SawyerHood
marked this pull request as ready for review
September 22, 2026 00:15
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Human comments
What was wrong
useSdk()should not ship with a single consumer. Two first-party frontends reached the public API by other means: plugin-api-docs hand-rolledfetch("/api/v1/plugins")and the catalog search with ad-hoc JSON parsing, and side-chat'ssendToMainRPC was a pure pass-through tobb.sdk.threads.queuedMessages.create.What changed
loadPluginReferences(sdk, signal)oversdk.plugins.list()andsdk.plugins.catalog.search({ query: "" }), with a Vitest setup and first tests for the plugin.sdk.threads.queuedMessages.createdirectly; thesendToMainRPC, its contract entry, and its server test are deleted.sdkfakes are now nested ({ threads: { queuedMessages: { create } } }) through a recursive proxy; unfaked methods still throw with the dot-path.theme-preview's RPCs were reviewed and left alone: they enrich the catalog and re-apply on disk changes, which is real server work.
Prerequisite: #4031.
How you verified
side-chat app and server suites, plugin-api-docs suite, plugin SDK harness suite (nested fake case added), bundled types build, guide parity suite.
🤖 Generated with Claude Code