JobStateData:
    | {
        imgID: string;
        jobID: string;
        jobIndex?: number;
        negativePrompt?: string;
        positivePrompt?: string;
        preparation?: JobPreparation;
        type: "initiatingModel"
        | "jobStarted";
        workerName: string;
    }
    | { jobID: string; type: "assigned"; workerName: string }
    | {
        estimatedStartSeconds?: number | null;
        jobID: string;
        queuePosition: number;
        queueStatus?: "waiting" | "no-workers";
        type: "queued";
    }
    | { jobID: string; type: "jobCompleted" }

Type declaration

  • {
        imgID: string;
        jobID: string;
        jobIndex?: number;
        negativePrompt?: string;
        positivePrompt?: string;
        preparation?: JobPreparation;
        type: "initiatingModel" | "jobStarted";
        workerName: string;
    }
  • { jobID: string; type: "assigned"; workerName: string }
  • {
        estimatedStartSeconds?: number | null;
        jobID: string;
        queuePosition: number;
        queueStatus?: "waiting" | "no-workers";
        type: "queued";
    }
    • OptionalestimatedStartSeconds?: number | null

      Server-provided estimate of seconds until a worker starts the project. null when no estimate is currently available.

    • jobID: string
    • queuePosition: number
    • OptionalqueueStatus?: "waiting" | "no-workers"

      Coarse state for the project's wait in the queue.

    • type: "queued"
  • { jobID: string; type: "jobCompleted" }