import type * as MiddlewareAttachment from "@confect/core/MiddlewareAttachment"; import type * as FunctionSpec from "@confect/core/FunctionSpec"; import type { FunctionType, FunctionVisibility } from "convex/server"; import type * as Schema from "effect/Schema"; import type * as Handler from "./Handler"; export declare const TypeId = "~@confect/server/FunctionRegistryItem"; export type TypeId = typeof TypeId; export declare const isFunctionRegistryItem: (value: unknown) => value is AnyWithProps; /** * A function registered by `FunctionImpl.make`, one of two shapes keyed by the * spec's provenance. */ export type AnyWithProps = ConfectFunctionRegistryItem | ConvexFunctionRegistryItem; export interface ConfectFunctionRegistryItem { readonly [TypeId]: TypeId; readonly _tag: "Confect"; readonly name: string; readonly functionVisibility: FunctionVisibility; readonly functionType: FunctionType; readonly args: Schema.Codec; readonly returns: Schema.Codec; readonly error?: Schema.Codec; readonly middlewareAttachments: ReadonlyArray; readonly handler: Handler.AnyConfectProvenance; } export interface ConvexFunctionRegistryItem { readonly [TypeId]: TypeId; readonly _tag: "Convex"; readonly handler: Handler.AnyConvexProvenance; } export declare const make: ({ functionSpec, groupMiddlewareAttachments, handler, }: { functionSpec: FunctionSpec.AnyWithProps; groupMiddlewareAttachments: ReadonlyArray; handler: Handler.Any; }) => AnyWithProps; //# sourceMappingURL=FunctionRegistryItem.d.ts.map