@get-bb/plugin-sdk 0.4.35 → 0.4.45
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +26 -1
- package/bundled-types/bb-plugin-sdk-app.d.ts +31 -2
- package/bundled-types/bb-plugin-sdk-internal-host-policy.d.ts +19 -2
- package/bundled-types/bb-plugin-sdk-internal-plugin-app-collector.d.ts +2 -1
- package/bundled-types/bb-plugin-sdk-provider-bridge-acp.d.ts +9 -0
- package/bundled-types/bb-plugin-sdk-provider-bridge-testing.d.ts +590 -0
- package/bundled-types/bb-plugin-sdk-provider-bridge.d.ts +135 -0
- package/bundled-types/bb-plugin-sdk-testing-app.d.ts +3 -2
- package/bundled-types/bb-plugin-sdk-testing.d.ts +45 -3
- package/bundled-types/bb-plugin-sdk.d.ts +900 -93
- package/dist/internal/host-policy.js +64 -1
- package/dist/internal/plugin-app-collector.js +11 -0
- package/dist/provider-bridge-acp.js +169 -28
- package/dist/provider-bridge-testing.js +34 -2
- package/dist/provider-bridge.js +34 -2
- package/dist/testing/app.js +11 -0
- package/dist/testing/index.js +304 -4
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -65,6 +65,16 @@ action id, or a surface with no side panel). A decline is a return value, never
|
|
|
65
65
|
a thrown error, so a plugin registering several kinds of action can share one
|
|
66
66
|
open routine and branch on the result.
|
|
67
67
|
|
|
68
|
+
Use `app.slots.experimental_appOverlay({ id, component })` for additive,
|
|
69
|
+
app-wide floating React UI. BB mounts the component once per app window through
|
|
70
|
+
the normal plugin slot boundary, so SDK hooks and plugin CSS work and React
|
|
71
|
+
context survives portals. This app-level boundary includes the sidebar thread
|
|
72
|
+
data and action hooks. Hooks whose contract requires a particular surface,
|
|
73
|
+
including `useComposer` and `useComposerView`, remain limited to that surface.
|
|
74
|
+
The plugin owns the overlay's chrome, positioning, visibility, focus, and
|
|
75
|
+
responsive behavior; a crashing overlay is hidden without affecting siblings.
|
|
76
|
+
Use a content script for app-wide DOM behavior that does not need React context.
|
|
77
|
+
|
|
68
78
|
See the
|
|
69
79
|
[`composer-customization` reference plugin](../../examples/plugins/composer-customization/README.md)
|
|
70
80
|
for every region in one small app. The deprecated pre-1.0
|
|
@@ -107,17 +117,32 @@ npm install --save-dev react react-dom @testing-library/react jsdom # frontend t
|
|
|
107
117
|
Backend example:
|
|
108
118
|
|
|
109
119
|
```ts
|
|
110
|
-
import {
|
|
120
|
+
import {
|
|
121
|
+
createFakePluginHost,
|
|
122
|
+
makePluginAgentConfigurationContext,
|
|
123
|
+
} from "@get-bb/plugin-sdk/testing";
|
|
111
124
|
import plugin from "./server.js";
|
|
112
125
|
|
|
113
126
|
const host = createFakePluginHost({ pluginId: "notes" });
|
|
114
127
|
await plugin(host.bb);
|
|
115
128
|
|
|
129
|
+
await host.harness.behavior.resolveAgentConfiguration(
|
|
130
|
+
makePluginAgentConfigurationContext({
|
|
131
|
+
provider: { id: "codex" },
|
|
132
|
+
}),
|
|
133
|
+
);
|
|
116
134
|
await host.harness.behavior.callRpc("list", { query: "today" });
|
|
117
135
|
expect(host.harness.inspection.registrations.rpcMethods).toContain("list");
|
|
118
136
|
await host.harness.lifecycle.dispose();
|
|
119
137
|
```
|
|
120
138
|
|
|
139
|
+
`makePluginAgentConfigurationContext`, `makeMessageDispatchHookContext`,
|
|
140
|
+
`makeThreadResponse`, `makeQueueEntry`, and `makeTurnFailedEvent` return
|
|
141
|
+
complete deterministic SDK objects. Pass partial overrides so a behavioral
|
|
142
|
+
test shows only the values relevant to its scenario. Nested context
|
|
143
|
+
members merge partial overrides against complete defaults, so required contract
|
|
144
|
+
additions remain localized to the shared fixtures.
|
|
145
|
+
|
|
121
146
|
`harness.behavior` contains deterministic host inputs (RPC/HTTP/CLI calls,
|
|
122
147
|
events, settings, tools, interactions, and schedules), `harness.inspection`
|
|
123
148
|
contains registrations and recorded state, and `harness.lifecycle` owns atomic
|
|
@@ -341,6 +341,14 @@ interface PluginHomepageSectionProps {
|
|
|
341
341
|
*/
|
|
342
342
|
interface PluginSettingsSectionProps {
|
|
343
343
|
}
|
|
344
|
+
/**
|
|
345
|
+
* Props passed to an `experimental_appOverlay` component.
|
|
346
|
+
*
|
|
347
|
+
* Deliberately empty while the component reads live app state through SDK
|
|
348
|
+
* hooks; versioned additive like the other slot props.
|
|
349
|
+
*/
|
|
350
|
+
interface ExperimentalAppOverlayProps {
|
|
351
|
+
}
|
|
344
352
|
/** Props passed to a `navPanel` component (it owns its whole route). */
|
|
345
353
|
interface PluginNavPanelProps {
|
|
346
354
|
/**
|
|
@@ -705,6 +713,21 @@ interface PluginSettingsSectionRegistration {
|
|
|
705
713
|
description?: string;
|
|
706
714
|
component: ComponentType<PluginSettingsSectionProps>;
|
|
707
715
|
}
|
|
716
|
+
/**
|
|
717
|
+
* Render app-wide plugin UI outside BB's layout regions.
|
|
718
|
+
*
|
|
719
|
+
* The host mounts each registration once per app window through the ordinary
|
|
720
|
+
* plugin React boundary. The component therefore keeps PluginContext, router,
|
|
721
|
+
* query, realtime, and other app-level SDK contexts when it renders fixed UI
|
|
722
|
+
* or creates a React portal. BB supplies no chrome, positioning, visibility,
|
|
723
|
+
* or interaction policy; the plugin owns those details and responsive
|
|
724
|
+
* behavior. Registrations are additive and a crash hides only that overlay.
|
|
725
|
+
*/
|
|
726
|
+
interface ExperimentalAppOverlayRegistration {
|
|
727
|
+
/** Unique within the plugin; letters, digits, `-`, `_`. */
|
|
728
|
+
id: string;
|
|
729
|
+
component: ComponentType<ExperimentalAppOverlayProps>;
|
|
730
|
+
}
|
|
708
731
|
/**
|
|
709
732
|
* Owner-defined validator for a fixed tab's transient target. The host first
|
|
710
733
|
* verifies that the value is JSON-safe, then calls this validator before
|
|
@@ -1522,6 +1545,12 @@ interface PluginTimelineRendererRegistration {
|
|
|
1522
1545
|
interface PluginAppSlots {
|
|
1523
1546
|
homepageSection(registration: PluginHomepageSectionRegistration): void;
|
|
1524
1547
|
settingsSection(registration: PluginSettingsSectionRegistration): void;
|
|
1548
|
+
/**
|
|
1549
|
+
* Render one app-wide overlay component (see
|
|
1550
|
+
* {@link ExperimentalAppOverlayRegistration}). Experimental: see
|
|
1551
|
+
* docs/api_to_audit.md.
|
|
1552
|
+
*/
|
|
1553
|
+
experimental_appOverlay(registration: ExperimentalAppOverlayRegistration): void;
|
|
1525
1554
|
navPanel(registration: PluginNavPanelRegistration): void;
|
|
1526
1555
|
/**
|
|
1527
1556
|
* Add an action to an existing thread's panel launcher. This slot is
|
|
@@ -1661,7 +1690,7 @@ interface PluginSettingsState {
|
|
|
1661
1690
|
* Effective non-secret setting values (secret settings are excluded —
|
|
1662
1691
|
* read them server-side). Undefined while loading or unavailable.
|
|
1663
1692
|
*/
|
|
1664
|
-
values: Record<string, string | boolean> | undefined;
|
|
1693
|
+
values: Record<string, string | number | boolean> | undefined;
|
|
1665
1694
|
isLoading: boolean;
|
|
1666
1695
|
}
|
|
1667
1696
|
/** State of the app's shared realtime connection to the bb server. */
|
|
@@ -2441,4 +2470,4 @@ declare const experimental_useProviders: () => PluginProvidersState;
|
|
|
2441
2470
|
declare const experimental_useCodeTheme: () => PluginCodeThemeState;
|
|
2442
2471
|
|
|
2443
2472
|
export { Markdown, ThreadChat, UrlLink, definePluginApp, experimental_Diff, experimental_FileLink, experimental_NewThreadComposer, experimental_PermissionModePicker, experimental_ProviderModelPicker, experimental_SourceCode, experimental_useAppPanel, experimental_useCodeTheme, experimental_useFixedTabTarget, experimental_useProviders, experimental_useSidebarThreadActions, experimental_useSidebarThreadPullRequest, experimental_useSidebarThreadSplit, experimental_useSidebarThreads, useBbContext, useBbNavigate, useComposer, useComposerView, useRealtime, useRealtimeConnectionState, useRpc, useSettings };
|
|
2444
|
-
export type { BbContext, BbNavigate, CodeOverflowMode, ComposerCustomization, ComposerPlusMenuItem, ComposerRichTextSpec, ComposerStructuredDraft, ComposerView, DiffProps, DiffViewMode, ExperimentalAppPanel, ExperimentalAppPanelSurface, ExperimentalComposerSubmitOptions, ExperimentalDiffFileContent, ExperimentalDiffFullFileContents, ExperimentalFileLinkProps, ExperimentalFileLocation, ExperimentalFileOpenOptions, ExperimentalFixedTabTargetContract, ExperimentalFixedTabTargetState, ExperimentalLiveFileTarget, ExperimentalOpenFixedTabOptions, ExperimentalPermissionModePickerProps, ExperimentalPluginFixedTabReference, ExperimentalProviderModelPickerProps, ExperimentalProviderModelPickerRouting, ExperimentalProviderModelPickerValue, ExperimentalSidebarNavigationAction, ExperimentalSidebarNavigationActivationOptions, ExperimentalSidebarNavigationIcon, ExperimentalSidebarNavigationItem, ExperimentalSidebarNavigationProps, ExperimentalSidebarNavigationRegistration, ExperimentalSidebarNavigationShortcut, JsonValue, MarkdownProps, NewThreadComposerProps, NewThreadRequest, PluginAppBuilder, PluginAppComposer, PluginAppContentScripts, PluginAppDefinition, PluginAppSetup, PluginAppSlots, PluginCodeThemeData, PluginCodeThemeState, PluginCodeThemeTokenRule, PluginCommandPaletteActionContext, PluginCommandPaletteActionRegistration, PluginComposerApi, PluginComposerMention, PluginComposerScope, PluginComposerTextEffect, PluginComposerThreadRowStatus, PluginContentScriptContext, PluginContentScriptDisposer, PluginContentScriptRegistration, PluginDiffRendererProps, PluginDiffRendererRegistration, PluginFileOpenerProps, PluginFileOpenerRegistration, PluginFileOpenerSource, PluginFixedTabDeclaration, PluginFixedTabRegistration, PluginHomepageSectionProps, PluginHomepageSectionRegistration, PluginMessageActionContext, PluginMessageActionRegistration, PluginMessageDirectiveMessage, PluginMessageDirectiveOpenWorkspaceFile, PluginMessageDirectiveProps, PluginMessageDirectiveRegistration, PluginNavPanelProps, PluginNavPanelRegistration, PluginNewThreadPanelActionContext, PluginNewThreadPanelActionRegistration, PluginNewThreadPanelProps, PluginPanelActionOpenOptions, PluginPendingInteractionProps, PluginPendingInteractionRegistration, PluginPendingInteractionView, PluginProviderIconRegistration, PluginProvidersState, PluginRealtimeConnectionState, PluginRpcCallArgs, PluginRpcClient, PluginRpcContract, PluginRpcError, PluginRpcErrorCode, PluginRpcHandlers, PluginRpcIssuePathSegment, PluginRpcMethodContract, PluginRpcResult, PluginRpcValidationIssue, PluginSdkApp, PluginSettingsSectionProps, PluginSettingsSectionRegistration, PluginSettingsState, PluginSidebarFooterActionContext, PluginSidebarFooterActionProps, PluginSidebarFooterActionRegistration, PluginSidebarProject, PluginSidebarPullRequest, PluginSidebarSplitPane, PluginSidebarThread, PluginSidebarThreadActions, PluginSidebarThreadActivity, PluginSidebarThreadIndicator, PluginSidebarThreadPullRequestState, PluginSidebarThreadSplit, PluginSidebarThreadsState, PluginSidebarWorkspaceKind, PluginSourceCodeRendererProps, PluginSourceCodeRendererRegistration, PluginTargetedPanelActionOpenOptions, PluginThreadHeaderActionProps, PluginThreadHeaderActionRegistration, PluginThreadListProps, PluginThreadListRegistration, PluginThreadPanelActionContext, PluginThreadPanelActionRegistration, PluginThreadPanelProps, PluginTimelineRendererProps, PluginTimelineRendererRegistration, PluginTimelineRendererRow, PluginTimelineRowPresentation, PluginTimelineRowStatus, SourceCodeLineRange, SourceCodeProps, StandardSchemaV1, StandardSchemaV1InferInput, StandardSchemaV1InferOutput, StandardSchemaV1Issue, StandardSchemaV1Result, ThreadChatMessageAction, ThreadChatMessageReference, ThreadChatProps, UrlLinkProps };
|
|
2473
|
+
export type { BbContext, BbNavigate, CodeOverflowMode, ComposerCustomization, ComposerPlusMenuItem, ComposerRichTextSpec, ComposerStructuredDraft, ComposerView, DiffProps, DiffViewMode, ExperimentalAppOverlayProps, ExperimentalAppOverlayRegistration, ExperimentalAppPanel, ExperimentalAppPanelSurface, ExperimentalComposerSubmitOptions, ExperimentalDiffFileContent, ExperimentalDiffFullFileContents, ExperimentalFileLinkProps, ExperimentalFileLocation, ExperimentalFileOpenOptions, ExperimentalFixedTabTargetContract, ExperimentalFixedTabTargetState, ExperimentalLiveFileTarget, ExperimentalOpenFixedTabOptions, ExperimentalPermissionModePickerProps, ExperimentalPluginFixedTabReference, ExperimentalProviderModelPickerProps, ExperimentalProviderModelPickerRouting, ExperimentalProviderModelPickerValue, ExperimentalSidebarNavigationAction, ExperimentalSidebarNavigationActivationOptions, ExperimentalSidebarNavigationIcon, ExperimentalSidebarNavigationItem, ExperimentalSidebarNavigationProps, ExperimentalSidebarNavigationRegistration, ExperimentalSidebarNavigationShortcut, JsonValue, MarkdownProps, NewThreadComposerProps, NewThreadRequest, PluginAppBuilder, PluginAppComposer, PluginAppContentScripts, PluginAppDefinition, PluginAppSetup, PluginAppSlots, PluginCodeThemeData, PluginCodeThemeState, PluginCodeThemeTokenRule, PluginCommandPaletteActionContext, PluginCommandPaletteActionRegistration, PluginComposerApi, PluginComposerMention, PluginComposerScope, PluginComposerTextEffect, PluginComposerThreadRowStatus, PluginContentScriptContext, PluginContentScriptDisposer, PluginContentScriptRegistration, PluginDiffRendererProps, PluginDiffRendererRegistration, PluginFileOpenerProps, PluginFileOpenerRegistration, PluginFileOpenerSource, PluginFixedTabDeclaration, PluginFixedTabRegistration, PluginHomepageSectionProps, PluginHomepageSectionRegistration, PluginMessageActionContext, PluginMessageActionRegistration, PluginMessageDirectiveMessage, PluginMessageDirectiveOpenWorkspaceFile, PluginMessageDirectiveProps, PluginMessageDirectiveRegistration, PluginNavPanelProps, PluginNavPanelRegistration, PluginNewThreadPanelActionContext, PluginNewThreadPanelActionRegistration, PluginNewThreadPanelProps, PluginPanelActionOpenOptions, PluginPendingInteractionProps, PluginPendingInteractionRegistration, PluginPendingInteractionView, PluginProviderIconRegistration, PluginProvidersState, PluginRealtimeConnectionState, PluginRpcCallArgs, PluginRpcClient, PluginRpcContract, PluginRpcError, PluginRpcErrorCode, PluginRpcHandlers, PluginRpcIssuePathSegment, PluginRpcMethodContract, PluginRpcResult, PluginRpcValidationIssue, PluginSdkApp, PluginSettingsSectionProps, PluginSettingsSectionRegistration, PluginSettingsState, PluginSidebarFooterActionContext, PluginSidebarFooterActionProps, PluginSidebarFooterActionRegistration, PluginSidebarProject, PluginSidebarPullRequest, PluginSidebarSplitPane, PluginSidebarThread, PluginSidebarThreadActions, PluginSidebarThreadActivity, PluginSidebarThreadIndicator, PluginSidebarThreadPullRequestState, PluginSidebarThreadSplit, PluginSidebarThreadsState, PluginSidebarWorkspaceKind, PluginSourceCodeRendererProps, PluginSourceCodeRendererRegistration, PluginTargetedPanelActionOpenOptions, PluginThreadHeaderActionProps, PluginThreadHeaderActionRegistration, PluginThreadListProps, PluginThreadListRegistration, PluginThreadPanelActionContext, PluginThreadPanelActionRegistration, PluginThreadPanelProps, PluginTimelineRendererProps, PluginTimelineRendererRegistration, PluginTimelineRendererRow, PluginTimelineRowPresentation, PluginTimelineRowStatus, SourceCodeLineRange, SourceCodeProps, StandardSchemaV1, StandardSchemaV1InferInput, StandardSchemaV1InferOutput, StandardSchemaV1Issue, StandardSchemaV1Result, ThreadChatMessageAction, ThreadChatMessageReference, ThreadChatProps, UrlLinkProps };
|
|
@@ -512,6 +512,12 @@ type PluginSettingDescriptor = {
|
|
|
512
512
|
/** Synchronously validate without transforming a proposed value. */
|
|
513
513
|
experimental_schema?: StandardSchemaV1<boolean, boolean>;
|
|
514
514
|
default?: boolean;
|
|
515
|
+
} | {
|
|
516
|
+
type: "number";
|
|
517
|
+
label: string;
|
|
518
|
+
description?: string;
|
|
519
|
+
experimental_schema?: StandardSchemaV1<number, number>;
|
|
520
|
+
default?: number;
|
|
515
521
|
} | {
|
|
516
522
|
type: "select";
|
|
517
523
|
label: string;
|
|
@@ -529,7 +535,7 @@ type PluginSettingDescriptor = {
|
|
|
529
535
|
default?: string;
|
|
530
536
|
};
|
|
531
537
|
type PluginSettingDescriptors = Record<string, PluginSettingDescriptor>;
|
|
532
|
-
type PluginSettingValue = string | boolean;
|
|
538
|
+
type PluginSettingValue = string | number | boolean;
|
|
533
539
|
/**
|
|
534
540
|
* What a `message.dispatch` hook answers.
|
|
535
541
|
*
|
|
@@ -1067,6 +1073,14 @@ interface PluginProviderDeclaration {
|
|
|
1067
1073
|
*/
|
|
1068
1074
|
deriveProviderOptions?: (context: PluginProviderOptionsContext) => Readonly<Record<string, JsonValue>>;
|
|
1069
1075
|
}
|
|
1076
|
+
interface ExperimentalPluginProviderEnvEntry {
|
|
1077
|
+
name: string;
|
|
1078
|
+
value: string | {
|
|
1079
|
+
serverPath: string;
|
|
1080
|
+
};
|
|
1081
|
+
reason: string;
|
|
1082
|
+
secret: boolean;
|
|
1083
|
+
}
|
|
1070
1084
|
type PluginMentionTrigger = "!" | "#" | "$" | "@" | "~";
|
|
1071
1085
|
/**
|
|
1072
1086
|
* What a plugin's AI service does. `inference` answers bb's server-side helper
|
|
@@ -1105,6 +1119,9 @@ declare const RPC_METHOD_PATTERN: RegExp;
|
|
|
1105
1119
|
declare const BACKGROUND_NAME_PATTERN: RegExp;
|
|
1106
1120
|
declare const CLI_COMMAND_NAME_PATTERN: RegExp;
|
|
1107
1121
|
declare const AGENT_TOOL_NAME_PATTERN: RegExp;
|
|
1122
|
+
declare const PLUGIN_PROVIDER_ENV_NAME_PATTERN: RegExp;
|
|
1123
|
+
declare const PLUGIN_PROVIDER_ENV_MAX_ENTRIES = 32;
|
|
1124
|
+
declare function validatePluginProviderEnvEntries(value: unknown): ExperimentalPluginProviderEnvEntry[];
|
|
1108
1125
|
declare const PLUGIN_AGENT_STATIC_INSTRUCTIONS_MAX_CHARS = 4096;
|
|
1109
1126
|
/** Status labels ride on every tool-call event and share one timeline row. */
|
|
1110
1127
|
declare const PLUGIN_AGENT_STATUS_LABEL_MAX_CHARS = 80;
|
|
@@ -1320,5 +1337,5 @@ declare function storePluginHook<K extends PluginHookName>(records: {
|
|
|
1320
1337
|
/** The refusal a second handler for one hook from one plugin gets. */
|
|
1321
1338
|
declare function pluginHookAlreadyRegisteredMessage(hook: PluginHookName): string;
|
|
1322
1339
|
|
|
1323
|
-
export { AGENT_TOOL_NAME_PATTERN, BACKGROUND_NAME_PATTERN, CLI_COMMAND_NAME_PATTERN, KV_VALUE_MAX_BYTES, MENTION_PROVIDER_ID_PATTERN, PLUGIN_AGENT_DYNAMIC_INSTRUCTIONS_MAX_CHARS, PLUGIN_AGENT_SELECTION_MAX_IDS, PLUGIN_AGENT_STATIC_INSTRUCTIONS_MAX_CHARS, PLUGIN_AGENT_STATUS_LABEL_MAX_CHARS, PLUGIN_AGENT_TOOL_PARAMETERS_MAX_BYTES, PLUGIN_HTTP_METHODS, PLUGIN_MENTION_TRIGGER_VALUES, PLUGIN_PROVIDER_BRIDGE_OPTIONS_MAX_BYTES, PLUGIN_PROVIDER_COMPOSER_ACTION_VALUES, PLUGIN_PROVIDER_DISPLAY_NAME_MAX_CHARS, PLUGIN_PROVIDER_PERMISSION_MODE_VALUES, PLUGIN_PROVIDER_REASONING_LEVEL_VALUES, PROVIDER_ID_PATTERN, RESERVED_AGENT_TOOL_NAMES, RESERVED_BB_CLI_COMMANDS, RPC_METHOD_PATTERN, SERVER_DIRECT_AI_SERVICE_IDS, SETTING_KEY_PATTERN, adoptHttpRouteResponse, agentToolIconRefusalMessage, aiServiceAlreadyRegisteredMessage, assertAiServiceRegistrable, assertNoRecursiveJsonSchemaReferences, deriveValidatedProviderOptions, enforcePluginCliOutputLimit, isPluginMentionTrigger, isStandardSchema, isZodSchemaLike, normalizeMentionProviderTriggers, parsePluginAgentToolPresentation, pluginCliCollisionWarning, pluginHookAlreadyRegisteredMessage, providerAlreadyRegisteredMessage, providerIconRefusalMessage, providerWithoutBridgeMessage, readRpcMethodContract, registerSettingDescriptors, rejectStaleAgentToolFields, storePluginHook, summarizeParseIssues, undeclaredIconProblem, validatePluginAiServiceDeclaration, validatePluginProviderDeclaration, validateSettingsUpdate, zodSchemaToJsonSchema };
|
|
1340
|
+
export { AGENT_TOOL_NAME_PATTERN, BACKGROUND_NAME_PATTERN, CLI_COMMAND_NAME_PATTERN, KV_VALUE_MAX_BYTES, MENTION_PROVIDER_ID_PATTERN, PLUGIN_AGENT_DYNAMIC_INSTRUCTIONS_MAX_CHARS, PLUGIN_AGENT_SELECTION_MAX_IDS, PLUGIN_AGENT_STATIC_INSTRUCTIONS_MAX_CHARS, PLUGIN_AGENT_STATUS_LABEL_MAX_CHARS, PLUGIN_AGENT_TOOL_PARAMETERS_MAX_BYTES, PLUGIN_HTTP_METHODS, PLUGIN_MENTION_TRIGGER_VALUES, PLUGIN_PROVIDER_BRIDGE_OPTIONS_MAX_BYTES, PLUGIN_PROVIDER_COMPOSER_ACTION_VALUES, PLUGIN_PROVIDER_DISPLAY_NAME_MAX_CHARS, PLUGIN_PROVIDER_ENV_MAX_ENTRIES, PLUGIN_PROVIDER_ENV_NAME_PATTERN, PLUGIN_PROVIDER_PERMISSION_MODE_VALUES, PLUGIN_PROVIDER_REASONING_LEVEL_VALUES, PROVIDER_ID_PATTERN, RESERVED_AGENT_TOOL_NAMES, RESERVED_BB_CLI_COMMANDS, RPC_METHOD_PATTERN, SERVER_DIRECT_AI_SERVICE_IDS, SETTING_KEY_PATTERN, adoptHttpRouteResponse, agentToolIconRefusalMessage, aiServiceAlreadyRegisteredMessage, assertAiServiceRegistrable, assertNoRecursiveJsonSchemaReferences, deriveValidatedProviderOptions, enforcePluginCliOutputLimit, isPluginMentionTrigger, isStandardSchema, isZodSchemaLike, normalizeMentionProviderTriggers, parsePluginAgentToolPresentation, pluginCliCollisionWarning, pluginHookAlreadyRegisteredMessage, providerAlreadyRegisteredMessage, providerIconRefusalMessage, providerWithoutBridgeMessage, readRpcMethodContract, registerSettingDescriptors, rejectStaleAgentToolFields, storePluginHook, summarizeParseIssues, undeclaredIconProblem, validatePluginAiServiceDeclaration, validatePluginProviderDeclaration, validatePluginProviderEnvEntries, validateSettingsUpdate, zodSchemaToJsonSchema };
|
|
1324
1341
|
export type { AiServiceHostBinding, NormalizedPluginProviderDeclaration };
|
|
@@ -5,12 +5,13 @@
|
|
|
5
5
|
// Confused by the API, or need a symbol that isn't here? Clone the BB repo
|
|
6
6
|
// and read the real source: https://github.com/get-bb/bb
|
|
7
7
|
|
|
8
|
-
import { PluginHomepageSectionRegistration, PluginSettingsSectionRegistration, PluginNavPanelRegistration, PluginThreadPanelActionRegistration, PluginNewThreadPanelActionRegistration, ComposerCustomization, PluginPendingInteractionRegistration, PluginSidebarFooterActionRegistration, ExperimentalSidebarNavigationRegistration, PluginThreadListRegistration, PluginThreadHeaderActionRegistration, PluginFileOpenerRegistration, PluginSourceCodeRendererRegistration, PluginDiffRendererRegistration, PluginMessageDirectiveRegistration, PluginMessageActionRegistration, PluginCommandPaletteActionRegistration, PluginProviderIconRegistration, PluginTimelineRendererRegistration, PluginContentScriptRegistration, PluginAppDefinition } from '@get-bb/plugin-sdk';
|
|
8
|
+
import { PluginHomepageSectionRegistration, PluginSettingsSectionRegistration, ExperimentalAppOverlayRegistration, PluginNavPanelRegistration, PluginThreadPanelActionRegistration, PluginNewThreadPanelActionRegistration, ComposerCustomization, PluginPendingInteractionRegistration, PluginSidebarFooterActionRegistration, ExperimentalSidebarNavigationRegistration, PluginThreadListRegistration, PluginThreadHeaderActionRegistration, PluginFileOpenerRegistration, PluginSourceCodeRendererRegistration, PluginDiffRendererRegistration, PluginMessageDirectiveRegistration, PluginMessageActionRegistration, PluginCommandPaletteActionRegistration, PluginProviderIconRegistration, PluginTimelineRendererRegistration, PluginContentScriptRegistration, PluginAppDefinition } from '@get-bb/plugin-sdk';
|
|
9
9
|
|
|
10
10
|
/** Validated registrations produced by one plugin app setup execution. */
|
|
11
11
|
interface CollectedPluginAppRegistrations {
|
|
12
12
|
homepageSections: PluginHomepageSectionRegistration[];
|
|
13
13
|
settingsSections: PluginSettingsSectionRegistration[];
|
|
14
|
+
appOverlays: ExperimentalAppOverlayRegistration[];
|
|
14
15
|
navPanels: PluginNavPanelRegistration[];
|
|
15
16
|
threadPanelActions: PluginThreadPanelActionRegistration[];
|
|
16
17
|
newThreadPanelActions: PluginNewThreadPanelActionRegistration[];
|
|
@@ -63,6 +63,15 @@ declare const availableModelSchema: z.ZodObject<{
|
|
|
63
63
|
type AvailableModel = z.infer<typeof availableModelSchema>;
|
|
64
64
|
|
|
65
65
|
declare const deltaPresentationSchema: z.ZodObject<{
|
|
66
|
+
badge: z.ZodOptional<z.ZodObject<{
|
|
67
|
+
glyph: z.ZodString;
|
|
68
|
+
hint: z.ZodString;
|
|
69
|
+
label: z.ZodString;
|
|
70
|
+
tone: z.ZodEnum<{
|
|
71
|
+
destructive: "destructive";
|
|
72
|
+
neutral: "neutral";
|
|
73
|
+
}>;
|
|
74
|
+
}, z.core.$strip>>;
|
|
66
75
|
detail: z.ZodOptional<z.ZodString>;
|
|
67
76
|
icon: z.ZodObject<{
|
|
68
77
|
glyph: z.ZodString;
|