import type { Operation } from "../../client/types.gen.js"; import type { CallOptions, RequestContext } from "../context.js"; import { type Paginated } from "../paginate.js"; import type { Outcome } from "../result.js"; import { type WaitForOptions } from "../wait.js"; /** * Options for {@link Operations.waitFor}. * * `requestTimeoutMs` and `waitForReadiness` are deliberately excluded. Readiness is * budgeted by `timeoutMs`, and waiting *is* the readiness step — accepting either would * offer a knob that silently did nothing. */ export type WaitForForOptions = WaitForOptions & Omit, "requestTimeoutMs" | "waitForReadiness" | "wait">; export type OperationsListParams = { projectId: string; }; export type OperationsGetParams = { projectId: string; operationId: string; }; export type OperationsWaitForParams = { operations: readonly Operation[]; }; /** Operation resource — read operations and wait for them to finish. */ export declare class Operations { #private; constructor(ctx: RequestContext); /** @apiCall GET /projects/{project_id}/operations (cursor-paginated) */ list(params: OperationsListParams): Paginated; list(params: OperationsListParams, opts: CallOptions): Paginated; /** @apiCall GET /projects/{project_id}/operations/{operation_id} */ get(params: OperationsGetParams): Promise>; get(params: OperationsGetParams, opts: CallOptions): Promise>; /** * Poll until every given operation reaches a terminal `finished`/`skipped` state. * The primitive behind `waitForReadiness`; use it directly with operations obtained * from any source (e.g. a raw call or a create response). */ waitFor(params: OperationsWaitForParams): Promise>; waitFor(params: OperationsWaitForParams, opts: WaitForForOptions): Promise>; } //# sourceMappingURL=operations.d.ts.map