/** * Copyright (c) 2025 Elara AI Pty Ltd * Dual-licensed under AGPL-3.0 and commercial license. See LICENSE for details. */ import { type UseMutationResult, type UseQueryResult } from '@tanstack/react-query'; import type { QueryOverrides } from './types.js'; import type { RequestOptions, DataflowOptions, DataflowPollOptions, ExecutionStateOptions, LogOptions, DataflowResult, DataflowExecutionState } from '@elaraai/e3-api-client'; export declare function useDataflowExecute(url: string, repo: string, workspace: string | null, requestOptions?: RequestOptions): UseMutationResult; export declare function useDataflowStart(url: string, repo: string, workspace: string | null, requestOptions?: RequestOptions): UseMutationResult; export declare function useDataflowGraph(url: string, repo: string, workspace: string | null, requestOptions?: RequestOptions, queryOptions?: QueryOverrides): UseQueryResult<{ readonly tasks: { readonly name: string; readonly hash: string; readonly inputs: string[]; readonly output: string; readonly dependsOn: string[]; }[]; }, Error>; /** * Polls a workspace's latest run: its state, with the events past * `stateOptions.since`, at most `stateOptions.limit` of them, and the cursor * past them (`nextSeq`). Each poll makes one request attempt: its next poll * is its retry. * * @param url - The API's base URL * @param repo - Repository name * @param workspace - Workspace name; nothing is polled while it is `null` * @param stateOptions - The cursor to poll from, and the most events to serve: * `{ limit: 0 }` reads the run's state alone * @param requestOptions - The request's token * @param queryOptions - react-query overrides, such as a `refetchInterval` * @returns The query of the run's state */ export declare function useDataflowExecution(url: string, repo: string, workspace: string | null, stateOptions?: ExecutionStateOptions, requestOptions?: RequestOptions, queryOptions?: QueryOverrides): UseQueryResult; export declare function useDataflowCancel(url: string, repo: string, workspace: string | null, requestOptions?: RequestOptions): UseMutationResult; /** A chunk of a task's log, read once per poll: one request attempt each, * its next poll being its retry. */ export declare function useTaskLogs(url: string, repo: string, workspace: string | null, task: string | null, logOptions?: LogOptions, requestOptions?: RequestOptions, queryOptions?: QueryOverrides): UseQueryResult<{ readonly data: string; readonly offset: bigint; readonly size: bigint; readonly totalSize: bigint; readonly complete: boolean; readonly inputsHash: string; readonly executionId: string; readonly ended: boolean; }, Error>; //# sourceMappingURL=executions.d.ts.map