import { r as EmbeddingProviderAdapter } from "./embedding-providers-BcW8hm2d.js";
import { r as PluginDiagnostic } from "./manifest-types-C_IWdo1j.js";
import { E as OpenClawPluginHookOptions, O as OpenClawPluginToolFactory, U as WebSearchProviderPlugin } from "./types-core-BYYcMpho.js";
import { r as AnyAgentTool } from "./common-BDN0bXby.js";
import { E as OpenClawPluginCliCommandDescriptor, Gn as RealtimeTranscriptionProviderPlugin, Kn as RealtimeVoiceProviderPlugin, N as OpenClawPluginGatewayRuntimeScopeSurface, O as OpenClawPluginCliRegistrar, P as OpenClawPluginHostedMediaResolver, Q as OpenClawPluginSecurityAuditCollector, T as OpenClawPluginChannelRegistration, U as OpenClawPluginNodeHostCommand, X as OpenClawPluginReloadRegistration, Xn as VideoGenerationProviderPlugin, Yn as UnifiedModelCatalogProviderPlugin, a as ImageGenerationProviderPlugin, bt as PluginRegistrationMode, et as OpenClawPluginService, g as MigrationProviderPlugin, k as OpenClawPluginCommandDefinition, li as AgentHarness, ln as ProviderPlugin, o as MediaUnderstandingProviderPlugin, qn as SpeechProviderPlugin, s as MeetingNotesSourceProviderPlugin, vr as CliBackendPlugin, w as OpenClawPluginApi, y as MusicGenerationProviderPlugin } from "./types-DRSJeM-F2.js";
import { et as PluginHookName, q as PluginHookHandlerMap } from "./hook-types-BQsqneFB.js";
import { Go as PluginSessionSchedulerJobRegistration, Io as PluginRuntimeLifecycleRegistration, Mo as PluginAgentEventSubscriptionRegistration, No as PluginControlUiDescriptor, Ro as PluginSessionActionRegistration, Uo as PluginSessionExtensionRegistration, Xo as PluginTrustedToolPolicyRegistration, Yo as PluginToolMetadataRegistration, Zo as OperatorScope } from "./index-0t-CbL3i.js";
import { n as ChannelPlugin } from "./types.public-7jt5jasi.js";
import { n as GatewayRequestHandler } from "./types-DcLa7SB8.js";
import { a as PluginRegistryParams, i as PluginRegistry, n as PluginHttpRouteRegistration$1, o as PluginTextTransformsRegistration, r as PluginRecord } from "./registry-types-CXS4TnP2.js";
import { E as registerInternalHook } from "./internal-hooks-Dr-QncGz.js";

//#region src/plugins/registry-empty.d.ts
declare function createEmptyPluginRegistry(): PluginRegistry;
//#endregion
//#region src/plugins/registry.d.ts
type PluginHttpRouteRegistration = PluginHttpRouteRegistration$1 & {
  gatewayRuntimeScopeSurface?: OpenClawPluginGatewayRuntimeScopeSurface;
};
type PluginTypedHookPolicy = {
  allowPromptInjection?: boolean;
  allowConversationAccess?: boolean;
  timeoutMs?: number;
  timeouts?: Record<string, number>;
};
declare function createPluginRegistry(registryParams: PluginRegistryParams): {
  registry: PluginRegistry;
  createApi: (record: PluginRecord, params: {
    config: OpenClawPluginApi["config"];
    pluginConfig?: Record<string, unknown>;
    hookPolicy?: PluginTypedHookPolicy;
    registrationMode?: PluginRegistrationMode;
  }) => OpenClawPluginApi;
  rollbackPluginGlobalSideEffects: (pluginId: string) => void;
  pushDiagnostic: (diag: PluginDiagnostic) => void;
  registerTool: (record: PluginRecord, tool: AnyAgentTool | OpenClawPluginToolFactory, opts?: {
    name?: string;
    names?: string[];
    optional?: boolean;
  }) => void;
  registerChannel: (record: PluginRecord, registration: OpenClawPluginChannelRegistration | ChannelPlugin, mode?: PluginRegistrationMode) => void;
  registerHostedMediaResolver: (record: PluginRecord, resolver: OpenClawPluginHostedMediaResolver) => void;
  registerProvider: (record: PluginRecord, provider: ProviderPlugin) => void;
  registerModelCatalogProvider: (record: PluginRecord, provider: UnifiedModelCatalogProviderPlugin) => void;
  registerAgentHarness: (record: PluginRecord, harness: AgentHarness) => void;
  registerCliBackend: (record: PluginRecord, backend: CliBackendPlugin) => void;
  registerTextTransforms: (record: PluginRecord, transforms: PluginTextTransformsRegistration["transforms"]) => void;
  registerEmbeddingProvider: (record: PluginRecord, adapter: EmbeddingProviderAdapter) => void;
  registerSpeechProvider: (record: PluginRecord, provider: SpeechProviderPlugin) => void;
  registerRealtimeTranscriptionProvider: (record: PluginRecord, provider: RealtimeTranscriptionProviderPlugin) => void;
  registerRealtimeVoiceProvider: (record: PluginRecord, provider: RealtimeVoiceProviderPlugin) => void;
  registerMediaUnderstandingProvider: (record: PluginRecord, provider: MediaUnderstandingProviderPlugin) => void;
  registerMeetingNotesSourceProvider: (record: PluginRecord, provider: MeetingNotesSourceProviderPlugin) => void;
  registerImageGenerationProvider: (record: PluginRecord, provider: ImageGenerationProviderPlugin) => void;
  registerVideoGenerationProvider: (record: PluginRecord, provider: VideoGenerationProviderPlugin) => void;
  registerMusicGenerationProvider: (record: PluginRecord, provider: MusicGenerationProviderPlugin) => void;
  registerWebSearchProvider: (record: PluginRecord, provider: WebSearchProviderPlugin) => void;
  registerMigrationProvider: (record: PluginRecord, provider: MigrationProviderPlugin) => void;
  registerGatewayMethod: (record: PluginRecord, method: string, handler: GatewayRequestHandler, opts?: {
    scope?: OperatorScope;
  }) => void;
  registerCli: (record: PluginRecord, registrar: OpenClawPluginCliRegistrar, opts?: {
    parentPath?: string[];
    commands?: string[];
    descriptors?: OpenClawPluginCliCommandDescriptor[];
  }) => void;
  registerReload: (record: PluginRecord, registration: OpenClawPluginReloadRegistration) => void;
  registerNodeHostCommand: (record: PluginRecord, nodeCommand: OpenClawPluginNodeHostCommand) => void;
  registerSecurityAuditCollector: (record: PluginRecord, collector: OpenClawPluginSecurityAuditCollector) => void;
  registerService: (record: PluginRecord, service: OpenClawPluginService) => void;
  registerCommand: (record: PluginRecord, command: OpenClawPluginCommandDefinition) => void;
  registerSessionExtension: (record: PluginRecord, extension: PluginSessionExtensionRegistration) => void;
  registerTrustedToolPolicy: (record: PluginRecord, policy: PluginTrustedToolPolicyRegistration) => void;
  registerToolMetadata: (record: PluginRecord, metadata: PluginToolMetadataRegistration) => void;
  registerControlUiDescriptor: (record: PluginRecord, descriptor: PluginControlUiDescriptor) => void;
  registerRuntimeLifecycle: (record: PluginRecord, lifecycle: PluginRuntimeLifecycleRegistration) => void;
  registerAgentEventSubscription: (record: PluginRecord, subscription: PluginAgentEventSubscriptionRegistration) => void;
  registerSessionSchedulerJob: (record: PluginRecord, job: PluginSessionSchedulerJobRegistration) => {
    id: string;
    pluginId: string;
    sessionKey: string;
    kind: string;
  } | undefined;
  registerSessionAction: (record: PluginRecord, action: PluginSessionActionRegistration) => void;
  registerHook: (record: PluginRecord, events: string | string[], handler: Parameters<typeof registerInternalHook>[1], opts: OpenClawPluginHookOptions | undefined, config: OpenClawPluginApi["config"], pluginConfig: unknown) => void;
  registerTypedHook: <K extends PluginHookName>(record: PluginRecord, hookName: K, handler: PluginHookHandlerMap[K], opts?: {
    priority?: number;
    timeoutMs?: number;
  }, policy?: PluginTypedHookPolicy) => void;
};
//#endregion
export { createPluginRegistry as n, createEmptyPluginRegistry as r, PluginHttpRouteRegistration as t };