# Jobs

## List

`client.jobs.list(JobListParamsquery?, RequestOptionsoptions?): JobsCursor<JobListResponse>`

**get** `/jobs`

List all jobs matching the given filters. A job is a synchronous operation or an asynchronous task such as a training, a generation, etc. It offers a unified view of all operations running on the platform along with their status and results. A page can hold fewer jobs than "pageSize", or none, while "nextPaginationToken" is set: keep paginating until it is absent.

### Parameters

- `query: JobListParams`

  - `authorId?: string`

    The authorId of the jobs to return. When set, only jobs from the last 30 days are returned (by creation date, or by update date when "status", "type", "types" or "workflowId" is set) unless "createdAfter" or "updatedAfter" is set. Optional.

  - `createdAfter?: string`

    Only return the jobs created after this date (ISO 8601). Only allowed without "status", "type", "types" and "workflowId", which sort jobs by update date: use "updatedAfter" with them. Overrides the 30-day window applied with "authorId" or "hideResults=false". Optional.

  - `hideResults?: boolean`

    If false, jobs submitted with "hideResults": true are not returned. When false, only jobs from the last 30 days are returned (by creation date, or by update date when "status", "type", "types" or "workflowId" is set) unless "createdAfter" or "updatedAfter" is set. Optional.

  - `pageSize?: number`

    The number of items to return in the response. The default value is 50, maximum value is 100, minimum value is 1

  - `paginationToken?: string`

    A token you received in a previous request to query the next page of items

  - `projectId?: string`

    The projectId used for ownership resource management. Either to assert ownership or to set the owner of the resource(s)

  - `status?: "pending" | "queued" | "warming-up" | 5 more`

    The status of the jobs to return. Optional.

    - `"pending"`

    - `"queued"`

    - `"warming-up"`

    - `"in-progress"`

    - `"success"`

    - `"failure"`

    - `"canceled"`

    - `"finalizing"`

  - `type?: "assets-download" | "model-training" | "flux-model-training" | 33 more`

    The type of the jobs to return. If "types" is defined, "type" will be ignored. Optional.

    - `"assets-download"`

    - `"model-training"`

    - `"flux-model-training"`

    - `"musubi-model-training"`

    - `"inference"`

    - `"pixelate"`

    - `"embed"`

    - `"remove-background"`

    - `"vectorize"`

    - `"canvas-export"`

    - `"image-generation"`

    - `"image-prompt-editing"`

    - `"caption"`

    - `"generate-prompt"`

    - `"describe-style"`

    - `"translate"`

    - `"detection"`

    - `"restyle"`

    - `"repaint"`

    - `"reframe"`

    - `"segment"`

    - `"skybox-base-360"`

    - `"skybox-upscale-360"`

    - `"skybox-hdri"`

    - `"skybox-3d"`

    - `"texture"`

    - `"upscale"`

    - `"upscale-skybox"`

    - `"upscale-texture"`

    - `"flux"`

    - `"openai-image-generation"`

    - `"upload"`

    - `"custom"`

    - `"splat"`

    - `"mesh-preview-rendering"`

    - `"workflow"`

  - `types?: Array<"assets-download" | "model-training" | "flux-model-training" | 33 more>`

    The types of the jobs to return, comma separated. If "types" is defined, "type" will be ignored. Can be any of the following values: assets-download, model-training, flux-model-training, musubi-model-training, inference, pixelate, embed, remove-background, vectorize, canvas-export, image-generation, image-prompt-editing, caption, generate-prompt, describe-style, translate, detection, restyle, repaint, reframe, segment, skybox-base-360, skybox-upscale-360, skybox-hdri, skybox-3d, texture, upscale, upscale-skybox, upscale-texture, flux, openai-image-generation, upload, custom, splat, mesh-preview-rendering, workflow. Optional.

    - `"assets-download"`

    - `"model-training"`

    - `"flux-model-training"`

    - `"musubi-model-training"`

    - `"inference"`

    - `"pixelate"`

    - `"embed"`

    - `"remove-background"`

    - `"vectorize"`

    - `"canvas-export"`

    - `"image-generation"`

    - `"image-prompt-editing"`

    - `"caption"`

    - `"generate-prompt"`

    - `"describe-style"`

    - `"translate"`

    - `"detection"`

    - `"restyle"`

    - `"repaint"`

    - `"reframe"`

    - `"segment"`

    - `"skybox-base-360"`

    - `"skybox-upscale-360"`

    - `"skybox-hdri"`

    - `"skybox-3d"`

    - `"texture"`

    - `"upscale"`

    - `"upscale-skybox"`

    - `"upscale-texture"`

    - `"flux"`

    - `"openai-image-generation"`

    - `"upload"`

    - `"custom"`

    - `"splat"`

    - `"mesh-preview-rendering"`

    - `"workflow"`

  - `updatedAfter?: string`

    Only return the jobs updated after this date (ISO 8601). Only allowed with "status", "type", "types" or "workflowId": without them jobs are sorted by creation date, use "createdAfter". Overrides the 30-day window applied with "authorId" or "hideResults=false". Optional.

  - `workflowId?: string`

    Only return the jobs produced by the given workflow. Optional.

### Returns

- `JobListResponse`

  - `createdAt: string`

    The job creation date as an ISO string (example: "2023-02-03T11:19:41.579Z")

  - `jobId: string`

    The job ID (example: "job_ocZCnG1Df35XRL1QyCZSRxAG8")

  - `jobType: "assets-download" | "canvas-export" | "caption" | 37 more`

    The type of job

    - `"assets-download"`

    - `"canvas-export"`

    - `"caption"`

    - `"caption-llava"`

    - `"custom"`

    - `"describe-style"`

    - `"detection"`

    - `"embed"`

    - `"flux"`

    - `"flux-model-training"`

    - `"generate-prompt"`

    - `"image-generation"`

    - `"image-prompt-editing"`

    - `"inference"`

    - `"mesh-preview-rendering"`

    - `"model-download"`

    - `"model-import"`

    - `"model-training"`

    - `"musubi-model-training"`

    - `"openai-image-generation"`

    - `"patch-image"`

    - `"pixelate"`

    - `"reframe"`

    - `"remove-background"`

    - `"repaint"`

    - `"restyle"`

    - `"segment"`

    - `"skybox-3d"`

    - `"skybox-base-360"`

    - `"skybox-hdri"`

    - `"skybox-upscale-360"`

    - `"splat"`

    - `"texture"`

    - `"translate"`

    - `"upload"`

    - `"upscale"`

    - `"upscale-skybox"`

    - `"upscale-texture"`

    - `"vectorize"`

    - `"workflow"`

  - `metadata: Metadata`

    Metadata of the job with some additional information

    - `assetIds?: Array<string>`

      List of produced assets for this job

    - `error?: string | null`

      Eventual error for the job

    - `flow?: Array<Flow>`

      The flow of the job. Only available for workflow jobs.

      - `id: string`

        The id of the node.

      - `status: "failure" | "pending" | "processing" | 3 more`

        The status of the node. Only available for WorkflowJob nodes.

        - `"failure"`

        - `"pending"`

        - `"processing"`

        - `"rejected"`

        - `"skipped"`

        - `"success"`

      - `type: "custom-model" | "for-each" | "generate-prompt" | 8 more`

        The type of the job for the node.

        - `"custom-model"`

        - `"for-each"`

        - `"generate-prompt"`

        - `"list"`

        - `"logic"`

        - `"model"`

        - `"remove-background"`

        - `"transform"`

        - `"user-approval"`

        - `"user-selection"`

        - `"workflow"`

      - `assets?: Array<Asset>`

        List of produced assets for this node.

        - `assetId: string`

        - `url: string`

      - `count?: number`

        Fixed number of iterations for a ForEach node.
        When set, the loop runs exactly `count` times regardless of array input.
        When not set, the loop iterates over the resolved array input.
        Only available for ForEach nodes.

      - `dependsOn?: Array<string>`

        The nodes that this node depends on.
        Only available for nodes that have dependencies. Mainly used for user approval nodes.

      - `includeOutputsInWorkflowJob?: true`

        If true, the outputs of this node will be included in the workflow job's final output.
        Only applicable to producing nodes (custom-model, inference, etc.).
        By default, only last nodes (nodes not referenced by other nodes) contribute to outputs.
        Set this to true to also include intermediate nodes in the final output.
        Note: This should only be set to `true` or left undefined.

        - `true`

      - `inputs?: Array<Input>`

        The inputs of the node.
        For a user-selection node, the array input's `min`/`max` bound how many
        items the user may pick (defaults: 1 and 100); conditional connections may
        be present as additional inputs.

        - `name: string`

          The name that must be user to call the model through the API

        - `type: "boolean" | "file" | "file_array" | 7 more`

          The data type of the input

          - `"boolean"`

          - `"file"`

          - `"file_array"`

          - `"inputs_array"`

          - `"model"`

          - `"model_array"`

          - `"number"`

          - `"number_array"`

          - `"string"`

          - `"string_array"`

        - `allowedValues?: Array<unknown>`

          The allowed values for the input. For `string` or `number` types, creates a single-select
          dropdown.
          For `string_array` type, creates a multi-select dropdown.

        - `backgroundBehavior?: "opaque" | "transparent"`

          Specifies the background behavior for the input. Only available for `file` and `file_array`
          input types with kind `image`.

          - `"opaque"`

          - `"transparent"`

        - `color?: boolean`

          Whether the input is a color or not. Only available for `string` input type.

        - `costImpact?: boolean`

          Whether this input affects the model's cost calculation

        - `default?: unknown`

          The default value for the input

        - `description?: string`

          Help text displayed in the UI to provide additional information about the input

        - `group?: string`

          Used to visually group inputs together in the UI. Inputs with the same group value appear
          consecutively in the UI.

        - `hint?: string`

          Hint text displayed in the UI as a tooltip to guide the user

        - `inputs?: Array<Record<string, unknown>>`

          The list of inputs which form an object within a container array.
          All inputs are the same as the current object.
          This is only available for type inputs_array inputs.

        - `items?: Array<Array<Item>>`

          The configured items for inputs_array type inputs.
          Each item is an array of SubNodeInput that need ref/value resolution.
          Only available for inputs_array type.

          - `name: string`

            The name that must be user to call the model through the API

          - `type: "boolean" | "file" | "file_array" | 7 more`

            The data type of the input

            - `"boolean"`

            - `"file"`

            - `"file_array"`

            - `"inputs_array"`

            - `"model"`

            - `"model_array"`

            - `"number"`

            - `"number_array"`

            - `"string"`

            - `"string_array"`

          - `allowedValues?: Array<unknown>`

            The allowed values for the input. For `string` or `number` types, creates a single-select
            dropdown.
            For `string_array` type, creates a multi-select dropdown.

          - `backgroundBehavior?: "opaque" | "transparent"`

            Specifies the background behavior for the input. Only available for `file` and `file_array`
            input types with kind `image`.

            - `"opaque"`

            - `"transparent"`

          - `color?: boolean`

            Whether the input is a color or not. Only available for `string` input type.

          - `costImpact?: boolean`

            Whether this input affects the model's cost calculation

          - `default?: unknown`

            The default value for the input

          - `description?: string`

            Help text displayed in the UI to provide additional information about the input

          - `group?: string`

            Used to visually group inputs together in the UI. Inputs with the same group value appear
            consecutively in the UI.

          - `hint?: string`

            Hint text displayed in the UI as a tooltip to guide the user

          - `inputs?: Array<Record<string, unknown>>`

            The list of inputs which form an object within a container array.
            All inputs are the same as the current object.
            This is only available for type inputs_array inputs.

          - `kind?: "3d" | "audio" | "document" | 5 more`

            The asset kind of the input. Only taken into account for `file` and `file_array` input types.
            If model provides multiple kinds,
            the input will be not able to create the asset on the flight on API side with dataurl without data:kind, prefix
            `file` and `file_array` inputs always expose a kind: when a model does not declare one,
            `image` is returned, which is the kind used at generation time.

            - `"3d"`

            - `"audio"`

            - `"document"`

            - `"image"`

            - `"image-hdr"`

            - `"json"`

            - `"text"`

            - `"video"`

          - `label?: string`

            The label displayed in the UI for this input

          - `maskFrom?: string`

            The name of the file input field to use as the mask source

          - `max?: number`

            The maximum allowed value. Only available for `number` and `array` input types.

          - `maxDuration?: number`

            The maximum allowed media duration in seconds. Only applies to `file` and `file_array` input types
            for video and audio assets. Validated against `asset.properties.duration` at job creation time.

          - `maxLength?: number`

            The maximum allowed length for `string` and `model` inputs, in characters.
            For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
            ITEMS instead — the length of each item is not constrained.

          - `maxSize?: number`

            The maximum allowed file size in bytes. Only applies to `file` and `file_array` input types.
            Validated against `asset.properties.size` at job creation time.

          - `min?: number`

            The minimum allowed value. Only available for `number` and array input types.

          - `minDuration?: number`

            The minimum allowed media duration in seconds. Only applies to `file` and `file_array` input types
            for video and audio assets. Validated against `asset.properties.duration` at job creation time.

          - `minLength?: number`

            The minimum allowed length for `string` and `model` inputs, in characters.
            For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
            ITEMS instead — the length of each item is not constrained.

          - `modelTypes?: Array<"custom" | "elevenlabs-voice" | "flux.1" | 28 more>`

            The allowed model types for this input. Example: `["flux.1-lora"]`.
            Only available for `model_array` input type.

            - `"custom"`

            - `"elevenlabs-voice"`

            - `"flux.1"`

            - `"flux.1-composition"`

            - `"flux.1-kontext-dev"`

            - `"flux.1-kontext-lora"`

            - `"flux.1-krea-dev"`

            - `"flux.1-krea-lora"`

            - `"flux.1-lora"`

            - `"flux.1-pro"`

            - `"flux.1.1-pro-ultra"`

            - `"flux.2-dev-edit-lora"`

            - `"flux.2-dev-lora"`

            - `"flux.2-klein-4b-edit-lora"`

            - `"flux.2-klein-4b-lora"`

            - `"flux.2-klein-9b-edit-lora"`

            - `"flux.2-klein-9b-lora"`

            - `"flux.2-klein-base-4b-edit-lora"`

            - `"flux.2-klein-base-4b-lora"`

            - `"flux.2-klein-base-9b-edit-lora"`

            - `"flux.2-klein-base-9b-lora"`

            - `"flux1.1-pro"`

            - `"gpt-image-1"`

            - `"qwen-image-2512-lora"`

            - `"qwen-image-edit-2509-lora"`

            - `"qwen-image-edit-2511-lora"`

            - `"qwen-image-edit-lora"`

            - `"qwen-image-lora"`

            - `"zimage-de-turbo-lora"`

            - `"zimage-lora"`

            - `"zimage-turbo-lora"`

          - `parent?: boolean`

            Whether this input represents a parent asset to assign to the produced assets.
            Only available for `file` and `file_array` input types.

            For `file_array`, the parent asset is the first item in the array.

          - `placeholder?: string`

            Placeholder text for the input. Only available for 'string' input type.

          - `prompt?: boolean`

            Whether the input is a prompt. When true, displays as a text area with prompt spark feature.
            Only available for `string` input type.

          - `promptSpark?: boolean`

            Whether the input is used with prompt spark. Only available for `string` input type.

          - `ref?: Ref`

            The reference to another input or output of the same workflow.
            Must have at least one of node or conditional.

            - `conditional?: Array<string>`

              The conditional nodes to reference.
              If the conditional nodes are successful, the node will be successful.
              If the conditional nodes are skipped, the node will be skipped.
              Contains an array of node ids used to check the status of the nodes.

            - `equal?: string`

              This is the desired node output value if ref is an if/else node.

            - `name?: string`

              The name of the input or output to reference.
              If the type is 'workflow', the name is the name of the input of the workflow is required
              If the type is 'node', the name is not mandatory, except if you want all outputs of the node.
              To get all outputs of a node, you can use the name 'all'.

            - `node?: string`

              The node id or 'workflow' if the source is a workflow input.

          - `required?: Required`

            Set of rules that describes when this input is required:

            - `always`: Input is always required
            - `ifNotDefined`: Input is required when another specified input is not defined
            - `ifDefined`: Input is required when another specified input is defined
            - `conditional`: Input is required when other inputs have specific values

            By default, the input is not required.

            - `always?: boolean`

              Whether the input is always required

            - `conditional?: Conditional`

              Makes this input required when other inputs have one of the listed values

              - `values: unknown`

                The conditions to check:

                - Key: name of the input to check
                - Value: values of that input that satisfy the condition

              - `operator?: "and" | "or"`

                How the conditions combine: `and` (all must match) or `or` (any must match)

                - `"and"`

                - `"or"`

            - `ifDefined?: unknown`

              Makes this input required when another input is defined:

              - Key: name of the input that must be defined
              - Value: message to display when this input is required

            - `ifNotDefined?: unknown`

              Makes this input required when another input is not defined:

              - Key: name of the input that must be undefined
              - Value: message to display when this input is required

          - `step?: number`

            The step increment for numeric inputs. Only available for `number` input type.

          - `value?: unknown`

            The value of the input.
            This is the value of the input that will be used to run the node.
            Only available for flows managed by a WorkflowJob.

        - `kind?: "3d" | "audio" | "document" | 5 more`

          The asset kind of the input. Only taken into account for `file` and `file_array` input types.
          If model provides multiple kinds,
          the input will be not able to create the asset on the flight on API side with dataurl without data:kind, prefix
          `file` and `file_array` inputs always expose a kind: when a model does not declare one,
          `image` is returned, which is the kind used at generation time.

          - `"3d"`

          - `"audio"`

          - `"document"`

          - `"image"`

          - `"image-hdr"`

          - `"json"`

          - `"text"`

          - `"video"`

        - `label?: string`

          The label displayed in the UI for this input

        - `maskFrom?: string`

          The name of the file input field to use as the mask source

        - `max?: number`

          The maximum allowed value. Only available for `number` and `array` input types.

        - `maxDuration?: number`

          The maximum allowed media duration in seconds. Only applies to `file` and `file_array` input types
          for video and audio assets. Validated against `asset.properties.duration` at job creation time.

        - `maxLength?: number`

          The maximum allowed length for `string` and `model` inputs, in characters.
          For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
          ITEMS instead — the length of each item is not constrained.

        - `maxSize?: number`

          The maximum allowed file size in bytes. Only applies to `file` and `file_array` input types.
          Validated against `asset.properties.size` at job creation time.

        - `min?: number`

          The minimum allowed value. Only available for `number` and array input types.

        - `minDuration?: number`

          The minimum allowed media duration in seconds. Only applies to `file` and `file_array` input types
          for video and audio assets. Validated against `asset.properties.duration` at job creation time.

        - `minLength?: number`

          The minimum allowed length for `string` and `model` inputs, in characters.
          For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
          ITEMS instead — the length of each item is not constrained.

        - `modelTypes?: Array<"custom" | "elevenlabs-voice" | "flux.1" | 28 more>`

          The allowed model types for this input. Example: `["flux.1-lora"]`.
          Only available for `model_array` input type.

          - `"custom"`

          - `"elevenlabs-voice"`

          - `"flux.1"`

          - `"flux.1-composition"`

          - `"flux.1-kontext-dev"`

          - `"flux.1-kontext-lora"`

          - `"flux.1-krea-dev"`

          - `"flux.1-krea-lora"`

          - `"flux.1-lora"`

          - `"flux.1-pro"`

          - `"flux.1.1-pro-ultra"`

          - `"flux.2-dev-edit-lora"`

          - `"flux.2-dev-lora"`

          - `"flux.2-klein-4b-edit-lora"`

          - `"flux.2-klein-4b-lora"`

          - `"flux.2-klein-9b-edit-lora"`

          - `"flux.2-klein-9b-lora"`

          - `"flux.2-klein-base-4b-edit-lora"`

          - `"flux.2-klein-base-4b-lora"`

          - `"flux.2-klein-base-9b-edit-lora"`

          - `"flux.2-klein-base-9b-lora"`

          - `"flux1.1-pro"`

          - `"gpt-image-1"`

          - `"qwen-image-2512-lora"`

          - `"qwen-image-edit-2509-lora"`

          - `"qwen-image-edit-2511-lora"`

          - `"qwen-image-edit-lora"`

          - `"qwen-image-lora"`

          - `"zimage-de-turbo-lora"`

          - `"zimage-lora"`

          - `"zimage-turbo-lora"`

        - `parent?: boolean`

          Whether this input represents a parent asset to assign to the produced assets.
          Only available for `file` and `file_array` input types.

          For `file_array`, the parent asset is the first item in the array.

        - `placeholder?: string`

          Placeholder text for the input. Only available for 'string' input type.

        - `prompt?: boolean`

          Whether the input is a prompt. When true, displays as a text area with prompt spark feature.
          Only available for `string` input type.

        - `promptSpark?: boolean`

          Whether the input is used with prompt spark. Only available for `string` input type.

        - `ref?: Ref`

          The reference to another input or output of the same workflow.
          Must have at least one of node or conditional.

          - `conditional?: Array<string>`

            The conditional nodes to reference.
            If the conditional nodes are successful, the node will be successful.
            If the conditional nodes are skipped, the node will be skipped.
            Contains an array of node ids used to check the status of the nodes.

          - `equal?: string`

            This is the desired node output value if ref is an if/else node.

          - `name?: string`

            The name of the input or output to reference.
            If the type is 'workflow', the name is the name of the input of the workflow is required
            If the type is 'node', the name is not mandatory, except if you want all outputs of the node.
            To get all outputs of a node, you can use the name 'all'.

          - `node?: string`

            The node id or 'workflow' if the source is a workflow input.

        - `required?: Required`

          Set of rules that describes when this input is required:

          - `always`: Input is always required
          - `ifNotDefined`: Input is required when another specified input is not defined
          - `ifDefined`: Input is required when another specified input is defined
          - `conditional`: Input is required when other inputs have specific values

          By default, the input is not required.

          - `always?: boolean`

            Whether the input is always required

          - `conditional?: Conditional`

            Makes this input required when other inputs have one of the listed values

            - `values: unknown`

              The conditions to check:

              - Key: name of the input to check
              - Value: values of that input that satisfy the condition

            - `operator?: "and" | "or"`

              How the conditions combine: `and` (all must match) or `or` (any must match)

              - `"and"`

              - `"or"`

          - `ifDefined?: unknown`

            Makes this input required when another input is defined:

            - Key: name of the input that must be defined
            - Value: message to display when this input is required

          - `ifNotDefined?: unknown`

            Makes this input required when another input is not defined:

            - Key: name of the input that must be undefined
            - Value: message to display when this input is required

        - `step?: number`

          The step increment for numeric inputs. Only available for `number` input type.

        - `value?: unknown`

          The value of the input.
          This is the value of the input that will be used to run the node.
          Only available for flows managed by a WorkflowJob.

      - `items?: Array<string>`

        Statically-configured items for a List node, or the frozen candidate list
        of a UserSelection node. The values can be strings, numbers, or asset IDs.

      - `iterationIndex?: number`

        Zero-based index of the iteration this node copy belongs to.
        Set on dynamically-created copies of loop body nodes.

      - `jobId?: string`

        If the flow is part of a WorkflowJob, this is the jobId for the node.
        jobId is only available for nodes started. A node "Pending" for a running workflow job is not started.

      - `logic?: Logic`

        The logic of the node.
        Only available for logic nodes.

        - `cases?: Array<Case>`

          The cases of the logic.
          Only available for if/else nodes.

          - `condition: string`

          - `value: string`

        - `default?: string`

          The default case of the logic.
          Contains the id/output of the node to execute if no case is matched.
          Only available for if/else nodes.

        - `transform?: string`

          The transform of the logic.
          Only available for transform nodes.

      - `logicType?: "if-else"`

        The type of the logic for the node.
        Only available for logic nodes.

        - `"if-else"`

      - `loopBodyNodeIds?: Array<string>`

        IDs of the body template nodes that belong to this ForEach loop.
        At runtime these templates are cloned once per iteration and marked Skipped.
        Only available for ForEach nodes.

      - `loopNodeId?: string`

        ID of the ForEach node that spawned this iteration copy.
        Set on dynamically-created copies of loop body nodes.

      - `modelId?: string`

        The model id for the node. Mainly used for custom model tasks.

      - `output?: unknown`

        The output of the node.
        Only available for logic nodes.

      - `workflowId?: string`

        The workflow id for the node. Mainly used for workflow tasks.

    - `hint?: string`

      Actionable hint for the user explaining what went wrong and how to resolve it.

    - `input?: Record<string, unknown>`

      The inputs for the job

    - `output?: Record<string, unknown>`

      May contain the output of the job for specific custom models jobs.
      Only available for custom models which generate non-assets outputs.
      Example: LLM text results.

    - `outputModelId?: string`

      For voice-clone jobs: the ID of the model being trained.

    - `workflowId?: string`

      The workflow ID of the job if job is part of a workflow.

    - `workflowJobId?: string`

      The workflow job ID of the job if job is part of a workflow job.

  - `progress: number`

    Progress of the job (between 0 and 1)

  - `status: "canceled" | "failure" | "finalizing" | 5 more`

    The current status of the job

    - `"canceled"`

    - `"failure"`

    - `"finalizing"`

    - `"in-progress"`

    - `"pending"`

    - `"queued"`

    - `"success"`

    - `"warming-up"`

  - `statusHistory: Array<StatusHistory>`

    The history of the different statuses the job went through with the ISO string date
    of when the job reached each statuses.

    - `date: string`

    - `status: "canceled" | "failure" | "finalizing" | 5 more`

      - `"canceled"`

      - `"failure"`

      - `"finalizing"`

      - `"in-progress"`

      - `"pending"`

      - `"queued"`

      - `"success"`

      - `"warming-up"`

  - `updatedAt: string`

    The job last update date as an ISO string (example: "2023-02-03T11:19:41.579Z")

  - `authorId?: string`

    The author user ID (example: "dcf121faaa1a0a0bbbd9ca1b73d62aea")

  - `billing?: Billing`

    The billing of the job

    - `cuCost: number`

    - `cuDiscount: number`

    - `cuCostDetails?: CuCostDetails`

      Compute Units charged for the ADD-ONS of this job, per action — the fees
      paid on top of the generation itself, such as `quality-gate`.

      `cuCost` above is the main action alone, so the job's total is `cuCost`
      plus the values here.

      Two caveats when displaying it:

      - These are a remaining refundable balance, not a receipt: a job that
        failed or was cancelled has had its add-ons refunded, so they read 0
        while `cuCost` still shows the main action's original charge.
      - `ip-detection` is part of the shape but is never populated today: that
        fee is charged outside the job and reported once, as
        `ipDetection.creativeUnitsCharged`, in the response of the request that
        ran it.

      Absent when the job paid for no add-on.

      - `"ip-detection"?: number`

      - `"quality-gate"?: number`

    - `disableRefund?: boolean`

      When true, the credits charged for this job are not automatically
      refunded if the generation fails, because the model used does not
      support refund-on-failure. Absent or false means a failed generation is
      refunded as usual.

  - `ownerId?: string`

    The owner ID (example: "team_U3Qmc8PCdWXwAQJ4Dvw4tV6D")

### Example

```typescript
import Scenario from '@scenario-labs/sdk';

const client = new Scenario({
  apiKey: process.env['SCENARIO_SDK_API_KEY'], // This is the default and can be omitted
  apiSecret: process.env['SCENARIO_SDK_API_SECRET'], // This is the default and can be omitted
});

// Automatically fetches more pages as needed.
for await (const jobListResponse of client.jobs.list()) {
  console.log(jobListResponse.createdAt);
}
```

#### Response

```json
{
  "jobs": [
    {
      "createdAt": "createdAt",
      "jobId": "jobId",
      "jobType": "assets-download",
      "metadata": {
        "assetIds": [
          "string"
        ],
        "error": "error",
        "flow": [
          {
            "id": "id",
            "status": "failure",
            "type": "custom-model",
            "assets": [
              {
                "assetId": "assetId",
                "url": "url"
              }
            ],
            "count": 0,
            "dependsOn": [
              "string"
            ],
            "includeOutputsInWorkflowJob": true,
            "inputs": [
              {
                "name": "name",
                "type": "boolean",
                "allowedValues": [
                  {}
                ],
                "backgroundBehavior": "opaque",
                "color": true,
                "costImpact": true,
                "default": {},
                "description": "description",
                "group": "group",
                "hint": "hint",
                "inputs": [
                  {
                    "foo": "bar"
                  }
                ],
                "items": [
                  [
                    {
                      "name": "name",
                      "type": "boolean",
                      "allowedValues": [
                        {}
                      ],
                      "backgroundBehavior": "opaque",
                      "color": true,
                      "costImpact": true,
                      "default": {},
                      "description": "description",
                      "group": "group",
                      "hint": "hint",
                      "inputs": [
                        {
                          "foo": "bar"
                        }
                      ],
                      "kind": "3d",
                      "label": "label",
                      "maskFrom": "maskFrom",
                      "max": 0,
                      "maxDuration": 0,
                      "maxLength": 0,
                      "maxSize": 0,
                      "min": 0,
                      "minDuration": 0,
                      "minLength": 0,
                      "modelTypes": [
                        "custom"
                      ],
                      "parent": true,
                      "placeholder": "placeholder",
                      "prompt": true,
                      "promptSpark": true,
                      "ref": {
                        "conditional": [
                          "string"
                        ],
                        "equal": "equal",
                        "name": "name",
                        "node": "node"
                      },
                      "required": {
                        "always": true,
                        "conditional": {
                          "values": {},
                          "operator": "and"
                        },
                        "ifDefined": {},
                        "ifNotDefined": {}
                      },
                      "step": 1,
                      "value": {}
                    }
                  ]
                ],
                "kind": "3d",
                "label": "label",
                "maskFrom": "maskFrom",
                "max": 0,
                "maxDuration": 0,
                "maxLength": 0,
                "maxSize": 0,
                "min": 0,
                "minDuration": 0,
                "minLength": 0,
                "modelTypes": [
                  "custom"
                ],
                "parent": true,
                "placeholder": "placeholder",
                "prompt": true,
                "promptSpark": true,
                "ref": {
                  "conditional": [
                    "string"
                  ],
                  "equal": "equal",
                  "name": "name",
                  "node": "node"
                },
                "required": {
                  "always": true,
                  "conditional": {
                    "values": {},
                    "operator": "and"
                  },
                  "ifDefined": {},
                  "ifNotDefined": {}
                },
                "step": 1,
                "value": {}
              }
            ],
            "items": [
              "string"
            ],
            "iterationIndex": 0,
            "jobId": "jobId",
            "logic": {
              "cases": [
                {
                  "condition": "condition",
                  "value": "value"
                }
              ],
              "default": "default",
              "transform": "transform"
            },
            "logicType": "if-else",
            "loopBodyNodeIds": [
              "string"
            ],
            "loopNodeId": "loopNodeId",
            "modelId": "modelId",
            "output": {},
            "workflowId": "workflowId"
          }
        ],
        "hint": "hint",
        "input": {
          "foo": "bar"
        },
        "output": {
          "foo": "bar"
        },
        "outputModelId": "outputModelId",
        "workflowId": "workflowId",
        "workflowJobId": "workflowJobId"
      },
      "progress": 0,
      "status": "canceled",
      "statusHistory": [
        {
          "date": "date",
          "status": "canceled"
        }
      ],
      "updatedAt": "updatedAt",
      "authorId": "authorId",
      "billing": {
        "cuCost": 0,
        "cuDiscount": 0,
        "cuCostDetails": {
          "ip-detection": 0,
          "quality-gate": 0
        },
        "disableRefund": true
      },
      "ownerId": "ownerId"
    }
  ],
  "nextPaginationToken": "nextPaginationToken"
}
```

## Retrieve

`client.jobs.retrieve(stringjobID, JobRetrieveParamsquery?, RequestOptionsoptions?): JobRetrieveResponse`

**get** `/jobs/{jobId}`

Get job data by job ID

### Parameters

- `jobID: string`

- `query: JobRetrieveParams`

  - `projectId?: string`

    The projectId used for ownership resource management. Either to assert ownership or to set the owner of the resource(s)

### Returns

- `JobRetrieveResponse`

  - `job: Job`

    - `createdAt: string`

      The job creation date as an ISO string (example: "2023-02-03T11:19:41.579Z")

    - `jobId: string`

      The job ID (example: "job_ocZCnG1Df35XRL1QyCZSRxAG8")

    - `jobType: "assets-download" | "canvas-export" | "caption" | 37 more`

      The type of job

      - `"assets-download"`

      - `"canvas-export"`

      - `"caption"`

      - `"caption-llava"`

      - `"custom"`

      - `"describe-style"`

      - `"detection"`

      - `"embed"`

      - `"flux"`

      - `"flux-model-training"`

      - `"generate-prompt"`

      - `"image-generation"`

      - `"image-prompt-editing"`

      - `"inference"`

      - `"mesh-preview-rendering"`

      - `"model-download"`

      - `"model-import"`

      - `"model-training"`

      - `"musubi-model-training"`

      - `"openai-image-generation"`

      - `"patch-image"`

      - `"pixelate"`

      - `"reframe"`

      - `"remove-background"`

      - `"repaint"`

      - `"restyle"`

      - `"segment"`

      - `"skybox-3d"`

      - `"skybox-base-360"`

      - `"skybox-hdri"`

      - `"skybox-upscale-360"`

      - `"splat"`

      - `"texture"`

      - `"translate"`

      - `"upload"`

      - `"upscale"`

      - `"upscale-skybox"`

      - `"upscale-texture"`

      - `"vectorize"`

      - `"workflow"`

    - `metadata: Metadata`

      Metadata of the job with some additional information

      - `assetIds?: Array<string>`

        List of produced assets for this job

      - `error?: string | null`

        Eventual error for the job

      - `flow?: Array<Flow>`

        The flow of the job. Only available for workflow jobs.

        - `id: string`

          The id of the node.

        - `status: "failure" | "pending" | "processing" | 3 more`

          The status of the node. Only available for WorkflowJob nodes.

          - `"failure"`

          - `"pending"`

          - `"processing"`

          - `"rejected"`

          - `"skipped"`

          - `"success"`

        - `type: "custom-model" | "for-each" | "generate-prompt" | 8 more`

          The type of the job for the node.

          - `"custom-model"`

          - `"for-each"`

          - `"generate-prompt"`

          - `"list"`

          - `"logic"`

          - `"model"`

          - `"remove-background"`

          - `"transform"`

          - `"user-approval"`

          - `"user-selection"`

          - `"workflow"`

        - `assets?: Array<Asset>`

          List of produced assets for this node.

          - `assetId: string`

          - `url: string`

        - `count?: number`

          Fixed number of iterations for a ForEach node.
          When set, the loop runs exactly `count` times regardless of array input.
          When not set, the loop iterates over the resolved array input.
          Only available for ForEach nodes.

        - `dependsOn?: Array<string>`

          The nodes that this node depends on.
          Only available for nodes that have dependencies. Mainly used for user approval nodes.

        - `includeOutputsInWorkflowJob?: true`

          If true, the outputs of this node will be included in the workflow job's final output.
          Only applicable to producing nodes (custom-model, inference, etc.).
          By default, only last nodes (nodes not referenced by other nodes) contribute to outputs.
          Set this to true to also include intermediate nodes in the final output.
          Note: This should only be set to `true` or left undefined.

          - `true`

        - `inputs?: Array<Input>`

          The inputs of the node.
          For a user-selection node, the array input's `min`/`max` bound how many
          items the user may pick (defaults: 1 and 100); conditional connections may
          be present as additional inputs.

          - `name: string`

            The name that must be user to call the model through the API

          - `type: "boolean" | "file" | "file_array" | 7 more`

            The data type of the input

            - `"boolean"`

            - `"file"`

            - `"file_array"`

            - `"inputs_array"`

            - `"model"`

            - `"model_array"`

            - `"number"`

            - `"number_array"`

            - `"string"`

            - `"string_array"`

          - `allowedValues?: Array<unknown>`

            The allowed values for the input. For `string` or `number` types, creates a single-select
            dropdown.
            For `string_array` type, creates a multi-select dropdown.

          - `backgroundBehavior?: "opaque" | "transparent"`

            Specifies the background behavior for the input. Only available for `file` and `file_array`
            input types with kind `image`.

            - `"opaque"`

            - `"transparent"`

          - `color?: boolean`

            Whether the input is a color or not. Only available for `string` input type.

          - `costImpact?: boolean`

            Whether this input affects the model's cost calculation

          - `default?: unknown`

            The default value for the input

          - `description?: string`

            Help text displayed in the UI to provide additional information about the input

          - `group?: string`

            Used to visually group inputs together in the UI. Inputs with the same group value appear
            consecutively in the UI.

          - `hint?: string`

            Hint text displayed in the UI as a tooltip to guide the user

          - `inputs?: Array<Record<string, unknown>>`

            The list of inputs which form an object within a container array.
            All inputs are the same as the current object.
            This is only available for type inputs_array inputs.

          - `items?: Array<Array<Item>>`

            The configured items for inputs_array type inputs.
            Each item is an array of SubNodeInput that need ref/value resolution.
            Only available for inputs_array type.

            - `name: string`

              The name that must be user to call the model through the API

            - `type: "boolean" | "file" | "file_array" | 7 more`

              The data type of the input

              - `"boolean"`

              - `"file"`

              - `"file_array"`

              - `"inputs_array"`

              - `"model"`

              - `"model_array"`

              - `"number"`

              - `"number_array"`

              - `"string"`

              - `"string_array"`

            - `allowedValues?: Array<unknown>`

              The allowed values for the input. For `string` or `number` types, creates a single-select
              dropdown.
              For `string_array` type, creates a multi-select dropdown.

            - `backgroundBehavior?: "opaque" | "transparent"`

              Specifies the background behavior for the input. Only available for `file` and `file_array`
              input types with kind `image`.

              - `"opaque"`

              - `"transparent"`

            - `color?: boolean`

              Whether the input is a color or not. Only available for `string` input type.

            - `costImpact?: boolean`

              Whether this input affects the model's cost calculation

            - `default?: unknown`

              The default value for the input

            - `description?: string`

              Help text displayed in the UI to provide additional information about the input

            - `group?: string`

              Used to visually group inputs together in the UI. Inputs with the same group value appear
              consecutively in the UI.

            - `hint?: string`

              Hint text displayed in the UI as a tooltip to guide the user

            - `inputs?: Array<Record<string, unknown>>`

              The list of inputs which form an object within a container array.
              All inputs are the same as the current object.
              This is only available for type inputs_array inputs.

            - `kind?: "3d" | "audio" | "document" | 5 more`

              The asset kind of the input. Only taken into account for `file` and `file_array` input types.
              If model provides multiple kinds,
              the input will be not able to create the asset on the flight on API side with dataurl without data:kind, prefix
              `file` and `file_array` inputs always expose a kind: when a model does not declare one,
              `image` is returned, which is the kind used at generation time.

              - `"3d"`

              - `"audio"`

              - `"document"`

              - `"image"`

              - `"image-hdr"`

              - `"json"`

              - `"text"`

              - `"video"`

            - `label?: string`

              The label displayed in the UI for this input

            - `maskFrom?: string`

              The name of the file input field to use as the mask source

            - `max?: number`

              The maximum allowed value. Only available for `number` and `array` input types.

            - `maxDuration?: number`

              The maximum allowed media duration in seconds. Only applies to `file` and `file_array` input types
              for video and audio assets. Validated against `asset.properties.duration` at job creation time.

            - `maxLength?: number`

              The maximum allowed length for `string` and `model` inputs, in characters.
              For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
              ITEMS instead — the length of each item is not constrained.

            - `maxSize?: number`

              The maximum allowed file size in bytes. Only applies to `file` and `file_array` input types.
              Validated against `asset.properties.size` at job creation time.

            - `min?: number`

              The minimum allowed value. Only available for `number` and array input types.

            - `minDuration?: number`

              The minimum allowed media duration in seconds. Only applies to `file` and `file_array` input types
              for video and audio assets. Validated against `asset.properties.duration` at job creation time.

            - `minLength?: number`

              The minimum allowed length for `string` and `model` inputs, in characters.
              For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
              ITEMS instead — the length of each item is not constrained.

            - `modelTypes?: Array<"custom" | "elevenlabs-voice" | "flux.1" | 28 more>`

              The allowed model types for this input. Example: `["flux.1-lora"]`.
              Only available for `model_array` input type.

              - `"custom"`

              - `"elevenlabs-voice"`

              - `"flux.1"`

              - `"flux.1-composition"`

              - `"flux.1-kontext-dev"`

              - `"flux.1-kontext-lora"`

              - `"flux.1-krea-dev"`

              - `"flux.1-krea-lora"`

              - `"flux.1-lora"`

              - `"flux.1-pro"`

              - `"flux.1.1-pro-ultra"`

              - `"flux.2-dev-edit-lora"`

              - `"flux.2-dev-lora"`

              - `"flux.2-klein-4b-edit-lora"`

              - `"flux.2-klein-4b-lora"`

              - `"flux.2-klein-9b-edit-lora"`

              - `"flux.2-klein-9b-lora"`

              - `"flux.2-klein-base-4b-edit-lora"`

              - `"flux.2-klein-base-4b-lora"`

              - `"flux.2-klein-base-9b-edit-lora"`

              - `"flux.2-klein-base-9b-lora"`

              - `"flux1.1-pro"`

              - `"gpt-image-1"`

              - `"qwen-image-2512-lora"`

              - `"qwen-image-edit-2509-lora"`

              - `"qwen-image-edit-2511-lora"`

              - `"qwen-image-edit-lora"`

              - `"qwen-image-lora"`

              - `"zimage-de-turbo-lora"`

              - `"zimage-lora"`

              - `"zimage-turbo-lora"`

            - `parent?: boolean`

              Whether this input represents a parent asset to assign to the produced assets.
              Only available for `file` and `file_array` input types.

              For `file_array`, the parent asset is the first item in the array.

            - `placeholder?: string`

              Placeholder text for the input. Only available for 'string' input type.

            - `prompt?: boolean`

              Whether the input is a prompt. When true, displays as a text area with prompt spark feature.
              Only available for `string` input type.

            - `promptSpark?: boolean`

              Whether the input is used with prompt spark. Only available for `string` input type.

            - `ref?: Ref`

              The reference to another input or output of the same workflow.
              Must have at least one of node or conditional.

              - `conditional?: Array<string>`

                The conditional nodes to reference.
                If the conditional nodes are successful, the node will be successful.
                If the conditional nodes are skipped, the node will be skipped.
                Contains an array of node ids used to check the status of the nodes.

              - `equal?: string`

                This is the desired node output value if ref is an if/else node.

              - `name?: string`

                The name of the input or output to reference.
                If the type is 'workflow', the name is the name of the input of the workflow is required
                If the type is 'node', the name is not mandatory, except if you want all outputs of the node.
                To get all outputs of a node, you can use the name 'all'.

              - `node?: string`

                The node id or 'workflow' if the source is a workflow input.

            - `required?: Required`

              Set of rules that describes when this input is required:

              - `always`: Input is always required
              - `ifNotDefined`: Input is required when another specified input is not defined
              - `ifDefined`: Input is required when another specified input is defined
              - `conditional`: Input is required when other inputs have specific values

              By default, the input is not required.

              - `always?: boolean`

                Whether the input is always required

              - `conditional?: Conditional`

                Makes this input required when other inputs have one of the listed values

                - `values: unknown`

                  The conditions to check:

                  - Key: name of the input to check
                  - Value: values of that input that satisfy the condition

                - `operator?: "and" | "or"`

                  How the conditions combine: `and` (all must match) or `or` (any must match)

                  - `"and"`

                  - `"or"`

              - `ifDefined?: unknown`

                Makes this input required when another input is defined:

                - Key: name of the input that must be defined
                - Value: message to display when this input is required

              - `ifNotDefined?: unknown`

                Makes this input required when another input is not defined:

                - Key: name of the input that must be undefined
                - Value: message to display when this input is required

            - `step?: number`

              The step increment for numeric inputs. Only available for `number` input type.

            - `value?: unknown`

              The value of the input.
              This is the value of the input that will be used to run the node.
              Only available for flows managed by a WorkflowJob.

          - `kind?: "3d" | "audio" | "document" | 5 more`

            The asset kind of the input. Only taken into account for `file` and `file_array` input types.
            If model provides multiple kinds,
            the input will be not able to create the asset on the flight on API side with dataurl without data:kind, prefix
            `file` and `file_array` inputs always expose a kind: when a model does not declare one,
            `image` is returned, which is the kind used at generation time.

            - `"3d"`

            - `"audio"`

            - `"document"`

            - `"image"`

            - `"image-hdr"`

            - `"json"`

            - `"text"`

            - `"video"`

          - `label?: string`

            The label displayed in the UI for this input

          - `maskFrom?: string`

            The name of the file input field to use as the mask source

          - `max?: number`

            The maximum allowed value. Only available for `number` and `array` input types.

          - `maxDuration?: number`

            The maximum allowed media duration in seconds. Only applies to `file` and `file_array` input types
            for video and audio assets. Validated against `asset.properties.duration` at job creation time.

          - `maxLength?: number`

            The maximum allowed length for `string` and `model` inputs, in characters.
            For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
            ITEMS instead — the length of each item is not constrained.

          - `maxSize?: number`

            The maximum allowed file size in bytes. Only applies to `file` and `file_array` input types.
            Validated against `asset.properties.size` at job creation time.

          - `min?: number`

            The minimum allowed value. Only available for `number` and array input types.

          - `minDuration?: number`

            The minimum allowed media duration in seconds. Only applies to `file` and `file_array` input types
            for video and audio assets. Validated against `asset.properties.duration` at job creation time.

          - `minLength?: number`

            The minimum allowed length for `string` and `model` inputs, in characters.
            For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
            ITEMS instead — the length of each item is not constrained.

          - `modelTypes?: Array<"custom" | "elevenlabs-voice" | "flux.1" | 28 more>`

            The allowed model types for this input. Example: `["flux.1-lora"]`.
            Only available for `model_array` input type.

            - `"custom"`

            - `"elevenlabs-voice"`

            - `"flux.1"`

            - `"flux.1-composition"`

            - `"flux.1-kontext-dev"`

            - `"flux.1-kontext-lora"`

            - `"flux.1-krea-dev"`

            - `"flux.1-krea-lora"`

            - `"flux.1-lora"`

            - `"flux.1-pro"`

            - `"flux.1.1-pro-ultra"`

            - `"flux.2-dev-edit-lora"`

            - `"flux.2-dev-lora"`

            - `"flux.2-klein-4b-edit-lora"`

            - `"flux.2-klein-4b-lora"`

            - `"flux.2-klein-9b-edit-lora"`

            - `"flux.2-klein-9b-lora"`

            - `"flux.2-klein-base-4b-edit-lora"`

            - `"flux.2-klein-base-4b-lora"`

            - `"flux.2-klein-base-9b-edit-lora"`

            - `"flux.2-klein-base-9b-lora"`

            - `"flux1.1-pro"`

            - `"gpt-image-1"`

            - `"qwen-image-2512-lora"`

            - `"qwen-image-edit-2509-lora"`

            - `"qwen-image-edit-2511-lora"`

            - `"qwen-image-edit-lora"`

            - `"qwen-image-lora"`

            - `"zimage-de-turbo-lora"`

            - `"zimage-lora"`

            - `"zimage-turbo-lora"`

          - `parent?: boolean`

            Whether this input represents a parent asset to assign to the produced assets.
            Only available for `file` and `file_array` input types.

            For `file_array`, the parent asset is the first item in the array.

          - `placeholder?: string`

            Placeholder text for the input. Only available for 'string' input type.

          - `prompt?: boolean`

            Whether the input is a prompt. When true, displays as a text area with prompt spark feature.
            Only available for `string` input type.

          - `promptSpark?: boolean`

            Whether the input is used with prompt spark. Only available for `string` input type.

          - `ref?: Ref`

            The reference to another input or output of the same workflow.
            Must have at least one of node or conditional.

            - `conditional?: Array<string>`

              The conditional nodes to reference.
              If the conditional nodes are successful, the node will be successful.
              If the conditional nodes are skipped, the node will be skipped.
              Contains an array of node ids used to check the status of the nodes.

            - `equal?: string`

              This is the desired node output value if ref is an if/else node.

            - `name?: string`

              The name of the input or output to reference.
              If the type is 'workflow', the name is the name of the input of the workflow is required
              If the type is 'node', the name is not mandatory, except if you want all outputs of the node.
              To get all outputs of a node, you can use the name 'all'.

            - `node?: string`

              The node id or 'workflow' if the source is a workflow input.

          - `required?: Required`

            Set of rules that describes when this input is required:

            - `always`: Input is always required
            - `ifNotDefined`: Input is required when another specified input is not defined
            - `ifDefined`: Input is required when another specified input is defined
            - `conditional`: Input is required when other inputs have specific values

            By default, the input is not required.

            - `always?: boolean`

              Whether the input is always required

            - `conditional?: Conditional`

              Makes this input required when other inputs have one of the listed values

              - `values: unknown`

                The conditions to check:

                - Key: name of the input to check
                - Value: values of that input that satisfy the condition

              - `operator?: "and" | "or"`

                How the conditions combine: `and` (all must match) or `or` (any must match)

                - `"and"`

                - `"or"`

            - `ifDefined?: unknown`

              Makes this input required when another input is defined:

              - Key: name of the input that must be defined
              - Value: message to display when this input is required

            - `ifNotDefined?: unknown`

              Makes this input required when another input is not defined:

              - Key: name of the input that must be undefined
              - Value: message to display when this input is required

          - `step?: number`

            The step increment for numeric inputs. Only available for `number` input type.

          - `value?: unknown`

            The value of the input.
            This is the value of the input that will be used to run the node.
            Only available for flows managed by a WorkflowJob.

        - `items?: Array<string>`

          Statically-configured items for a List node, or the frozen candidate list
          of a UserSelection node. The values can be strings, numbers, or asset IDs.

        - `iterationIndex?: number`

          Zero-based index of the iteration this node copy belongs to.
          Set on dynamically-created copies of loop body nodes.

        - `jobId?: string`

          If the flow is part of a WorkflowJob, this is the jobId for the node.
          jobId is only available for nodes started. A node "Pending" for a running workflow job is not started.

        - `logic?: Logic`

          The logic of the node.
          Only available for logic nodes.

          - `cases?: Array<Case>`

            The cases of the logic.
            Only available for if/else nodes.

            - `condition: string`

            - `value: string`

          - `default?: string`

            The default case of the logic.
            Contains the id/output of the node to execute if no case is matched.
            Only available for if/else nodes.

          - `transform?: string`

            The transform of the logic.
            Only available for transform nodes.

        - `logicType?: "if-else"`

          The type of the logic for the node.
          Only available for logic nodes.

          - `"if-else"`

        - `loopBodyNodeIds?: Array<string>`

          IDs of the body template nodes that belong to this ForEach loop.
          At runtime these templates are cloned once per iteration and marked Skipped.
          Only available for ForEach nodes.

        - `loopNodeId?: string`

          ID of the ForEach node that spawned this iteration copy.
          Set on dynamically-created copies of loop body nodes.

        - `modelId?: string`

          The model id for the node. Mainly used for custom model tasks.

        - `output?: unknown`

          The output of the node.
          Only available for logic nodes.

        - `workflowId?: string`

          The workflow id for the node. Mainly used for workflow tasks.

      - `hint?: string`

        Actionable hint for the user explaining what went wrong and how to resolve it.

      - `input?: Record<string, unknown>`

        The inputs for the job

      - `output?: Record<string, unknown>`

        May contain the output of the job for specific custom models jobs.
        Only available for custom models which generate non-assets outputs.
        Example: LLM text results.

      - `outputModelId?: string`

        For voice-clone jobs: the ID of the model being trained.

      - `workflowId?: string`

        The workflow ID of the job if job is part of a workflow.

      - `workflowJobId?: string`

        The workflow job ID of the job if job is part of a workflow job.

    - `progress: number`

      Progress of the job (between 0 and 1)

    - `status: "canceled" | "failure" | "finalizing" | 5 more`

      The current status of the job

      - `"canceled"`

      - `"failure"`

      - `"finalizing"`

      - `"in-progress"`

      - `"pending"`

      - `"queued"`

      - `"success"`

      - `"warming-up"`

    - `statusHistory: Array<StatusHistory>`

      The history of the different statuses the job went through with the ISO string date
      of when the job reached each statuses.

      - `date: string`

      - `status: "canceled" | "failure" | "finalizing" | 5 more`

        - `"canceled"`

        - `"failure"`

        - `"finalizing"`

        - `"in-progress"`

        - `"pending"`

        - `"queued"`

        - `"success"`

        - `"warming-up"`

    - `updatedAt: string`

      The job last update date as an ISO string (example: "2023-02-03T11:19:41.579Z")

    - `authorId?: string`

      The author user ID (example: "dcf121faaa1a0a0bbbd9ca1b73d62aea")

    - `billing?: Billing`

      The billing of the job

      - `cuCost: number`

      - `cuDiscount: number`

      - `cuCostDetails?: CuCostDetails`

        Compute Units charged for the ADD-ONS of this job, per action — the fees
        paid on top of the generation itself, such as `quality-gate`.

        `cuCost` above is the main action alone, so the job's total is `cuCost`
        plus the values here.

        Two caveats when displaying it:

        - These are a remaining refundable balance, not a receipt: a job that
          failed or was cancelled has had its add-ons refunded, so they read 0
          while `cuCost` still shows the main action's original charge.
        - `ip-detection` is part of the shape but is never populated today: that
          fee is charged outside the job and reported once, as
          `ipDetection.creativeUnitsCharged`, in the response of the request that
          ran it.

        Absent when the job paid for no add-on.

        - `"ip-detection"?: number`

        - `"quality-gate"?: number`

      - `disableRefund?: boolean`

        When true, the credits charged for this job are not automatically
        refunded if the generation fails, because the model used does not
        support refund-on-failure. Absent or false means a failed generation is
        refunded as usual.

    - `ownerId?: string`

      The owner ID (example: "team_U3Qmc8PCdWXwAQJ4Dvw4tV6D")

### Example

```typescript
import Scenario from '@scenario-labs/sdk';

const client = new Scenario({
  apiKey: process.env['SCENARIO_SDK_API_KEY'], // This is the default and can be omitted
  apiSecret: process.env['SCENARIO_SDK_API_SECRET'], // This is the default and can be omitted
});

const job = await client.jobs.retrieve('jobId');

console.log(job.job);
```

#### Response

```json
{
  "job": {
    "createdAt": "createdAt",
    "jobId": "jobId",
    "jobType": "assets-download",
    "metadata": {
      "assetIds": [
        "string"
      ],
      "error": "error",
      "flow": [
        {
          "id": "id",
          "status": "failure",
          "type": "custom-model",
          "assets": [
            {
              "assetId": "assetId",
              "url": "url"
            }
          ],
          "count": 0,
          "dependsOn": [
            "string"
          ],
          "includeOutputsInWorkflowJob": true,
          "inputs": [
            {
              "name": "name",
              "type": "boolean",
              "allowedValues": [
                {}
              ],
              "backgroundBehavior": "opaque",
              "color": true,
              "costImpact": true,
              "default": {},
              "description": "description",
              "group": "group",
              "hint": "hint",
              "inputs": [
                {
                  "foo": "bar"
                }
              ],
              "items": [
                [
                  {
                    "name": "name",
                    "type": "boolean",
                    "allowedValues": [
                      {}
                    ],
                    "backgroundBehavior": "opaque",
                    "color": true,
                    "costImpact": true,
                    "default": {},
                    "description": "description",
                    "group": "group",
                    "hint": "hint",
                    "inputs": [
                      {
                        "foo": "bar"
                      }
                    ],
                    "kind": "3d",
                    "label": "label",
                    "maskFrom": "maskFrom",
                    "max": 0,
                    "maxDuration": 0,
                    "maxLength": 0,
                    "maxSize": 0,
                    "min": 0,
                    "minDuration": 0,
                    "minLength": 0,
                    "modelTypes": [
                      "custom"
                    ],
                    "parent": true,
                    "placeholder": "placeholder",
                    "prompt": true,
                    "promptSpark": true,
                    "ref": {
                      "conditional": [
                        "string"
                      ],
                      "equal": "equal",
                      "name": "name",
                      "node": "node"
                    },
                    "required": {
                      "always": true,
                      "conditional": {
                        "values": {},
                        "operator": "and"
                      },
                      "ifDefined": {},
                      "ifNotDefined": {}
                    },
                    "step": 1,
                    "value": {}
                  }
                ]
              ],
              "kind": "3d",
              "label": "label",
              "maskFrom": "maskFrom",
              "max": 0,
              "maxDuration": 0,
              "maxLength": 0,
              "maxSize": 0,
              "min": 0,
              "minDuration": 0,
              "minLength": 0,
              "modelTypes": [
                "custom"
              ],
              "parent": true,
              "placeholder": "placeholder",
              "prompt": true,
              "promptSpark": true,
              "ref": {
                "conditional": [
                  "string"
                ],
                "equal": "equal",
                "name": "name",
                "node": "node"
              },
              "required": {
                "always": true,
                "conditional": {
                  "values": {},
                  "operator": "and"
                },
                "ifDefined": {},
                "ifNotDefined": {}
              },
              "step": 1,
              "value": {}
            }
          ],
          "items": [
            "string"
          ],
          "iterationIndex": 0,
          "jobId": "jobId",
          "logic": {
            "cases": [
              {
                "condition": "condition",
                "value": "value"
              }
            ],
            "default": "default",
            "transform": "transform"
          },
          "logicType": "if-else",
          "loopBodyNodeIds": [
            "string"
          ],
          "loopNodeId": "loopNodeId",
          "modelId": "modelId",
          "output": {},
          "workflowId": "workflowId"
        }
      ],
      "hint": "hint",
      "input": {
        "foo": "bar"
      },
      "output": {
        "foo": "bar"
      },
      "outputModelId": "outputModelId",
      "workflowId": "workflowId",
      "workflowJobId": "workflowJobId"
    },
    "progress": 0,
    "status": "canceled",
    "statusHistory": [
      {
        "date": "date",
        "status": "canceled"
      }
    ],
    "updatedAt": "updatedAt",
    "authorId": "authorId",
    "billing": {
      "cuCost": 0,
      "cuDiscount": 0,
      "cuCostDetails": {
        "ip-detection": 0,
        "quality-gate": 0
      },
      "disableRefund": true
    },
    "ownerId": "ownerId"
  }
}
```

## Trigger Action

`client.jobs.triggerAction(stringjobID, JobTriggerActionParamsparams, RequestOptionsoptions?): JobTriggerActionResponse`

**post** `/jobs/{jobId}/action`

Trigger an action on a job: cancel

### Parameters

- `jobID: string`

- `params: JobTriggerActionParams`

  - `projectId?: string`

    Query param: The projectId used for ownership resource management. Either to assert ownership or to set the owner of the resource(s)

  - `action?: "cancel"`

    Body param: The action to execute on the job, such as canceling it. Today only cancel on inference jobs is supported.

    - `"cancel"`

### Returns

- `JobTriggerActionResponse`

  - `job: Job`

    - `createdAt: string`

      The job creation date as an ISO string (example: "2023-02-03T11:19:41.579Z")

    - `jobId: string`

      The job ID (example: "job_ocZCnG1Df35XRL1QyCZSRxAG8")

    - `jobType: "assets-download" | "canvas-export" | "caption" | 37 more`

      The type of job

      - `"assets-download"`

      - `"canvas-export"`

      - `"caption"`

      - `"caption-llava"`

      - `"custom"`

      - `"describe-style"`

      - `"detection"`

      - `"embed"`

      - `"flux"`

      - `"flux-model-training"`

      - `"generate-prompt"`

      - `"image-generation"`

      - `"image-prompt-editing"`

      - `"inference"`

      - `"mesh-preview-rendering"`

      - `"model-download"`

      - `"model-import"`

      - `"model-training"`

      - `"musubi-model-training"`

      - `"openai-image-generation"`

      - `"patch-image"`

      - `"pixelate"`

      - `"reframe"`

      - `"remove-background"`

      - `"repaint"`

      - `"restyle"`

      - `"segment"`

      - `"skybox-3d"`

      - `"skybox-base-360"`

      - `"skybox-hdri"`

      - `"skybox-upscale-360"`

      - `"splat"`

      - `"texture"`

      - `"translate"`

      - `"upload"`

      - `"upscale"`

      - `"upscale-skybox"`

      - `"upscale-texture"`

      - `"vectorize"`

      - `"workflow"`

    - `metadata: Metadata`

      Metadata of the job with some additional information

      - `assetIds?: Array<string>`

        List of produced assets for this job

      - `error?: string | null`

        Eventual error for the job

      - `flow?: Array<Flow>`

        The flow of the job. Only available for workflow jobs.

        - `id: string`

          The id of the node.

        - `status: "failure" | "pending" | "processing" | 3 more`

          The status of the node. Only available for WorkflowJob nodes.

          - `"failure"`

          - `"pending"`

          - `"processing"`

          - `"rejected"`

          - `"skipped"`

          - `"success"`

        - `type: "custom-model" | "for-each" | "generate-prompt" | 8 more`

          The type of the job for the node.

          - `"custom-model"`

          - `"for-each"`

          - `"generate-prompt"`

          - `"list"`

          - `"logic"`

          - `"model"`

          - `"remove-background"`

          - `"transform"`

          - `"user-approval"`

          - `"user-selection"`

          - `"workflow"`

        - `assets?: Array<Asset>`

          List of produced assets for this node.

          - `assetId: string`

          - `url: string`

        - `count?: number`

          Fixed number of iterations for a ForEach node.
          When set, the loop runs exactly `count` times regardless of array input.
          When not set, the loop iterates over the resolved array input.
          Only available for ForEach nodes.

        - `dependsOn?: Array<string>`

          The nodes that this node depends on.
          Only available for nodes that have dependencies. Mainly used for user approval nodes.

        - `includeOutputsInWorkflowJob?: true`

          If true, the outputs of this node will be included in the workflow job's final output.
          Only applicable to producing nodes (custom-model, inference, etc.).
          By default, only last nodes (nodes not referenced by other nodes) contribute to outputs.
          Set this to true to also include intermediate nodes in the final output.
          Note: This should only be set to `true` or left undefined.

          - `true`

        - `inputs?: Array<Input>`

          The inputs of the node.
          For a user-selection node, the array input's `min`/`max` bound how many
          items the user may pick (defaults: 1 and 100); conditional connections may
          be present as additional inputs.

          - `name: string`

            The name that must be user to call the model through the API

          - `type: "boolean" | "file" | "file_array" | 7 more`

            The data type of the input

            - `"boolean"`

            - `"file"`

            - `"file_array"`

            - `"inputs_array"`

            - `"model"`

            - `"model_array"`

            - `"number"`

            - `"number_array"`

            - `"string"`

            - `"string_array"`

          - `allowedValues?: Array<unknown>`

            The allowed values for the input. For `string` or `number` types, creates a single-select
            dropdown.
            For `string_array` type, creates a multi-select dropdown.

          - `backgroundBehavior?: "opaque" | "transparent"`

            Specifies the background behavior for the input. Only available for `file` and `file_array`
            input types with kind `image`.

            - `"opaque"`

            - `"transparent"`

          - `color?: boolean`

            Whether the input is a color or not. Only available for `string` input type.

          - `costImpact?: boolean`

            Whether this input affects the model's cost calculation

          - `default?: unknown`

            The default value for the input

          - `description?: string`

            Help text displayed in the UI to provide additional information about the input

          - `group?: string`

            Used to visually group inputs together in the UI. Inputs with the same group value appear
            consecutively in the UI.

          - `hint?: string`

            Hint text displayed in the UI as a tooltip to guide the user

          - `inputs?: Array<Record<string, unknown>>`

            The list of inputs which form an object within a container array.
            All inputs are the same as the current object.
            This is only available for type inputs_array inputs.

          - `items?: Array<Array<Item>>`

            The configured items for inputs_array type inputs.
            Each item is an array of SubNodeInput that need ref/value resolution.
            Only available for inputs_array type.

            - `name: string`

              The name that must be user to call the model through the API

            - `type: "boolean" | "file" | "file_array" | 7 more`

              The data type of the input

              - `"boolean"`

              - `"file"`

              - `"file_array"`

              - `"inputs_array"`

              - `"model"`

              - `"model_array"`

              - `"number"`

              - `"number_array"`

              - `"string"`

              - `"string_array"`

            - `allowedValues?: Array<unknown>`

              The allowed values for the input. For `string` or `number` types, creates a single-select
              dropdown.
              For `string_array` type, creates a multi-select dropdown.

            - `backgroundBehavior?: "opaque" | "transparent"`

              Specifies the background behavior for the input. Only available for `file` and `file_array`
              input types with kind `image`.

              - `"opaque"`

              - `"transparent"`

            - `color?: boolean`

              Whether the input is a color or not. Only available for `string` input type.

            - `costImpact?: boolean`

              Whether this input affects the model's cost calculation

            - `default?: unknown`

              The default value for the input

            - `description?: string`

              Help text displayed in the UI to provide additional information about the input

            - `group?: string`

              Used to visually group inputs together in the UI. Inputs with the same group value appear
              consecutively in the UI.

            - `hint?: string`

              Hint text displayed in the UI as a tooltip to guide the user

            - `inputs?: Array<Record<string, unknown>>`

              The list of inputs which form an object within a container array.
              All inputs are the same as the current object.
              This is only available for type inputs_array inputs.

            - `kind?: "3d" | "audio" | "document" | 5 more`

              The asset kind of the input. Only taken into account for `file` and `file_array` input types.
              If model provides multiple kinds,
              the input will be not able to create the asset on the flight on API side with dataurl without data:kind, prefix
              `file` and `file_array` inputs always expose a kind: when a model does not declare one,
              `image` is returned, which is the kind used at generation time.

              - `"3d"`

              - `"audio"`

              - `"document"`

              - `"image"`

              - `"image-hdr"`

              - `"json"`

              - `"text"`

              - `"video"`

            - `label?: string`

              The label displayed in the UI for this input

            - `maskFrom?: string`

              The name of the file input field to use as the mask source

            - `max?: number`

              The maximum allowed value. Only available for `number` and `array` input types.

            - `maxDuration?: number`

              The maximum allowed media duration in seconds. Only applies to `file` and `file_array` input types
              for video and audio assets. Validated against `asset.properties.duration` at job creation time.

            - `maxLength?: number`

              The maximum allowed length for `string` and `model` inputs, in characters.
              For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
              ITEMS instead — the length of each item is not constrained.

            - `maxSize?: number`

              The maximum allowed file size in bytes. Only applies to `file` and `file_array` input types.
              Validated against `asset.properties.size` at job creation time.

            - `min?: number`

              The minimum allowed value. Only available for `number` and array input types.

            - `minDuration?: number`

              The minimum allowed media duration in seconds. Only applies to `file` and `file_array` input types
              for video and audio assets. Validated against `asset.properties.duration` at job creation time.

            - `minLength?: number`

              The minimum allowed length for `string` and `model` inputs, in characters.
              For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
              ITEMS instead — the length of each item is not constrained.

            - `modelTypes?: Array<"custom" | "elevenlabs-voice" | "flux.1" | 28 more>`

              The allowed model types for this input. Example: `["flux.1-lora"]`.
              Only available for `model_array` input type.

              - `"custom"`

              - `"elevenlabs-voice"`

              - `"flux.1"`

              - `"flux.1-composition"`

              - `"flux.1-kontext-dev"`

              - `"flux.1-kontext-lora"`

              - `"flux.1-krea-dev"`

              - `"flux.1-krea-lora"`

              - `"flux.1-lora"`

              - `"flux.1-pro"`

              - `"flux.1.1-pro-ultra"`

              - `"flux.2-dev-edit-lora"`

              - `"flux.2-dev-lora"`

              - `"flux.2-klein-4b-edit-lora"`

              - `"flux.2-klein-4b-lora"`

              - `"flux.2-klein-9b-edit-lora"`

              - `"flux.2-klein-9b-lora"`

              - `"flux.2-klein-base-4b-edit-lora"`

              - `"flux.2-klein-base-4b-lora"`

              - `"flux.2-klein-base-9b-edit-lora"`

              - `"flux.2-klein-base-9b-lora"`

              - `"flux1.1-pro"`

              - `"gpt-image-1"`

              - `"qwen-image-2512-lora"`

              - `"qwen-image-edit-2509-lora"`

              - `"qwen-image-edit-2511-lora"`

              - `"qwen-image-edit-lora"`

              - `"qwen-image-lora"`

              - `"zimage-de-turbo-lora"`

              - `"zimage-lora"`

              - `"zimage-turbo-lora"`

            - `parent?: boolean`

              Whether this input represents a parent asset to assign to the produced assets.
              Only available for `file` and `file_array` input types.

              For `file_array`, the parent asset is the first item in the array.

            - `placeholder?: string`

              Placeholder text for the input. Only available for 'string' input type.

            - `prompt?: boolean`

              Whether the input is a prompt. When true, displays as a text area with prompt spark feature.
              Only available for `string` input type.

            - `promptSpark?: boolean`

              Whether the input is used with prompt spark. Only available for `string` input type.

            - `ref?: Ref`

              The reference to another input or output of the same workflow.
              Must have at least one of node or conditional.

              - `conditional?: Array<string>`

                The conditional nodes to reference.
                If the conditional nodes are successful, the node will be successful.
                If the conditional nodes are skipped, the node will be skipped.
                Contains an array of node ids used to check the status of the nodes.

              - `equal?: string`

                This is the desired node output value if ref is an if/else node.

              - `name?: string`

                The name of the input or output to reference.
                If the type is 'workflow', the name is the name of the input of the workflow is required
                If the type is 'node', the name is not mandatory, except if you want all outputs of the node.
                To get all outputs of a node, you can use the name 'all'.

              - `node?: string`

                The node id or 'workflow' if the source is a workflow input.

            - `required?: Required`

              Set of rules that describes when this input is required:

              - `always`: Input is always required
              - `ifNotDefined`: Input is required when another specified input is not defined
              - `ifDefined`: Input is required when another specified input is defined
              - `conditional`: Input is required when other inputs have specific values

              By default, the input is not required.

              - `always?: boolean`

                Whether the input is always required

              - `conditional?: Conditional`

                Makes this input required when other inputs have one of the listed values

                - `values: unknown`

                  The conditions to check:

                  - Key: name of the input to check
                  - Value: values of that input that satisfy the condition

                - `operator?: "and" | "or"`

                  How the conditions combine: `and` (all must match) or `or` (any must match)

                  - `"and"`

                  - `"or"`

              - `ifDefined?: unknown`

                Makes this input required when another input is defined:

                - Key: name of the input that must be defined
                - Value: message to display when this input is required

              - `ifNotDefined?: unknown`

                Makes this input required when another input is not defined:

                - Key: name of the input that must be undefined
                - Value: message to display when this input is required

            - `step?: number`

              The step increment for numeric inputs. Only available for `number` input type.

            - `value?: unknown`

              The value of the input.
              This is the value of the input that will be used to run the node.
              Only available for flows managed by a WorkflowJob.

          - `kind?: "3d" | "audio" | "document" | 5 more`

            The asset kind of the input. Only taken into account for `file` and `file_array` input types.
            If model provides multiple kinds,
            the input will be not able to create the asset on the flight on API side with dataurl without data:kind, prefix
            `file` and `file_array` inputs always expose a kind: when a model does not declare one,
            `image` is returned, which is the kind used at generation time.

            - `"3d"`

            - `"audio"`

            - `"document"`

            - `"image"`

            - `"image-hdr"`

            - `"json"`

            - `"text"`

            - `"video"`

          - `label?: string`

            The label displayed in the UI for this input

          - `maskFrom?: string`

            The name of the file input field to use as the mask source

          - `max?: number`

            The maximum allowed value. Only available for `number` and `array` input types.

          - `maxDuration?: number`

            The maximum allowed media duration in seconds. Only applies to `file` and `file_array` input types
            for video and audio assets. Validated against `asset.properties.duration` at job creation time.

          - `maxLength?: number`

            The maximum allowed length for `string` and `model` inputs, in characters.
            For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
            ITEMS instead — the length of each item is not constrained.

          - `maxSize?: number`

            The maximum allowed file size in bytes. Only applies to `file` and `file_array` input types.
            Validated against `asset.properties.size` at job creation time.

          - `min?: number`

            The minimum allowed value. Only available for `number` and array input types.

          - `minDuration?: number`

            The minimum allowed media duration in seconds. Only applies to `file` and `file_array` input types
            for video and audio assets. Validated against `asset.properties.duration` at job creation time.

          - `minLength?: number`

            The minimum allowed length for `string` and `model` inputs, in characters.
            For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
            ITEMS instead — the length of each item is not constrained.

          - `modelTypes?: Array<"custom" | "elevenlabs-voice" | "flux.1" | 28 more>`

            The allowed model types for this input. Example: `["flux.1-lora"]`.
            Only available for `model_array` input type.

            - `"custom"`

            - `"elevenlabs-voice"`

            - `"flux.1"`

            - `"flux.1-composition"`

            - `"flux.1-kontext-dev"`

            - `"flux.1-kontext-lora"`

            - `"flux.1-krea-dev"`

            - `"flux.1-krea-lora"`

            - `"flux.1-lora"`

            - `"flux.1-pro"`

            - `"flux.1.1-pro-ultra"`

            - `"flux.2-dev-edit-lora"`

            - `"flux.2-dev-lora"`

            - `"flux.2-klein-4b-edit-lora"`

            - `"flux.2-klein-4b-lora"`

            - `"flux.2-klein-9b-edit-lora"`

            - `"flux.2-klein-9b-lora"`

            - `"flux.2-klein-base-4b-edit-lora"`

            - `"flux.2-klein-base-4b-lora"`

            - `"flux.2-klein-base-9b-edit-lora"`

            - `"flux.2-klein-base-9b-lora"`

            - `"flux1.1-pro"`

            - `"gpt-image-1"`

            - `"qwen-image-2512-lora"`

            - `"qwen-image-edit-2509-lora"`

            - `"qwen-image-edit-2511-lora"`

            - `"qwen-image-edit-lora"`

            - `"qwen-image-lora"`

            - `"zimage-de-turbo-lora"`

            - `"zimage-lora"`

            - `"zimage-turbo-lora"`

          - `parent?: boolean`

            Whether this input represents a parent asset to assign to the produced assets.
            Only available for `file` and `file_array` input types.

            For `file_array`, the parent asset is the first item in the array.

          - `placeholder?: string`

            Placeholder text for the input. Only available for 'string' input type.

          - `prompt?: boolean`

            Whether the input is a prompt. When true, displays as a text area with prompt spark feature.
            Only available for `string` input type.

          - `promptSpark?: boolean`

            Whether the input is used with prompt spark. Only available for `string` input type.

          - `ref?: Ref`

            The reference to another input or output of the same workflow.
            Must have at least one of node or conditional.

            - `conditional?: Array<string>`

              The conditional nodes to reference.
              If the conditional nodes are successful, the node will be successful.
              If the conditional nodes are skipped, the node will be skipped.
              Contains an array of node ids used to check the status of the nodes.

            - `equal?: string`

              This is the desired node output value if ref is an if/else node.

            - `name?: string`

              The name of the input or output to reference.
              If the type is 'workflow', the name is the name of the input of the workflow is required
              If the type is 'node', the name is not mandatory, except if you want all outputs of the node.
              To get all outputs of a node, you can use the name 'all'.

            - `node?: string`

              The node id or 'workflow' if the source is a workflow input.

          - `required?: Required`

            Set of rules that describes when this input is required:

            - `always`: Input is always required
            - `ifNotDefined`: Input is required when another specified input is not defined
            - `ifDefined`: Input is required when another specified input is defined
            - `conditional`: Input is required when other inputs have specific values

            By default, the input is not required.

            - `always?: boolean`

              Whether the input is always required

            - `conditional?: Conditional`

              Makes this input required when other inputs have one of the listed values

              - `values: unknown`

                The conditions to check:

                - Key: name of the input to check
                - Value: values of that input that satisfy the condition

              - `operator?: "and" | "or"`

                How the conditions combine: `and` (all must match) or `or` (any must match)

                - `"and"`

                - `"or"`

            - `ifDefined?: unknown`

              Makes this input required when another input is defined:

              - Key: name of the input that must be defined
              - Value: message to display when this input is required

            - `ifNotDefined?: unknown`

              Makes this input required when another input is not defined:

              - Key: name of the input that must be undefined
              - Value: message to display when this input is required

          - `step?: number`

            The step increment for numeric inputs. Only available for `number` input type.

          - `value?: unknown`

            The value of the input.
            This is the value of the input that will be used to run the node.
            Only available for flows managed by a WorkflowJob.

        - `items?: Array<string>`

          Statically-configured items for a List node, or the frozen candidate list
          of a UserSelection node. The values can be strings, numbers, or asset IDs.

        - `iterationIndex?: number`

          Zero-based index of the iteration this node copy belongs to.
          Set on dynamically-created copies of loop body nodes.

        - `jobId?: string`

          If the flow is part of a WorkflowJob, this is the jobId for the node.
          jobId is only available for nodes started. A node "Pending" for a running workflow job is not started.

        - `logic?: Logic`

          The logic of the node.
          Only available for logic nodes.

          - `cases?: Array<Case>`

            The cases of the logic.
            Only available for if/else nodes.

            - `condition: string`

            - `value: string`

          - `default?: string`

            The default case of the logic.
            Contains the id/output of the node to execute if no case is matched.
            Only available for if/else nodes.

          - `transform?: string`

            The transform of the logic.
            Only available for transform nodes.

        - `logicType?: "if-else"`

          The type of the logic for the node.
          Only available for logic nodes.

          - `"if-else"`

        - `loopBodyNodeIds?: Array<string>`

          IDs of the body template nodes that belong to this ForEach loop.
          At runtime these templates are cloned once per iteration and marked Skipped.
          Only available for ForEach nodes.

        - `loopNodeId?: string`

          ID of the ForEach node that spawned this iteration copy.
          Set on dynamically-created copies of loop body nodes.

        - `modelId?: string`

          The model id for the node. Mainly used for custom model tasks.

        - `output?: unknown`

          The output of the node.
          Only available for logic nodes.

        - `workflowId?: string`

          The workflow id for the node. Mainly used for workflow tasks.

      - `hint?: string`

        Actionable hint for the user explaining what went wrong and how to resolve it.

      - `input?: Record<string, unknown>`

        The inputs for the job

      - `output?: Record<string, unknown>`

        May contain the output of the job for specific custom models jobs.
        Only available for custom models which generate non-assets outputs.
        Example: LLM text results.

      - `outputModelId?: string`

        For voice-clone jobs: the ID of the model being trained.

      - `workflowId?: string`

        The workflow ID of the job if job is part of a workflow.

      - `workflowJobId?: string`

        The workflow job ID of the job if job is part of a workflow job.

    - `progress: number`

      Progress of the job (between 0 and 1)

    - `status: "canceled" | "failure" | "finalizing" | 5 more`

      The current status of the job

      - `"canceled"`

      - `"failure"`

      - `"finalizing"`

      - `"in-progress"`

      - `"pending"`

      - `"queued"`

      - `"success"`

      - `"warming-up"`

    - `statusHistory: Array<StatusHistory>`

      The history of the different statuses the job went through with the ISO string date
      of when the job reached each statuses.

      - `date: string`

      - `status: "canceled" | "failure" | "finalizing" | 5 more`

        - `"canceled"`

        - `"failure"`

        - `"finalizing"`

        - `"in-progress"`

        - `"pending"`

        - `"queued"`

        - `"success"`

        - `"warming-up"`

    - `updatedAt: string`

      The job last update date as an ISO string (example: "2023-02-03T11:19:41.579Z")

    - `authorId?: string`

      The author user ID (example: "dcf121faaa1a0a0bbbd9ca1b73d62aea")

    - `billing?: Billing`

      The billing of the job

      - `cuCost: number`

      - `cuDiscount: number`

      - `cuCostDetails?: CuCostDetails`

        Compute Units charged for the ADD-ONS of this job, per action — the fees
        paid on top of the generation itself, such as `quality-gate`.

        `cuCost` above is the main action alone, so the job's total is `cuCost`
        plus the values here.

        Two caveats when displaying it:

        - These are a remaining refundable balance, not a receipt: a job that
          failed or was cancelled has had its add-ons refunded, so they read 0
          while `cuCost` still shows the main action's original charge.
        - `ip-detection` is part of the shape but is never populated today: that
          fee is charged outside the job and reported once, as
          `ipDetection.creativeUnitsCharged`, in the response of the request that
          ran it.

        Absent when the job paid for no add-on.

        - `"ip-detection"?: number`

        - `"quality-gate"?: number`

      - `disableRefund?: boolean`

        When true, the credits charged for this job are not automatically
        refunded if the generation fails, because the model used does not
        support refund-on-failure. Absent or false means a failed generation is
        refunded as usual.

    - `ownerId?: string`

      The owner ID (example: "team_U3Qmc8PCdWXwAQJ4Dvw4tV6D")

### Example

```typescript
import Scenario from '@scenario-labs/sdk';

const client = new Scenario({
  apiKey: process.env['SCENARIO_SDK_API_KEY'], // This is the default and can be omitted
  apiSecret: process.env['SCENARIO_SDK_API_SECRET'], // This is the default and can be omitted
});

const response = await client.jobs.triggerAction('jobId');

console.log(response.job);
```

#### Response

```json
{
  "job": {
    "createdAt": "createdAt",
    "jobId": "jobId",
    "jobType": "assets-download",
    "metadata": {
      "assetIds": [
        "string"
      ],
      "error": "error",
      "flow": [
        {
          "id": "id",
          "status": "failure",
          "type": "custom-model",
          "assets": [
            {
              "assetId": "assetId",
              "url": "url"
            }
          ],
          "count": 0,
          "dependsOn": [
            "string"
          ],
          "includeOutputsInWorkflowJob": true,
          "inputs": [
            {
              "name": "name",
              "type": "boolean",
              "allowedValues": [
                {}
              ],
              "backgroundBehavior": "opaque",
              "color": true,
              "costImpact": true,
              "default": {},
              "description": "description",
              "group": "group",
              "hint": "hint",
              "inputs": [
                {
                  "foo": "bar"
                }
              ],
              "items": [
                [
                  {
                    "name": "name",
                    "type": "boolean",
                    "allowedValues": [
                      {}
                    ],
                    "backgroundBehavior": "opaque",
                    "color": true,
                    "costImpact": true,
                    "default": {},
                    "description": "description",
                    "group": "group",
                    "hint": "hint",
                    "inputs": [
                      {
                        "foo": "bar"
                      }
                    ],
                    "kind": "3d",
                    "label": "label",
                    "maskFrom": "maskFrom",
                    "max": 0,
                    "maxDuration": 0,
                    "maxLength": 0,
                    "maxSize": 0,
                    "min": 0,
                    "minDuration": 0,
                    "minLength": 0,
                    "modelTypes": [
                      "custom"
                    ],
                    "parent": true,
                    "placeholder": "placeholder",
                    "prompt": true,
                    "promptSpark": true,
                    "ref": {
                      "conditional": [
                        "string"
                      ],
                      "equal": "equal",
                      "name": "name",
                      "node": "node"
                    },
                    "required": {
                      "always": true,
                      "conditional": {
                        "values": {},
                        "operator": "and"
                      },
                      "ifDefined": {},
                      "ifNotDefined": {}
                    },
                    "step": 1,
                    "value": {}
                  }
                ]
              ],
              "kind": "3d",
              "label": "label",
              "maskFrom": "maskFrom",
              "max": 0,
              "maxDuration": 0,
              "maxLength": 0,
              "maxSize": 0,
              "min": 0,
              "minDuration": 0,
              "minLength": 0,
              "modelTypes": [
                "custom"
              ],
              "parent": true,
              "placeholder": "placeholder",
              "prompt": true,
              "promptSpark": true,
              "ref": {
                "conditional": [
                  "string"
                ],
                "equal": "equal",
                "name": "name",
                "node": "node"
              },
              "required": {
                "always": true,
                "conditional": {
                  "values": {},
                  "operator": "and"
                },
                "ifDefined": {},
                "ifNotDefined": {}
              },
              "step": 1,
              "value": {}
            }
          ],
          "items": [
            "string"
          ],
          "iterationIndex": 0,
          "jobId": "jobId",
          "logic": {
            "cases": [
              {
                "condition": "condition",
                "value": "value"
              }
            ],
            "default": "default",
            "transform": "transform"
          },
          "logicType": "if-else",
          "loopBodyNodeIds": [
            "string"
          ],
          "loopNodeId": "loopNodeId",
          "modelId": "modelId",
          "output": {},
          "workflowId": "workflowId"
        }
      ],
      "hint": "hint",
      "input": {
        "foo": "bar"
      },
      "output": {
        "foo": "bar"
      },
      "outputModelId": "outputModelId",
      "workflowId": "workflowId",
      "workflowJobId": "workflowJobId"
    },
    "progress": 0,
    "status": "canceled",
    "statusHistory": [
      {
        "date": "date",
        "status": "canceled"
      }
    ],
    "updatedAt": "updatedAt",
    "authorId": "authorId",
    "billing": {
      "cuCost": 0,
      "cuDiscount": 0,
      "cuCostDetails": {
        "ip-detection": 0,
        "quality-gate": 0
      },
      "disableRefund": true
    },
    "ownerId": "ownerId"
  }
}
```

## Domain Types

### Job List Response

- `JobListResponse`

  - `createdAt: string`

    The job creation date as an ISO string (example: "2023-02-03T11:19:41.579Z")

  - `jobId: string`

    The job ID (example: "job_ocZCnG1Df35XRL1QyCZSRxAG8")

  - `jobType: "assets-download" | "canvas-export" | "caption" | 37 more`

    The type of job

    - `"assets-download"`

    - `"canvas-export"`

    - `"caption"`

    - `"caption-llava"`

    - `"custom"`

    - `"describe-style"`

    - `"detection"`

    - `"embed"`

    - `"flux"`

    - `"flux-model-training"`

    - `"generate-prompt"`

    - `"image-generation"`

    - `"image-prompt-editing"`

    - `"inference"`

    - `"mesh-preview-rendering"`

    - `"model-download"`

    - `"model-import"`

    - `"model-training"`

    - `"musubi-model-training"`

    - `"openai-image-generation"`

    - `"patch-image"`

    - `"pixelate"`

    - `"reframe"`

    - `"remove-background"`

    - `"repaint"`

    - `"restyle"`

    - `"segment"`

    - `"skybox-3d"`

    - `"skybox-base-360"`

    - `"skybox-hdri"`

    - `"skybox-upscale-360"`

    - `"splat"`

    - `"texture"`

    - `"translate"`

    - `"upload"`

    - `"upscale"`

    - `"upscale-skybox"`

    - `"upscale-texture"`

    - `"vectorize"`

    - `"workflow"`

  - `metadata: Metadata`

    Metadata of the job with some additional information

    - `assetIds?: Array<string>`

      List of produced assets for this job

    - `error?: string | null`

      Eventual error for the job

    - `flow?: Array<Flow>`

      The flow of the job. Only available for workflow jobs.

      - `id: string`

        The id of the node.

      - `status: "failure" | "pending" | "processing" | 3 more`

        The status of the node. Only available for WorkflowJob nodes.

        - `"failure"`

        - `"pending"`

        - `"processing"`

        - `"rejected"`

        - `"skipped"`

        - `"success"`

      - `type: "custom-model" | "for-each" | "generate-prompt" | 8 more`

        The type of the job for the node.

        - `"custom-model"`

        - `"for-each"`

        - `"generate-prompt"`

        - `"list"`

        - `"logic"`

        - `"model"`

        - `"remove-background"`

        - `"transform"`

        - `"user-approval"`

        - `"user-selection"`

        - `"workflow"`

      - `assets?: Array<Asset>`

        List of produced assets for this node.

        - `assetId: string`

        - `url: string`

      - `count?: number`

        Fixed number of iterations for a ForEach node.
        When set, the loop runs exactly `count` times regardless of array input.
        When not set, the loop iterates over the resolved array input.
        Only available for ForEach nodes.

      - `dependsOn?: Array<string>`

        The nodes that this node depends on.
        Only available for nodes that have dependencies. Mainly used for user approval nodes.

      - `includeOutputsInWorkflowJob?: true`

        If true, the outputs of this node will be included in the workflow job's final output.
        Only applicable to producing nodes (custom-model, inference, etc.).
        By default, only last nodes (nodes not referenced by other nodes) contribute to outputs.
        Set this to true to also include intermediate nodes in the final output.
        Note: This should only be set to `true` or left undefined.

        - `true`

      - `inputs?: Array<Input>`

        The inputs of the node.
        For a user-selection node, the array input's `min`/`max` bound how many
        items the user may pick (defaults: 1 and 100); conditional connections may
        be present as additional inputs.

        - `name: string`

          The name that must be user to call the model through the API

        - `type: "boolean" | "file" | "file_array" | 7 more`

          The data type of the input

          - `"boolean"`

          - `"file"`

          - `"file_array"`

          - `"inputs_array"`

          - `"model"`

          - `"model_array"`

          - `"number"`

          - `"number_array"`

          - `"string"`

          - `"string_array"`

        - `allowedValues?: Array<unknown>`

          The allowed values for the input. For `string` or `number` types, creates a single-select
          dropdown.
          For `string_array` type, creates a multi-select dropdown.

        - `backgroundBehavior?: "opaque" | "transparent"`

          Specifies the background behavior for the input. Only available for `file` and `file_array`
          input types with kind `image`.

          - `"opaque"`

          - `"transparent"`

        - `color?: boolean`

          Whether the input is a color or not. Only available for `string` input type.

        - `costImpact?: boolean`

          Whether this input affects the model's cost calculation

        - `default?: unknown`

          The default value for the input

        - `description?: string`

          Help text displayed in the UI to provide additional information about the input

        - `group?: string`

          Used to visually group inputs together in the UI. Inputs with the same group value appear
          consecutively in the UI.

        - `hint?: string`

          Hint text displayed in the UI as a tooltip to guide the user

        - `inputs?: Array<Record<string, unknown>>`

          The list of inputs which form an object within a container array.
          All inputs are the same as the current object.
          This is only available for type inputs_array inputs.

        - `items?: Array<Array<Item>>`

          The configured items for inputs_array type inputs.
          Each item is an array of SubNodeInput that need ref/value resolution.
          Only available for inputs_array type.

          - `name: string`

            The name that must be user to call the model through the API

          - `type: "boolean" | "file" | "file_array" | 7 more`

            The data type of the input

            - `"boolean"`

            - `"file"`

            - `"file_array"`

            - `"inputs_array"`

            - `"model"`

            - `"model_array"`

            - `"number"`

            - `"number_array"`

            - `"string"`

            - `"string_array"`

          - `allowedValues?: Array<unknown>`

            The allowed values for the input. For `string` or `number` types, creates a single-select
            dropdown.
            For `string_array` type, creates a multi-select dropdown.

          - `backgroundBehavior?: "opaque" | "transparent"`

            Specifies the background behavior for the input. Only available for `file` and `file_array`
            input types with kind `image`.

            - `"opaque"`

            - `"transparent"`

          - `color?: boolean`

            Whether the input is a color or not. Only available for `string` input type.

          - `costImpact?: boolean`

            Whether this input affects the model's cost calculation

          - `default?: unknown`

            The default value for the input

          - `description?: string`

            Help text displayed in the UI to provide additional information about the input

          - `group?: string`

            Used to visually group inputs together in the UI. Inputs with the same group value appear
            consecutively in the UI.

          - `hint?: string`

            Hint text displayed in the UI as a tooltip to guide the user

          - `inputs?: Array<Record<string, unknown>>`

            The list of inputs which form an object within a container array.
            All inputs are the same as the current object.
            This is only available for type inputs_array inputs.

          - `kind?: "3d" | "audio" | "document" | 5 more`

            The asset kind of the input. Only taken into account for `file` and `file_array` input types.
            If model provides multiple kinds,
            the input will be not able to create the asset on the flight on API side with dataurl without data:kind, prefix
            `file` and `file_array` inputs always expose a kind: when a model does not declare one,
            `image` is returned, which is the kind used at generation time.

            - `"3d"`

            - `"audio"`

            - `"document"`

            - `"image"`

            - `"image-hdr"`

            - `"json"`

            - `"text"`

            - `"video"`

          - `label?: string`

            The label displayed in the UI for this input

          - `maskFrom?: string`

            The name of the file input field to use as the mask source

          - `max?: number`

            The maximum allowed value. Only available for `number` and `array` input types.

          - `maxDuration?: number`

            The maximum allowed media duration in seconds. Only applies to `file` and `file_array` input types
            for video and audio assets. Validated against `asset.properties.duration` at job creation time.

          - `maxLength?: number`

            The maximum allowed length for `string` and `model` inputs, in characters.
            For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
            ITEMS instead — the length of each item is not constrained.

          - `maxSize?: number`

            The maximum allowed file size in bytes. Only applies to `file` and `file_array` input types.
            Validated against `asset.properties.size` at job creation time.

          - `min?: number`

            The minimum allowed value. Only available for `number` and array input types.

          - `minDuration?: number`

            The minimum allowed media duration in seconds. Only applies to `file` and `file_array` input types
            for video and audio assets. Validated against `asset.properties.duration` at job creation time.

          - `minLength?: number`

            The minimum allowed length for `string` and `model` inputs, in characters.
            For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
            ITEMS instead — the length of each item is not constrained.

          - `modelTypes?: Array<"custom" | "elevenlabs-voice" | "flux.1" | 28 more>`

            The allowed model types for this input. Example: `["flux.1-lora"]`.
            Only available for `model_array` input type.

            - `"custom"`

            - `"elevenlabs-voice"`

            - `"flux.1"`

            - `"flux.1-composition"`

            - `"flux.1-kontext-dev"`

            - `"flux.1-kontext-lora"`

            - `"flux.1-krea-dev"`

            - `"flux.1-krea-lora"`

            - `"flux.1-lora"`

            - `"flux.1-pro"`

            - `"flux.1.1-pro-ultra"`

            - `"flux.2-dev-edit-lora"`

            - `"flux.2-dev-lora"`

            - `"flux.2-klein-4b-edit-lora"`

            - `"flux.2-klein-4b-lora"`

            - `"flux.2-klein-9b-edit-lora"`

            - `"flux.2-klein-9b-lora"`

            - `"flux.2-klein-base-4b-edit-lora"`

            - `"flux.2-klein-base-4b-lora"`

            - `"flux.2-klein-base-9b-edit-lora"`

            - `"flux.2-klein-base-9b-lora"`

            - `"flux1.1-pro"`

            - `"gpt-image-1"`

            - `"qwen-image-2512-lora"`

            - `"qwen-image-edit-2509-lora"`

            - `"qwen-image-edit-2511-lora"`

            - `"qwen-image-edit-lora"`

            - `"qwen-image-lora"`

            - `"zimage-de-turbo-lora"`

            - `"zimage-lora"`

            - `"zimage-turbo-lora"`

          - `parent?: boolean`

            Whether this input represents a parent asset to assign to the produced assets.
            Only available for `file` and `file_array` input types.

            For `file_array`, the parent asset is the first item in the array.

          - `placeholder?: string`

            Placeholder text for the input. Only available for 'string' input type.

          - `prompt?: boolean`

            Whether the input is a prompt. When true, displays as a text area with prompt spark feature.
            Only available for `string` input type.

          - `promptSpark?: boolean`

            Whether the input is used with prompt spark. Only available for `string` input type.

          - `ref?: Ref`

            The reference to another input or output of the same workflow.
            Must have at least one of node or conditional.

            - `conditional?: Array<string>`

              The conditional nodes to reference.
              If the conditional nodes are successful, the node will be successful.
              If the conditional nodes are skipped, the node will be skipped.
              Contains an array of node ids used to check the status of the nodes.

            - `equal?: string`

              This is the desired node output value if ref is an if/else node.

            - `name?: string`

              The name of the input or output to reference.
              If the type is 'workflow', the name is the name of the input of the workflow is required
              If the type is 'node', the name is not mandatory, except if you want all outputs of the node.
              To get all outputs of a node, you can use the name 'all'.

            - `node?: string`

              The node id or 'workflow' if the source is a workflow input.

          - `required?: Required`

            Set of rules that describes when this input is required:

            - `always`: Input is always required
            - `ifNotDefined`: Input is required when another specified input is not defined
            - `ifDefined`: Input is required when another specified input is defined
            - `conditional`: Input is required when other inputs have specific values

            By default, the input is not required.

            - `always?: boolean`

              Whether the input is always required

            - `conditional?: Conditional`

              Makes this input required when other inputs have one of the listed values

              - `values: unknown`

                The conditions to check:

                - Key: name of the input to check
                - Value: values of that input that satisfy the condition

              - `operator?: "and" | "or"`

                How the conditions combine: `and` (all must match) or `or` (any must match)

                - `"and"`

                - `"or"`

            - `ifDefined?: unknown`

              Makes this input required when another input is defined:

              - Key: name of the input that must be defined
              - Value: message to display when this input is required

            - `ifNotDefined?: unknown`

              Makes this input required when another input is not defined:

              - Key: name of the input that must be undefined
              - Value: message to display when this input is required

          - `step?: number`

            The step increment for numeric inputs. Only available for `number` input type.

          - `value?: unknown`

            The value of the input.
            This is the value of the input that will be used to run the node.
            Only available for flows managed by a WorkflowJob.

        - `kind?: "3d" | "audio" | "document" | 5 more`

          The asset kind of the input. Only taken into account for `file` and `file_array` input types.
          If model provides multiple kinds,
          the input will be not able to create the asset on the flight on API side with dataurl without data:kind, prefix
          `file` and `file_array` inputs always expose a kind: when a model does not declare one,
          `image` is returned, which is the kind used at generation time.

          - `"3d"`

          - `"audio"`

          - `"document"`

          - `"image"`

          - `"image-hdr"`

          - `"json"`

          - `"text"`

          - `"video"`

        - `label?: string`

          The label displayed in the UI for this input

        - `maskFrom?: string`

          The name of the file input field to use as the mask source

        - `max?: number`

          The maximum allowed value. Only available for `number` and `array` input types.

        - `maxDuration?: number`

          The maximum allowed media duration in seconds. Only applies to `file` and `file_array` input types
          for video and audio assets. Validated against `asset.properties.duration` at job creation time.

        - `maxLength?: number`

          The maximum allowed length for `string` and `model` inputs, in characters.
          For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
          ITEMS instead — the length of each item is not constrained.

        - `maxSize?: number`

          The maximum allowed file size in bytes. Only applies to `file` and `file_array` input types.
          Validated against `asset.properties.size` at job creation time.

        - `min?: number`

          The minimum allowed value. Only available for `number` and array input types.

        - `minDuration?: number`

          The minimum allowed media duration in seconds. Only applies to `file` and `file_array` input types
          for video and audio assets. Validated against `asset.properties.duration` at job creation time.

        - `minLength?: number`

          The minimum allowed length for `string` and `model` inputs, in characters.
          For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
          ITEMS instead — the length of each item is not constrained.

        - `modelTypes?: Array<"custom" | "elevenlabs-voice" | "flux.1" | 28 more>`

          The allowed model types for this input. Example: `["flux.1-lora"]`.
          Only available for `model_array` input type.

          - `"custom"`

          - `"elevenlabs-voice"`

          - `"flux.1"`

          - `"flux.1-composition"`

          - `"flux.1-kontext-dev"`

          - `"flux.1-kontext-lora"`

          - `"flux.1-krea-dev"`

          - `"flux.1-krea-lora"`

          - `"flux.1-lora"`

          - `"flux.1-pro"`

          - `"flux.1.1-pro-ultra"`

          - `"flux.2-dev-edit-lora"`

          - `"flux.2-dev-lora"`

          - `"flux.2-klein-4b-edit-lora"`

          - `"flux.2-klein-4b-lora"`

          - `"flux.2-klein-9b-edit-lora"`

          - `"flux.2-klein-9b-lora"`

          - `"flux.2-klein-base-4b-edit-lora"`

          - `"flux.2-klein-base-4b-lora"`

          - `"flux.2-klein-base-9b-edit-lora"`

          - `"flux.2-klein-base-9b-lora"`

          - `"flux1.1-pro"`

          - `"gpt-image-1"`

          - `"qwen-image-2512-lora"`

          - `"qwen-image-edit-2509-lora"`

          - `"qwen-image-edit-2511-lora"`

          - `"qwen-image-edit-lora"`

          - `"qwen-image-lora"`

          - `"zimage-de-turbo-lora"`

          - `"zimage-lora"`

          - `"zimage-turbo-lora"`

        - `parent?: boolean`

          Whether this input represents a parent asset to assign to the produced assets.
          Only available for `file` and `file_array` input types.

          For `file_array`, the parent asset is the first item in the array.

        - `placeholder?: string`

          Placeholder text for the input. Only available for 'string' input type.

        - `prompt?: boolean`

          Whether the input is a prompt. When true, displays as a text area with prompt spark feature.
          Only available for `string` input type.

        - `promptSpark?: boolean`

          Whether the input is used with prompt spark. Only available for `string` input type.

        - `ref?: Ref`

          The reference to another input or output of the same workflow.
          Must have at least one of node or conditional.

          - `conditional?: Array<string>`

            The conditional nodes to reference.
            If the conditional nodes are successful, the node will be successful.
            If the conditional nodes are skipped, the node will be skipped.
            Contains an array of node ids used to check the status of the nodes.

          - `equal?: string`

            This is the desired node output value if ref is an if/else node.

          - `name?: string`

            The name of the input or output to reference.
            If the type is 'workflow', the name is the name of the input of the workflow is required
            If the type is 'node', the name is not mandatory, except if you want all outputs of the node.
            To get all outputs of a node, you can use the name 'all'.

          - `node?: string`

            The node id or 'workflow' if the source is a workflow input.

        - `required?: Required`

          Set of rules that describes when this input is required:

          - `always`: Input is always required
          - `ifNotDefined`: Input is required when another specified input is not defined
          - `ifDefined`: Input is required when another specified input is defined
          - `conditional`: Input is required when other inputs have specific values

          By default, the input is not required.

          - `always?: boolean`

            Whether the input is always required

          - `conditional?: Conditional`

            Makes this input required when other inputs have one of the listed values

            - `values: unknown`

              The conditions to check:

              - Key: name of the input to check
              - Value: values of that input that satisfy the condition

            - `operator?: "and" | "or"`

              How the conditions combine: `and` (all must match) or `or` (any must match)

              - `"and"`

              - `"or"`

          - `ifDefined?: unknown`

            Makes this input required when another input is defined:

            - Key: name of the input that must be defined
            - Value: message to display when this input is required

          - `ifNotDefined?: unknown`

            Makes this input required when another input is not defined:

            - Key: name of the input that must be undefined
            - Value: message to display when this input is required

        - `step?: number`

          The step increment for numeric inputs. Only available for `number` input type.

        - `value?: unknown`

          The value of the input.
          This is the value of the input that will be used to run the node.
          Only available for flows managed by a WorkflowJob.

      - `items?: Array<string>`

        Statically-configured items for a List node, or the frozen candidate list
        of a UserSelection node. The values can be strings, numbers, or asset IDs.

      - `iterationIndex?: number`

        Zero-based index of the iteration this node copy belongs to.
        Set on dynamically-created copies of loop body nodes.

      - `jobId?: string`

        If the flow is part of a WorkflowJob, this is the jobId for the node.
        jobId is only available for nodes started. A node "Pending" for a running workflow job is not started.

      - `logic?: Logic`

        The logic of the node.
        Only available for logic nodes.

        - `cases?: Array<Case>`

          The cases of the logic.
          Only available for if/else nodes.

          - `condition: string`

          - `value: string`

        - `default?: string`

          The default case of the logic.
          Contains the id/output of the node to execute if no case is matched.
          Only available for if/else nodes.

        - `transform?: string`

          The transform of the logic.
          Only available for transform nodes.

      - `logicType?: "if-else"`

        The type of the logic for the node.
        Only available for logic nodes.

        - `"if-else"`

      - `loopBodyNodeIds?: Array<string>`

        IDs of the body template nodes that belong to this ForEach loop.
        At runtime these templates are cloned once per iteration and marked Skipped.
        Only available for ForEach nodes.

      - `loopNodeId?: string`

        ID of the ForEach node that spawned this iteration copy.
        Set on dynamically-created copies of loop body nodes.

      - `modelId?: string`

        The model id for the node. Mainly used for custom model tasks.

      - `output?: unknown`

        The output of the node.
        Only available for logic nodes.

      - `workflowId?: string`

        The workflow id for the node. Mainly used for workflow tasks.

    - `hint?: string`

      Actionable hint for the user explaining what went wrong and how to resolve it.

    - `input?: Record<string, unknown>`

      The inputs for the job

    - `output?: Record<string, unknown>`

      May contain the output of the job for specific custom models jobs.
      Only available for custom models which generate non-assets outputs.
      Example: LLM text results.

    - `outputModelId?: string`

      For voice-clone jobs: the ID of the model being trained.

    - `workflowId?: string`

      The workflow ID of the job if job is part of a workflow.

    - `workflowJobId?: string`

      The workflow job ID of the job if job is part of a workflow job.

  - `progress: number`

    Progress of the job (between 0 and 1)

  - `status: "canceled" | "failure" | "finalizing" | 5 more`

    The current status of the job

    - `"canceled"`

    - `"failure"`

    - `"finalizing"`

    - `"in-progress"`

    - `"pending"`

    - `"queued"`

    - `"success"`

    - `"warming-up"`

  - `statusHistory: Array<StatusHistory>`

    The history of the different statuses the job went through with the ISO string date
    of when the job reached each statuses.

    - `date: string`

    - `status: "canceled" | "failure" | "finalizing" | 5 more`

      - `"canceled"`

      - `"failure"`

      - `"finalizing"`

      - `"in-progress"`

      - `"pending"`

      - `"queued"`

      - `"success"`

      - `"warming-up"`

  - `updatedAt: string`

    The job last update date as an ISO string (example: "2023-02-03T11:19:41.579Z")

  - `authorId?: string`

    The author user ID (example: "dcf121faaa1a0a0bbbd9ca1b73d62aea")

  - `billing?: Billing`

    The billing of the job

    - `cuCost: number`

    - `cuDiscount: number`

    - `cuCostDetails?: CuCostDetails`

      Compute Units charged for the ADD-ONS of this job, per action — the fees
      paid on top of the generation itself, such as `quality-gate`.

      `cuCost` above is the main action alone, so the job's total is `cuCost`
      plus the values here.

      Two caveats when displaying it:

      - These are a remaining refundable balance, not a receipt: a job that
        failed or was cancelled has had its add-ons refunded, so they read 0
        while `cuCost` still shows the main action's original charge.
      - `ip-detection` is part of the shape but is never populated today: that
        fee is charged outside the job and reported once, as
        `ipDetection.creativeUnitsCharged`, in the response of the request that
        ran it.

      Absent when the job paid for no add-on.

      - `"ip-detection"?: number`

      - `"quality-gate"?: number`

    - `disableRefund?: boolean`

      When true, the credits charged for this job are not automatically
      refunded if the generation fails, because the model used does not
      support refund-on-failure. Absent or false means a failed generation is
      refunded as usual.

  - `ownerId?: string`

    The owner ID (example: "team_U3Qmc8PCdWXwAQJ4Dvw4tV6D")

### Job Retrieve Response

- `JobRetrieveResponse`

  - `job: Job`

    - `createdAt: string`

      The job creation date as an ISO string (example: "2023-02-03T11:19:41.579Z")

    - `jobId: string`

      The job ID (example: "job_ocZCnG1Df35XRL1QyCZSRxAG8")

    - `jobType: "assets-download" | "canvas-export" | "caption" | 37 more`

      The type of job

      - `"assets-download"`

      - `"canvas-export"`

      - `"caption"`

      - `"caption-llava"`

      - `"custom"`

      - `"describe-style"`

      - `"detection"`

      - `"embed"`

      - `"flux"`

      - `"flux-model-training"`

      - `"generate-prompt"`

      - `"image-generation"`

      - `"image-prompt-editing"`

      - `"inference"`

      - `"mesh-preview-rendering"`

      - `"model-download"`

      - `"model-import"`

      - `"model-training"`

      - `"musubi-model-training"`

      - `"openai-image-generation"`

      - `"patch-image"`

      - `"pixelate"`

      - `"reframe"`

      - `"remove-background"`

      - `"repaint"`

      - `"restyle"`

      - `"segment"`

      - `"skybox-3d"`

      - `"skybox-base-360"`

      - `"skybox-hdri"`

      - `"skybox-upscale-360"`

      - `"splat"`

      - `"texture"`

      - `"translate"`

      - `"upload"`

      - `"upscale"`

      - `"upscale-skybox"`

      - `"upscale-texture"`

      - `"vectorize"`

      - `"workflow"`

    - `metadata: Metadata`

      Metadata of the job with some additional information

      - `assetIds?: Array<string>`

        List of produced assets for this job

      - `error?: string | null`

        Eventual error for the job

      - `flow?: Array<Flow>`

        The flow of the job. Only available for workflow jobs.

        - `id: string`

          The id of the node.

        - `status: "failure" | "pending" | "processing" | 3 more`

          The status of the node. Only available for WorkflowJob nodes.

          - `"failure"`

          - `"pending"`

          - `"processing"`

          - `"rejected"`

          - `"skipped"`

          - `"success"`

        - `type: "custom-model" | "for-each" | "generate-prompt" | 8 more`

          The type of the job for the node.

          - `"custom-model"`

          - `"for-each"`

          - `"generate-prompt"`

          - `"list"`

          - `"logic"`

          - `"model"`

          - `"remove-background"`

          - `"transform"`

          - `"user-approval"`

          - `"user-selection"`

          - `"workflow"`

        - `assets?: Array<Asset>`

          List of produced assets for this node.

          - `assetId: string`

          - `url: string`

        - `count?: number`

          Fixed number of iterations for a ForEach node.
          When set, the loop runs exactly `count` times regardless of array input.
          When not set, the loop iterates over the resolved array input.
          Only available for ForEach nodes.

        - `dependsOn?: Array<string>`

          The nodes that this node depends on.
          Only available for nodes that have dependencies. Mainly used for user approval nodes.

        - `includeOutputsInWorkflowJob?: true`

          If true, the outputs of this node will be included in the workflow job's final output.
          Only applicable to producing nodes (custom-model, inference, etc.).
          By default, only last nodes (nodes not referenced by other nodes) contribute to outputs.
          Set this to true to also include intermediate nodes in the final output.
          Note: This should only be set to `true` or left undefined.

          - `true`

        - `inputs?: Array<Input>`

          The inputs of the node.
          For a user-selection node, the array input's `min`/`max` bound how many
          items the user may pick (defaults: 1 and 100); conditional connections may
          be present as additional inputs.

          - `name: string`

            The name that must be user to call the model through the API

          - `type: "boolean" | "file" | "file_array" | 7 more`

            The data type of the input

            - `"boolean"`

            - `"file"`

            - `"file_array"`

            - `"inputs_array"`

            - `"model"`

            - `"model_array"`

            - `"number"`

            - `"number_array"`

            - `"string"`

            - `"string_array"`

          - `allowedValues?: Array<unknown>`

            The allowed values for the input. For `string` or `number` types, creates a single-select
            dropdown.
            For `string_array` type, creates a multi-select dropdown.

          - `backgroundBehavior?: "opaque" | "transparent"`

            Specifies the background behavior for the input. Only available for `file` and `file_array`
            input types with kind `image`.

            - `"opaque"`

            - `"transparent"`

          - `color?: boolean`

            Whether the input is a color or not. Only available for `string` input type.

          - `costImpact?: boolean`

            Whether this input affects the model's cost calculation

          - `default?: unknown`

            The default value for the input

          - `description?: string`

            Help text displayed in the UI to provide additional information about the input

          - `group?: string`

            Used to visually group inputs together in the UI. Inputs with the same group value appear
            consecutively in the UI.

          - `hint?: string`

            Hint text displayed in the UI as a tooltip to guide the user

          - `inputs?: Array<Record<string, unknown>>`

            The list of inputs which form an object within a container array.
            All inputs are the same as the current object.
            This is only available for type inputs_array inputs.

          - `items?: Array<Array<Item>>`

            The configured items for inputs_array type inputs.
            Each item is an array of SubNodeInput that need ref/value resolution.
            Only available for inputs_array type.

            - `name: string`

              The name that must be user to call the model through the API

            - `type: "boolean" | "file" | "file_array" | 7 more`

              The data type of the input

              - `"boolean"`

              - `"file"`

              - `"file_array"`

              - `"inputs_array"`

              - `"model"`

              - `"model_array"`

              - `"number"`

              - `"number_array"`

              - `"string"`

              - `"string_array"`

            - `allowedValues?: Array<unknown>`

              The allowed values for the input. For `string` or `number` types, creates a single-select
              dropdown.
              For `string_array` type, creates a multi-select dropdown.

            - `backgroundBehavior?: "opaque" | "transparent"`

              Specifies the background behavior for the input. Only available for `file` and `file_array`
              input types with kind `image`.

              - `"opaque"`

              - `"transparent"`

            - `color?: boolean`

              Whether the input is a color or not. Only available for `string` input type.

            - `costImpact?: boolean`

              Whether this input affects the model's cost calculation

            - `default?: unknown`

              The default value for the input

            - `description?: string`

              Help text displayed in the UI to provide additional information about the input

            - `group?: string`

              Used to visually group inputs together in the UI. Inputs with the same group value appear
              consecutively in the UI.

            - `hint?: string`

              Hint text displayed in the UI as a tooltip to guide the user

            - `inputs?: Array<Record<string, unknown>>`

              The list of inputs which form an object within a container array.
              All inputs are the same as the current object.
              This is only available for type inputs_array inputs.

            - `kind?: "3d" | "audio" | "document" | 5 more`

              The asset kind of the input. Only taken into account for `file` and `file_array` input types.
              If model provides multiple kinds,
              the input will be not able to create the asset on the flight on API side with dataurl without data:kind, prefix
              `file` and `file_array` inputs always expose a kind: when a model does not declare one,
              `image` is returned, which is the kind used at generation time.

              - `"3d"`

              - `"audio"`

              - `"document"`

              - `"image"`

              - `"image-hdr"`

              - `"json"`

              - `"text"`

              - `"video"`

            - `label?: string`

              The label displayed in the UI for this input

            - `maskFrom?: string`

              The name of the file input field to use as the mask source

            - `max?: number`

              The maximum allowed value. Only available for `number` and `array` input types.

            - `maxDuration?: number`

              The maximum allowed media duration in seconds. Only applies to `file` and `file_array` input types
              for video and audio assets. Validated against `asset.properties.duration` at job creation time.

            - `maxLength?: number`

              The maximum allowed length for `string` and `model` inputs, in characters.
              For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
              ITEMS instead — the length of each item is not constrained.

            - `maxSize?: number`

              The maximum allowed file size in bytes. Only applies to `file` and `file_array` input types.
              Validated against `asset.properties.size` at job creation time.

            - `min?: number`

              The minimum allowed value. Only available for `number` and array input types.

            - `minDuration?: number`

              The minimum allowed media duration in seconds. Only applies to `file` and `file_array` input types
              for video and audio assets. Validated against `asset.properties.duration` at job creation time.

            - `minLength?: number`

              The minimum allowed length for `string` and `model` inputs, in characters.
              For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
              ITEMS instead — the length of each item is not constrained.

            - `modelTypes?: Array<"custom" | "elevenlabs-voice" | "flux.1" | 28 more>`

              The allowed model types for this input. Example: `["flux.1-lora"]`.
              Only available for `model_array` input type.

              - `"custom"`

              - `"elevenlabs-voice"`

              - `"flux.1"`

              - `"flux.1-composition"`

              - `"flux.1-kontext-dev"`

              - `"flux.1-kontext-lora"`

              - `"flux.1-krea-dev"`

              - `"flux.1-krea-lora"`

              - `"flux.1-lora"`

              - `"flux.1-pro"`

              - `"flux.1.1-pro-ultra"`

              - `"flux.2-dev-edit-lora"`

              - `"flux.2-dev-lora"`

              - `"flux.2-klein-4b-edit-lora"`

              - `"flux.2-klein-4b-lora"`

              - `"flux.2-klein-9b-edit-lora"`

              - `"flux.2-klein-9b-lora"`

              - `"flux.2-klein-base-4b-edit-lora"`

              - `"flux.2-klein-base-4b-lora"`

              - `"flux.2-klein-base-9b-edit-lora"`

              - `"flux.2-klein-base-9b-lora"`

              - `"flux1.1-pro"`

              - `"gpt-image-1"`

              - `"qwen-image-2512-lora"`

              - `"qwen-image-edit-2509-lora"`

              - `"qwen-image-edit-2511-lora"`

              - `"qwen-image-edit-lora"`

              - `"qwen-image-lora"`

              - `"zimage-de-turbo-lora"`

              - `"zimage-lora"`

              - `"zimage-turbo-lora"`

            - `parent?: boolean`

              Whether this input represents a parent asset to assign to the produced assets.
              Only available for `file` and `file_array` input types.

              For `file_array`, the parent asset is the first item in the array.

            - `placeholder?: string`

              Placeholder text for the input. Only available for 'string' input type.

            - `prompt?: boolean`

              Whether the input is a prompt. When true, displays as a text area with prompt spark feature.
              Only available for `string` input type.

            - `promptSpark?: boolean`

              Whether the input is used with prompt spark. Only available for `string` input type.

            - `ref?: Ref`

              The reference to another input or output of the same workflow.
              Must have at least one of node or conditional.

              - `conditional?: Array<string>`

                The conditional nodes to reference.
                If the conditional nodes are successful, the node will be successful.
                If the conditional nodes are skipped, the node will be skipped.
                Contains an array of node ids used to check the status of the nodes.

              - `equal?: string`

                This is the desired node output value if ref is an if/else node.

              - `name?: string`

                The name of the input or output to reference.
                If the type is 'workflow', the name is the name of the input of the workflow is required
                If the type is 'node', the name is not mandatory, except if you want all outputs of the node.
                To get all outputs of a node, you can use the name 'all'.

              - `node?: string`

                The node id or 'workflow' if the source is a workflow input.

            - `required?: Required`

              Set of rules that describes when this input is required:

              - `always`: Input is always required
              - `ifNotDefined`: Input is required when another specified input is not defined
              - `ifDefined`: Input is required when another specified input is defined
              - `conditional`: Input is required when other inputs have specific values

              By default, the input is not required.

              - `always?: boolean`

                Whether the input is always required

              - `conditional?: Conditional`

                Makes this input required when other inputs have one of the listed values

                - `values: unknown`

                  The conditions to check:

                  - Key: name of the input to check
                  - Value: values of that input that satisfy the condition

                - `operator?: "and" | "or"`

                  How the conditions combine: `and` (all must match) or `or` (any must match)

                  - `"and"`

                  - `"or"`

              - `ifDefined?: unknown`

                Makes this input required when another input is defined:

                - Key: name of the input that must be defined
                - Value: message to display when this input is required

              - `ifNotDefined?: unknown`

                Makes this input required when another input is not defined:

                - Key: name of the input that must be undefined
                - Value: message to display when this input is required

            - `step?: number`

              The step increment for numeric inputs. Only available for `number` input type.

            - `value?: unknown`

              The value of the input.
              This is the value of the input that will be used to run the node.
              Only available for flows managed by a WorkflowJob.

          - `kind?: "3d" | "audio" | "document" | 5 more`

            The asset kind of the input. Only taken into account for `file` and `file_array` input types.
            If model provides multiple kinds,
            the input will be not able to create the asset on the flight on API side with dataurl without data:kind, prefix
            `file` and `file_array` inputs always expose a kind: when a model does not declare one,
            `image` is returned, which is the kind used at generation time.

            - `"3d"`

            - `"audio"`

            - `"document"`

            - `"image"`

            - `"image-hdr"`

            - `"json"`

            - `"text"`

            - `"video"`

          - `label?: string`

            The label displayed in the UI for this input

          - `maskFrom?: string`

            The name of the file input field to use as the mask source

          - `max?: number`

            The maximum allowed value. Only available for `number` and `array` input types.

          - `maxDuration?: number`

            The maximum allowed media duration in seconds. Only applies to `file` and `file_array` input types
            for video and audio assets. Validated against `asset.properties.duration` at job creation time.

          - `maxLength?: number`

            The maximum allowed length for `string` and `model` inputs, in characters.
            For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
            ITEMS instead — the length of each item is not constrained.

          - `maxSize?: number`

            The maximum allowed file size in bytes. Only applies to `file` and `file_array` input types.
            Validated against `asset.properties.size` at job creation time.

          - `min?: number`

            The minimum allowed value. Only available for `number` and array input types.

          - `minDuration?: number`

            The minimum allowed media duration in seconds. Only applies to `file` and `file_array` input types
            for video and audio assets. Validated against `asset.properties.duration` at job creation time.

          - `minLength?: number`

            The minimum allowed length for `string` and `model` inputs, in characters.
            For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
            ITEMS instead — the length of each item is not constrained.

          - `modelTypes?: Array<"custom" | "elevenlabs-voice" | "flux.1" | 28 more>`

            The allowed model types for this input. Example: `["flux.1-lora"]`.
            Only available for `model_array` input type.

            - `"custom"`

            - `"elevenlabs-voice"`

            - `"flux.1"`

            - `"flux.1-composition"`

            - `"flux.1-kontext-dev"`

            - `"flux.1-kontext-lora"`

            - `"flux.1-krea-dev"`

            - `"flux.1-krea-lora"`

            - `"flux.1-lora"`

            - `"flux.1-pro"`

            - `"flux.1.1-pro-ultra"`

            - `"flux.2-dev-edit-lora"`

            - `"flux.2-dev-lora"`

            - `"flux.2-klein-4b-edit-lora"`

            - `"flux.2-klein-4b-lora"`

            - `"flux.2-klein-9b-edit-lora"`

            - `"flux.2-klein-9b-lora"`

            - `"flux.2-klein-base-4b-edit-lora"`

            - `"flux.2-klein-base-4b-lora"`

            - `"flux.2-klein-base-9b-edit-lora"`

            - `"flux.2-klein-base-9b-lora"`

            - `"flux1.1-pro"`

            - `"gpt-image-1"`

            - `"qwen-image-2512-lora"`

            - `"qwen-image-edit-2509-lora"`

            - `"qwen-image-edit-2511-lora"`

            - `"qwen-image-edit-lora"`

            - `"qwen-image-lora"`

            - `"zimage-de-turbo-lora"`

            - `"zimage-lora"`

            - `"zimage-turbo-lora"`

          - `parent?: boolean`

            Whether this input represents a parent asset to assign to the produced assets.
            Only available for `file` and `file_array` input types.

            For `file_array`, the parent asset is the first item in the array.

          - `placeholder?: string`

            Placeholder text for the input. Only available for 'string' input type.

          - `prompt?: boolean`

            Whether the input is a prompt. When true, displays as a text area with prompt spark feature.
            Only available for `string` input type.

          - `promptSpark?: boolean`

            Whether the input is used with prompt spark. Only available for `string` input type.

          - `ref?: Ref`

            The reference to another input or output of the same workflow.
            Must have at least one of node or conditional.

            - `conditional?: Array<string>`

              The conditional nodes to reference.
              If the conditional nodes are successful, the node will be successful.
              If the conditional nodes are skipped, the node will be skipped.
              Contains an array of node ids used to check the status of the nodes.

            - `equal?: string`

              This is the desired node output value if ref is an if/else node.

            - `name?: string`

              The name of the input or output to reference.
              If the type is 'workflow', the name is the name of the input of the workflow is required
              If the type is 'node', the name is not mandatory, except if you want all outputs of the node.
              To get all outputs of a node, you can use the name 'all'.

            - `node?: string`

              The node id or 'workflow' if the source is a workflow input.

          - `required?: Required`

            Set of rules that describes when this input is required:

            - `always`: Input is always required
            - `ifNotDefined`: Input is required when another specified input is not defined
            - `ifDefined`: Input is required when another specified input is defined
            - `conditional`: Input is required when other inputs have specific values

            By default, the input is not required.

            - `always?: boolean`

              Whether the input is always required

            - `conditional?: Conditional`

              Makes this input required when other inputs have one of the listed values

              - `values: unknown`

                The conditions to check:

                - Key: name of the input to check
                - Value: values of that input that satisfy the condition

              - `operator?: "and" | "or"`

                How the conditions combine: `and` (all must match) or `or` (any must match)

                - `"and"`

                - `"or"`

            - `ifDefined?: unknown`

              Makes this input required when another input is defined:

              - Key: name of the input that must be defined
              - Value: message to display when this input is required

            - `ifNotDefined?: unknown`

              Makes this input required when another input is not defined:

              - Key: name of the input that must be undefined
              - Value: message to display when this input is required

          - `step?: number`

            The step increment for numeric inputs. Only available for `number` input type.

          - `value?: unknown`

            The value of the input.
            This is the value of the input that will be used to run the node.
            Only available for flows managed by a WorkflowJob.

        - `items?: Array<string>`

          Statically-configured items for a List node, or the frozen candidate list
          of a UserSelection node. The values can be strings, numbers, or asset IDs.

        - `iterationIndex?: number`

          Zero-based index of the iteration this node copy belongs to.
          Set on dynamically-created copies of loop body nodes.

        - `jobId?: string`

          If the flow is part of a WorkflowJob, this is the jobId for the node.
          jobId is only available for nodes started. A node "Pending" for a running workflow job is not started.

        - `logic?: Logic`

          The logic of the node.
          Only available for logic nodes.

          - `cases?: Array<Case>`

            The cases of the logic.
            Only available for if/else nodes.

            - `condition: string`

            - `value: string`

          - `default?: string`

            The default case of the logic.
            Contains the id/output of the node to execute if no case is matched.
            Only available for if/else nodes.

          - `transform?: string`

            The transform of the logic.
            Only available for transform nodes.

        - `logicType?: "if-else"`

          The type of the logic for the node.
          Only available for logic nodes.

          - `"if-else"`

        - `loopBodyNodeIds?: Array<string>`

          IDs of the body template nodes that belong to this ForEach loop.
          At runtime these templates are cloned once per iteration and marked Skipped.
          Only available for ForEach nodes.

        - `loopNodeId?: string`

          ID of the ForEach node that spawned this iteration copy.
          Set on dynamically-created copies of loop body nodes.

        - `modelId?: string`

          The model id for the node. Mainly used for custom model tasks.

        - `output?: unknown`

          The output of the node.
          Only available for logic nodes.

        - `workflowId?: string`

          The workflow id for the node. Mainly used for workflow tasks.

      - `hint?: string`

        Actionable hint for the user explaining what went wrong and how to resolve it.

      - `input?: Record<string, unknown>`

        The inputs for the job

      - `output?: Record<string, unknown>`

        May contain the output of the job for specific custom models jobs.
        Only available for custom models which generate non-assets outputs.
        Example: LLM text results.

      - `outputModelId?: string`

        For voice-clone jobs: the ID of the model being trained.

      - `workflowId?: string`

        The workflow ID of the job if job is part of a workflow.

      - `workflowJobId?: string`

        The workflow job ID of the job if job is part of a workflow job.

    - `progress: number`

      Progress of the job (between 0 and 1)

    - `status: "canceled" | "failure" | "finalizing" | 5 more`

      The current status of the job

      - `"canceled"`

      - `"failure"`

      - `"finalizing"`

      - `"in-progress"`

      - `"pending"`

      - `"queued"`

      - `"success"`

      - `"warming-up"`

    - `statusHistory: Array<StatusHistory>`

      The history of the different statuses the job went through with the ISO string date
      of when the job reached each statuses.

      - `date: string`

      - `status: "canceled" | "failure" | "finalizing" | 5 more`

        - `"canceled"`

        - `"failure"`

        - `"finalizing"`

        - `"in-progress"`

        - `"pending"`

        - `"queued"`

        - `"success"`

        - `"warming-up"`

    - `updatedAt: string`

      The job last update date as an ISO string (example: "2023-02-03T11:19:41.579Z")

    - `authorId?: string`

      The author user ID (example: "dcf121faaa1a0a0bbbd9ca1b73d62aea")

    - `billing?: Billing`

      The billing of the job

      - `cuCost: number`

      - `cuDiscount: number`

      - `cuCostDetails?: CuCostDetails`

        Compute Units charged for the ADD-ONS of this job, per action — the fees
        paid on top of the generation itself, such as `quality-gate`.

        `cuCost` above is the main action alone, so the job's total is `cuCost`
        plus the values here.

        Two caveats when displaying it:

        - These are a remaining refundable balance, not a receipt: a job that
          failed or was cancelled has had its add-ons refunded, so they read 0
          while `cuCost` still shows the main action's original charge.
        - `ip-detection` is part of the shape but is never populated today: that
          fee is charged outside the job and reported once, as
          `ipDetection.creativeUnitsCharged`, in the response of the request that
          ran it.

        Absent when the job paid for no add-on.

        - `"ip-detection"?: number`

        - `"quality-gate"?: number`

      - `disableRefund?: boolean`

        When true, the credits charged for this job are not automatically
        refunded if the generation fails, because the model used does not
        support refund-on-failure. Absent or false means a failed generation is
        refunded as usual.

    - `ownerId?: string`

      The owner ID (example: "team_U3Qmc8PCdWXwAQJ4Dvw4tV6D")

### Job Trigger Action Response

- `JobTriggerActionResponse`

  - `job: Job`

    - `createdAt: string`

      The job creation date as an ISO string (example: "2023-02-03T11:19:41.579Z")

    - `jobId: string`

      The job ID (example: "job_ocZCnG1Df35XRL1QyCZSRxAG8")

    - `jobType: "assets-download" | "canvas-export" | "caption" | 37 more`

      The type of job

      - `"assets-download"`

      - `"canvas-export"`

      - `"caption"`

      - `"caption-llava"`

      - `"custom"`

      - `"describe-style"`

      - `"detection"`

      - `"embed"`

      - `"flux"`

      - `"flux-model-training"`

      - `"generate-prompt"`

      - `"image-generation"`

      - `"image-prompt-editing"`

      - `"inference"`

      - `"mesh-preview-rendering"`

      - `"model-download"`

      - `"model-import"`

      - `"model-training"`

      - `"musubi-model-training"`

      - `"openai-image-generation"`

      - `"patch-image"`

      - `"pixelate"`

      - `"reframe"`

      - `"remove-background"`

      - `"repaint"`

      - `"restyle"`

      - `"segment"`

      - `"skybox-3d"`

      - `"skybox-base-360"`

      - `"skybox-hdri"`

      - `"skybox-upscale-360"`

      - `"splat"`

      - `"texture"`

      - `"translate"`

      - `"upload"`

      - `"upscale"`

      - `"upscale-skybox"`

      - `"upscale-texture"`

      - `"vectorize"`

      - `"workflow"`

    - `metadata: Metadata`

      Metadata of the job with some additional information

      - `assetIds?: Array<string>`

        List of produced assets for this job

      - `error?: string | null`

        Eventual error for the job

      - `flow?: Array<Flow>`

        The flow of the job. Only available for workflow jobs.

        - `id: string`

          The id of the node.

        - `status: "failure" | "pending" | "processing" | 3 more`

          The status of the node. Only available for WorkflowJob nodes.

          - `"failure"`

          - `"pending"`

          - `"processing"`

          - `"rejected"`

          - `"skipped"`

          - `"success"`

        - `type: "custom-model" | "for-each" | "generate-prompt" | 8 more`

          The type of the job for the node.

          - `"custom-model"`

          - `"for-each"`

          - `"generate-prompt"`

          - `"list"`

          - `"logic"`

          - `"model"`

          - `"remove-background"`

          - `"transform"`

          - `"user-approval"`

          - `"user-selection"`

          - `"workflow"`

        - `assets?: Array<Asset>`

          List of produced assets for this node.

          - `assetId: string`

          - `url: string`

        - `count?: number`

          Fixed number of iterations for a ForEach node.
          When set, the loop runs exactly `count` times regardless of array input.
          When not set, the loop iterates over the resolved array input.
          Only available for ForEach nodes.

        - `dependsOn?: Array<string>`

          The nodes that this node depends on.
          Only available for nodes that have dependencies. Mainly used for user approval nodes.

        - `includeOutputsInWorkflowJob?: true`

          If true, the outputs of this node will be included in the workflow job's final output.
          Only applicable to producing nodes (custom-model, inference, etc.).
          By default, only last nodes (nodes not referenced by other nodes) contribute to outputs.
          Set this to true to also include intermediate nodes in the final output.
          Note: This should only be set to `true` or left undefined.

          - `true`

        - `inputs?: Array<Input>`

          The inputs of the node.
          For a user-selection node, the array input's `min`/`max` bound how many
          items the user may pick (defaults: 1 and 100); conditional connections may
          be present as additional inputs.

          - `name: string`

            The name that must be user to call the model through the API

          - `type: "boolean" | "file" | "file_array" | 7 more`

            The data type of the input

            - `"boolean"`

            - `"file"`

            - `"file_array"`

            - `"inputs_array"`

            - `"model"`

            - `"model_array"`

            - `"number"`

            - `"number_array"`

            - `"string"`

            - `"string_array"`

          - `allowedValues?: Array<unknown>`

            The allowed values for the input. For `string` or `number` types, creates a single-select
            dropdown.
            For `string_array` type, creates a multi-select dropdown.

          - `backgroundBehavior?: "opaque" | "transparent"`

            Specifies the background behavior for the input. Only available for `file` and `file_array`
            input types with kind `image`.

            - `"opaque"`

            - `"transparent"`

          - `color?: boolean`

            Whether the input is a color or not. Only available for `string` input type.

          - `costImpact?: boolean`

            Whether this input affects the model's cost calculation

          - `default?: unknown`

            The default value for the input

          - `description?: string`

            Help text displayed in the UI to provide additional information about the input

          - `group?: string`

            Used to visually group inputs together in the UI. Inputs with the same group value appear
            consecutively in the UI.

          - `hint?: string`

            Hint text displayed in the UI as a tooltip to guide the user

          - `inputs?: Array<Record<string, unknown>>`

            The list of inputs which form an object within a container array.
            All inputs are the same as the current object.
            This is only available for type inputs_array inputs.

          - `items?: Array<Array<Item>>`

            The configured items for inputs_array type inputs.
            Each item is an array of SubNodeInput that need ref/value resolution.
            Only available for inputs_array type.

            - `name: string`

              The name that must be user to call the model through the API

            - `type: "boolean" | "file" | "file_array" | 7 more`

              The data type of the input

              - `"boolean"`

              - `"file"`

              - `"file_array"`

              - `"inputs_array"`

              - `"model"`

              - `"model_array"`

              - `"number"`

              - `"number_array"`

              - `"string"`

              - `"string_array"`

            - `allowedValues?: Array<unknown>`

              The allowed values for the input. For `string` or `number` types, creates a single-select
              dropdown.
              For `string_array` type, creates a multi-select dropdown.

            - `backgroundBehavior?: "opaque" | "transparent"`

              Specifies the background behavior for the input. Only available for `file` and `file_array`
              input types with kind `image`.

              - `"opaque"`

              - `"transparent"`

            - `color?: boolean`

              Whether the input is a color or not. Only available for `string` input type.

            - `costImpact?: boolean`

              Whether this input affects the model's cost calculation

            - `default?: unknown`

              The default value for the input

            - `description?: string`

              Help text displayed in the UI to provide additional information about the input

            - `group?: string`

              Used to visually group inputs together in the UI. Inputs with the same group value appear
              consecutively in the UI.

            - `hint?: string`

              Hint text displayed in the UI as a tooltip to guide the user

            - `inputs?: Array<Record<string, unknown>>`

              The list of inputs which form an object within a container array.
              All inputs are the same as the current object.
              This is only available for type inputs_array inputs.

            - `kind?: "3d" | "audio" | "document" | 5 more`

              The asset kind of the input. Only taken into account for `file` and `file_array` input types.
              If model provides multiple kinds,
              the input will be not able to create the asset on the flight on API side with dataurl without data:kind, prefix
              `file` and `file_array` inputs always expose a kind: when a model does not declare one,
              `image` is returned, which is the kind used at generation time.

              - `"3d"`

              - `"audio"`

              - `"document"`

              - `"image"`

              - `"image-hdr"`

              - `"json"`

              - `"text"`

              - `"video"`

            - `label?: string`

              The label displayed in the UI for this input

            - `maskFrom?: string`

              The name of the file input field to use as the mask source

            - `max?: number`

              The maximum allowed value. Only available for `number` and `array` input types.

            - `maxDuration?: number`

              The maximum allowed media duration in seconds. Only applies to `file` and `file_array` input types
              for video and audio assets. Validated against `asset.properties.duration` at job creation time.

            - `maxLength?: number`

              The maximum allowed length for `string` and `model` inputs, in characters.
              For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
              ITEMS instead — the length of each item is not constrained.

            - `maxSize?: number`

              The maximum allowed file size in bytes. Only applies to `file` and `file_array` input types.
              Validated against `asset.properties.size` at job creation time.

            - `min?: number`

              The minimum allowed value. Only available for `number` and array input types.

            - `minDuration?: number`

              The minimum allowed media duration in seconds. Only applies to `file` and `file_array` input types
              for video and audio assets. Validated against `asset.properties.duration` at job creation time.

            - `minLength?: number`

              The minimum allowed length for `string` and `model` inputs, in characters.
              For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
              ITEMS instead — the length of each item is not constrained.

            - `modelTypes?: Array<"custom" | "elevenlabs-voice" | "flux.1" | 28 more>`

              The allowed model types for this input. Example: `["flux.1-lora"]`.
              Only available for `model_array` input type.

              - `"custom"`

              - `"elevenlabs-voice"`

              - `"flux.1"`

              - `"flux.1-composition"`

              - `"flux.1-kontext-dev"`

              - `"flux.1-kontext-lora"`

              - `"flux.1-krea-dev"`

              - `"flux.1-krea-lora"`

              - `"flux.1-lora"`

              - `"flux.1-pro"`

              - `"flux.1.1-pro-ultra"`

              - `"flux.2-dev-edit-lora"`

              - `"flux.2-dev-lora"`

              - `"flux.2-klein-4b-edit-lora"`

              - `"flux.2-klein-4b-lora"`

              - `"flux.2-klein-9b-edit-lora"`

              - `"flux.2-klein-9b-lora"`

              - `"flux.2-klein-base-4b-edit-lora"`

              - `"flux.2-klein-base-4b-lora"`

              - `"flux.2-klein-base-9b-edit-lora"`

              - `"flux.2-klein-base-9b-lora"`

              - `"flux1.1-pro"`

              - `"gpt-image-1"`

              - `"qwen-image-2512-lora"`

              - `"qwen-image-edit-2509-lora"`

              - `"qwen-image-edit-2511-lora"`

              - `"qwen-image-edit-lora"`

              - `"qwen-image-lora"`

              - `"zimage-de-turbo-lora"`

              - `"zimage-lora"`

              - `"zimage-turbo-lora"`

            - `parent?: boolean`

              Whether this input represents a parent asset to assign to the produced assets.
              Only available for `file` and `file_array` input types.

              For `file_array`, the parent asset is the first item in the array.

            - `placeholder?: string`

              Placeholder text for the input. Only available for 'string' input type.

            - `prompt?: boolean`

              Whether the input is a prompt. When true, displays as a text area with prompt spark feature.
              Only available for `string` input type.

            - `promptSpark?: boolean`

              Whether the input is used with prompt spark. Only available for `string` input type.

            - `ref?: Ref`

              The reference to another input or output of the same workflow.
              Must have at least one of node or conditional.

              - `conditional?: Array<string>`

                The conditional nodes to reference.
                If the conditional nodes are successful, the node will be successful.
                If the conditional nodes are skipped, the node will be skipped.
                Contains an array of node ids used to check the status of the nodes.

              - `equal?: string`

                This is the desired node output value if ref is an if/else node.

              - `name?: string`

                The name of the input or output to reference.
                If the type is 'workflow', the name is the name of the input of the workflow is required
                If the type is 'node', the name is not mandatory, except if you want all outputs of the node.
                To get all outputs of a node, you can use the name 'all'.

              - `node?: string`

                The node id or 'workflow' if the source is a workflow input.

            - `required?: Required`

              Set of rules that describes when this input is required:

              - `always`: Input is always required
              - `ifNotDefined`: Input is required when another specified input is not defined
              - `ifDefined`: Input is required when another specified input is defined
              - `conditional`: Input is required when other inputs have specific values

              By default, the input is not required.

              - `always?: boolean`

                Whether the input is always required

              - `conditional?: Conditional`

                Makes this input required when other inputs have one of the listed values

                - `values: unknown`

                  The conditions to check:

                  - Key: name of the input to check
                  - Value: values of that input that satisfy the condition

                - `operator?: "and" | "or"`

                  How the conditions combine: `and` (all must match) or `or` (any must match)

                  - `"and"`

                  - `"or"`

              - `ifDefined?: unknown`

                Makes this input required when another input is defined:

                - Key: name of the input that must be defined
                - Value: message to display when this input is required

              - `ifNotDefined?: unknown`

                Makes this input required when another input is not defined:

                - Key: name of the input that must be undefined
                - Value: message to display when this input is required

            - `step?: number`

              The step increment for numeric inputs. Only available for `number` input type.

            - `value?: unknown`

              The value of the input.
              This is the value of the input that will be used to run the node.
              Only available for flows managed by a WorkflowJob.

          - `kind?: "3d" | "audio" | "document" | 5 more`

            The asset kind of the input. Only taken into account for `file` and `file_array` input types.
            If model provides multiple kinds,
            the input will be not able to create the asset on the flight on API side with dataurl without data:kind, prefix
            `file` and `file_array` inputs always expose a kind: when a model does not declare one,
            `image` is returned, which is the kind used at generation time.

            - `"3d"`

            - `"audio"`

            - `"document"`

            - `"image"`

            - `"image-hdr"`

            - `"json"`

            - `"text"`

            - `"video"`

          - `label?: string`

            The label displayed in the UI for this input

          - `maskFrom?: string`

            The name of the file input field to use as the mask source

          - `max?: number`

            The maximum allowed value. Only available for `number` and `array` input types.

          - `maxDuration?: number`

            The maximum allowed media duration in seconds. Only applies to `file` and `file_array` input types
            for video and audio assets. Validated against `asset.properties.duration` at job creation time.

          - `maxLength?: number`

            The maximum allowed length for `string` and `model` inputs, in characters.
            For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
            ITEMS instead — the length of each item is not constrained.

          - `maxSize?: number`

            The maximum allowed file size in bytes. Only applies to `file` and `file_array` input types.
            Validated against `asset.properties.size` at job creation time.

          - `min?: number`

            The minimum allowed value. Only available for `number` and array input types.

          - `minDuration?: number`

            The minimum allowed media duration in seconds. Only applies to `file` and `file_array` input types
            for video and audio assets. Validated against `asset.properties.duration` at job creation time.

          - `minLength?: number`

            The minimum allowed length for `string` and `model` inputs, in characters.
            For the array types (`string_array`, `model_array`) it bounds the NUMBER OF
            ITEMS instead — the length of each item is not constrained.

          - `modelTypes?: Array<"custom" | "elevenlabs-voice" | "flux.1" | 28 more>`

            The allowed model types for this input. Example: `["flux.1-lora"]`.
            Only available for `model_array` input type.

            - `"custom"`

            - `"elevenlabs-voice"`

            - `"flux.1"`

            - `"flux.1-composition"`

            - `"flux.1-kontext-dev"`

            - `"flux.1-kontext-lora"`

            - `"flux.1-krea-dev"`

            - `"flux.1-krea-lora"`

            - `"flux.1-lora"`

            - `"flux.1-pro"`

            - `"flux.1.1-pro-ultra"`

            - `"flux.2-dev-edit-lora"`

            - `"flux.2-dev-lora"`

            - `"flux.2-klein-4b-edit-lora"`

            - `"flux.2-klein-4b-lora"`

            - `"flux.2-klein-9b-edit-lora"`

            - `"flux.2-klein-9b-lora"`

            - `"flux.2-klein-base-4b-edit-lora"`

            - `"flux.2-klein-base-4b-lora"`

            - `"flux.2-klein-base-9b-edit-lora"`

            - `"flux.2-klein-base-9b-lora"`

            - `"flux1.1-pro"`

            - `"gpt-image-1"`

            - `"qwen-image-2512-lora"`

            - `"qwen-image-edit-2509-lora"`

            - `"qwen-image-edit-2511-lora"`

            - `"qwen-image-edit-lora"`

            - `"qwen-image-lora"`

            - `"zimage-de-turbo-lora"`

            - `"zimage-lora"`

            - `"zimage-turbo-lora"`

          - `parent?: boolean`

            Whether this input represents a parent asset to assign to the produced assets.
            Only available for `file` and `file_array` input types.

            For `file_array`, the parent asset is the first item in the array.

          - `placeholder?: string`

            Placeholder text for the input. Only available for 'string' input type.

          - `prompt?: boolean`

            Whether the input is a prompt. When true, displays as a text area with prompt spark feature.
            Only available for `string` input type.

          - `promptSpark?: boolean`

            Whether the input is used with prompt spark. Only available for `string` input type.

          - `ref?: Ref`

            The reference to another input or output of the same workflow.
            Must have at least one of node or conditional.

            - `conditional?: Array<string>`

              The conditional nodes to reference.
              If the conditional nodes are successful, the node will be successful.
              If the conditional nodes are skipped, the node will be skipped.
              Contains an array of node ids used to check the status of the nodes.

            - `equal?: string`

              This is the desired node output value if ref is an if/else node.

            - `name?: string`

              The name of the input or output to reference.
              If the type is 'workflow', the name is the name of the input of the workflow is required
              If the type is 'node', the name is not mandatory, except if you want all outputs of the node.
              To get all outputs of a node, you can use the name 'all'.

            - `node?: string`

              The node id or 'workflow' if the source is a workflow input.

          - `required?: Required`

            Set of rules that describes when this input is required:

            - `always`: Input is always required
            - `ifNotDefined`: Input is required when another specified input is not defined
            - `ifDefined`: Input is required when another specified input is defined
            - `conditional`: Input is required when other inputs have specific values

            By default, the input is not required.

            - `always?: boolean`

              Whether the input is always required

            - `conditional?: Conditional`

              Makes this input required when other inputs have one of the listed values

              - `values: unknown`

                The conditions to check:

                - Key: name of the input to check
                - Value: values of that input that satisfy the condition

              - `operator?: "and" | "or"`

                How the conditions combine: `and` (all must match) or `or` (any must match)

                - `"and"`

                - `"or"`

            - `ifDefined?: unknown`

              Makes this input required when another input is defined:

              - Key: name of the input that must be defined
              - Value: message to display when this input is required

            - `ifNotDefined?: unknown`

              Makes this input required when another input is not defined:

              - Key: name of the input that must be undefined
              - Value: message to display when this input is required

          - `step?: number`

            The step increment for numeric inputs. Only available for `number` input type.

          - `value?: unknown`

            The value of the input.
            This is the value of the input that will be used to run the node.
            Only available for flows managed by a WorkflowJob.

        - `items?: Array<string>`

          Statically-configured items for a List node, or the frozen candidate list
          of a UserSelection node. The values can be strings, numbers, or asset IDs.

        - `iterationIndex?: number`

          Zero-based index of the iteration this node copy belongs to.
          Set on dynamically-created copies of loop body nodes.

        - `jobId?: string`

          If the flow is part of a WorkflowJob, this is the jobId for the node.
          jobId is only available for nodes started. A node "Pending" for a running workflow job is not started.

        - `logic?: Logic`

          The logic of the node.
          Only available for logic nodes.

          - `cases?: Array<Case>`

            The cases of the logic.
            Only available for if/else nodes.

            - `condition: string`

            - `value: string`

          - `default?: string`

            The default case of the logic.
            Contains the id/output of the node to execute if no case is matched.
            Only available for if/else nodes.

          - `transform?: string`

            The transform of the logic.
            Only available for transform nodes.

        - `logicType?: "if-else"`

          The type of the logic for the node.
          Only available for logic nodes.

          - `"if-else"`

        - `loopBodyNodeIds?: Array<string>`

          IDs of the body template nodes that belong to this ForEach loop.
          At runtime these templates are cloned once per iteration and marked Skipped.
          Only available for ForEach nodes.

        - `loopNodeId?: string`

          ID of the ForEach node that spawned this iteration copy.
          Set on dynamically-created copies of loop body nodes.

        - `modelId?: string`

          The model id for the node. Mainly used for custom model tasks.

        - `output?: unknown`

          The output of the node.
          Only available for logic nodes.

        - `workflowId?: string`

          The workflow id for the node. Mainly used for workflow tasks.

      - `hint?: string`

        Actionable hint for the user explaining what went wrong and how to resolve it.

      - `input?: Record<string, unknown>`

        The inputs for the job

      - `output?: Record<string, unknown>`

        May contain the output of the job for specific custom models jobs.
        Only available for custom models which generate non-assets outputs.
        Example: LLM text results.

      - `outputModelId?: string`

        For voice-clone jobs: the ID of the model being trained.

      - `workflowId?: string`

        The workflow ID of the job if job is part of a workflow.

      - `workflowJobId?: string`

        The workflow job ID of the job if job is part of a workflow job.

    - `progress: number`

      Progress of the job (between 0 and 1)

    - `status: "canceled" | "failure" | "finalizing" | 5 more`

      The current status of the job

      - `"canceled"`

      - `"failure"`

      - `"finalizing"`

      - `"in-progress"`

      - `"pending"`

      - `"queued"`

      - `"success"`

      - `"warming-up"`

    - `statusHistory: Array<StatusHistory>`

      The history of the different statuses the job went through with the ISO string date
      of when the job reached each statuses.

      - `date: string`

      - `status: "canceled" | "failure" | "finalizing" | 5 more`

        - `"canceled"`

        - `"failure"`

        - `"finalizing"`

        - `"in-progress"`

        - `"pending"`

        - `"queued"`

        - `"success"`

        - `"warming-up"`

    - `updatedAt: string`

      The job last update date as an ISO string (example: "2023-02-03T11:19:41.579Z")

    - `authorId?: string`

      The author user ID (example: "dcf121faaa1a0a0bbbd9ca1b73d62aea")

    - `billing?: Billing`

      The billing of the job

      - `cuCost: number`

      - `cuDiscount: number`

      - `cuCostDetails?: CuCostDetails`

        Compute Units charged for the ADD-ONS of this job, per action — the fees
        paid on top of the generation itself, such as `quality-gate`.

        `cuCost` above is the main action alone, so the job's total is `cuCost`
        plus the values here.

        Two caveats when displaying it:

        - These are a remaining refundable balance, not a receipt: a job that
          failed or was cancelled has had its add-ons refunded, so they read 0
          while `cuCost` still shows the main action's original charge.
        - `ip-detection` is part of the shape but is never populated today: that
          fee is charged outside the job and reported once, as
          `ipDetection.creativeUnitsCharged`, in the response of the request that
          ran it.

        Absent when the job paid for no add-on.

        - `"ip-detection"?: number`

        - `"quality-gate"?: number`

      - `disableRefund?: boolean`

        When true, the credits charged for this job are not automatically
        refunded if the generation fails, because the model used does not
        support refund-on-failure. Absent or false means a failed generation is
        refunded as usual.

    - `ownerId?: string`

      The owner ID (example: "team_U3Qmc8PCdWXwAQJ4Dvw4tV6D")
