import type { AuthProfile } from "../auth/auth-profile.js"; import type { Backend } from "../backend.js"; import type { BuiltinProtocolCoverageRow } from "../protocol-coverage.js"; /** A workspace package whose source history must CONTAIN its canonical upstream's history. * Replaces the retired external-fork model (#282): the fork now lives in this repository as a * non-squashed subtree, so the dependency gate checks git ancestry against the monorepo HEAD — * `merge-base --is-ancestor HEAD` — instead of inspecting an external * clone. Sync is merge-based, never rebase/squash: a squash import cannot satisfy the check. */ export interface BuiltinBackendSourceUpstreamMetadata { readonly package: string; readonly path: string; readonly upstreamUrl: string; readonly upstreamUrlEnv: string; readonly upstreamRef: string; } export interface BuiltinBackendWrappedRuntimeMetadata { readonly adapterPackage: string; readonly runtimePackage: string; } export type BuiltinBackendServerMetadata = { readonly kind: "npm-package"; readonly package: string; } | { readonly kind: "workspace-package"; readonly package: string; readonly path: string; } | { readonly kind: "system-command"; readonly command: string; readonly optionalPackageProbe?: string; }; export interface BuiltinBackendReleaseMetadata { readonly engine: { readonly node: string; }; readonly server: BuiltinBackendServerMetadata; readonly freshness: { readonly npm: readonly string[]; readonly sourceUpstreams: readonly BuiltinBackendSourceUpstreamMetadata[]; readonly wrappedRuntimes: readonly BuiltinBackendWrappedRuntimeMetadata[]; }; } /** Whether thought-level select values form an ordered ladder or only an exact supported set. */ export type ThoughtLevelDomainSemantics = "ordered" | "exact-set"; export interface BuiltinBackendDefinition { readonly id: Id; readonly thoughtLevelDomainSemantics: ThoughtLevelDomainSemantics; readonly authProfile: AuthProfile; readonly create: () => Backend & { readonly id: Id; readonly authProfile: AuthProfile; }; readonly release: BuiltinBackendReleaseMetadata; readonly protocolCoverage: BuiltinProtocolCoverageRow; } export interface DefineBuiltinBackendOptions { readonly id: Id; readonly thoughtLevelDomainSemantics: ThoughtLevelDomainSemantics; readonly authProfile: AuthProfile; readonly create: (authProfile: AuthProfile) => Backend & { readonly id: Id; readonly authProfile: AuthProfile; }; readonly release: BuiltinBackendReleaseMetadata; readonly protocolCoverage: BuiltinProtocolCoverageRow; } /** Compose and validate a built-in while retaining ownership only of its release metadata tree. */ export declare function defineBuiltinBackend(options: DefineBuiltinBackendOptions): BuiltinBackendDefinition; //# sourceMappingURL=define.d.ts.map