/** * Generated `ComponentApi` utility. * * THIS CODE IS AUTOMATICALLY GENERATED. * * To regenerate, run `npx convex dev`. * @module */ import type { FunctionReference } from "convex/server"; /** * A utility for referencing a Convex component's exposed API. * * Useful when expecting a parameter like `components.myComponent`. * Usage: * ```ts * async function myFunction(ctx: QueryCtx, component: ComponentApi) { * return ctx.runQuery(component.someFile.someQuery, { ...args }); * } * ``` */ export type ComponentApi = { config: { update: FunctionReference<"mutation", "internal", { logLevel?: "DEBUG" | "TRACE" | "INFO" | "REPORT" | "WARN" | "ERROR"; maxParallelism?: number; }, any, Name>; }; lib: { cancel: FunctionReference<"mutation", "internal", { id: string; logLevel?: "DEBUG" | "TRACE" | "INFO" | "REPORT" | "WARN" | "ERROR"; }, any, Name>; cancelAll: FunctionReference<"mutation", "internal", { before?: number; limit?: number; logLevel?: "DEBUG" | "TRACE" | "INFO" | "REPORT" | "WARN" | "ERROR"; }, any, Name>; enqueue: FunctionReference<"mutation", "internal", { config: { logLevel?: "DEBUG" | "TRACE" | "INFO" | "REPORT" | "WARN" | "ERROR"; maxParallelism?: number; }; fnArgs: any; fnHandle: string; fnName: string; fnType: "action" | "mutation" | "query"; onComplete?: { context?: any; fnHandle: string; }; retryBehavior?: { base: number; initialBackoffMs: number; maxAttempts: number; }; runAt: number; }, string, Name>; enqueueBatch: FunctionReference<"mutation", "internal", { config: { logLevel?: "DEBUG" | "TRACE" | "INFO" | "REPORT" | "WARN" | "ERROR"; maxParallelism?: number; }; items: Array<{ fnArgs: any; fnHandle: string; fnName: string; fnType: "action" | "mutation" | "query"; onComplete?: { context?: any; fnHandle: string; }; retryBehavior?: { base: number; initialBackoffMs: number; maxAttempts: number; }; runAt: number; }>; }, Array, Name>; status: FunctionReference<"query", "internal", { id: string; }, { previousAttempts: number; state: "pending"; } | { previousAttempts: number; state: "running"; } | { state: "finished"; }, Name>; statusBatch: FunctionReference<"query", "internal", { ids: Array; }, Array<{ previousAttempts: number; state: "pending"; } | { previousAttempts: number; state: "running"; } | { state: "finished"; }>, Name>; }; }; //# sourceMappingURL=component.d.ts.map