@scenario-labs/sdk 0.3.0 → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (180) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/README.md +40 -6
  3. package/client.d.mts +34 -14
  4. package/client.d.mts.map +1 -1
  5. package/client.d.ts +34 -14
  6. package/client.d.ts.map +1 -1
  7. package/client.js +10 -0
  8. package/client.js.map +1 -1
  9. package/client.mjs +10 -0
  10. package/client.mjs.map +1 -1
  11. package/core/pagination.d.mts +153 -0
  12. package/core/pagination.d.mts.map +1 -0
  13. package/core/pagination.d.ts +153 -0
  14. package/core/pagination.d.ts.map +1 -0
  15. package/core/pagination.js +276 -0
  16. package/core/pagination.js.map +1 -0
  17. package/core/pagination.mjs +263 -0
  18. package/core/pagination.mjs.map +1 -0
  19. package/index.d.mts +2 -0
  20. package/index.d.mts.map +1 -1
  21. package/index.d.ts +2 -0
  22. package/index.d.ts.map +1 -1
  23. package/index.js +7 -1
  24. package/index.js.map +1 -1
  25. package/index.mjs +2 -0
  26. package/index.mjs.map +1 -1
  27. package/lib/models.d.mts +34 -2
  28. package/lib/models.d.mts.map +1 -1
  29. package/lib/models.d.ts +34 -2
  30. package/lib/models.d.ts.map +1 -1
  31. package/lib/models.js +39 -2
  32. package/lib/models.js.map +1 -1
  33. package/lib/models.mjs +37 -1
  34. package/lib/models.mjs.map +1 -1
  35. package/lib/scenario.d.mts +2 -0
  36. package/lib/scenario.d.mts.map +1 -1
  37. package/lib/scenario.d.ts +2 -0
  38. package/lib/scenario.d.ts.map +1 -1
  39. package/lib/scenario.js +2 -0
  40. package/lib/scenario.js.map +1 -1
  41. package/lib/scenario.mjs +2 -0
  42. package/lib/scenario.mjs.map +1 -1
  43. package/lib/upload.d.mts +89 -0
  44. package/lib/upload.d.mts.map +1 -0
  45. package/lib/upload.d.ts +89 -0
  46. package/lib/upload.d.ts.map +1 -0
  47. package/lib/upload.js +193 -0
  48. package/lib/upload.js.map +1 -0
  49. package/lib/upload.mjs +156 -0
  50. package/lib/upload.mjs.map +1 -0
  51. package/lib/workflow.d.mts +13 -2
  52. package/lib/workflow.d.mts.map +1 -1
  53. package/lib/workflow.d.ts +13 -2
  54. package/lib/workflow.d.ts.map +1 -1
  55. package/lib/workflow.js +17 -4
  56. package/lib/workflow.js.map +1 -1
  57. package/lib/workflow.mjs +17 -4
  58. package/lib/workflow.mjs.map +1 -1
  59. package/lib/workflow_import_validator.d.mts +40 -0
  60. package/lib/workflow_import_validator.d.mts.map +1 -0
  61. package/lib/workflow_import_validator.d.ts +40 -0
  62. package/lib/workflow_import_validator.d.ts.map +1 -0
  63. package/lib/workflow_import_validator.js +69 -0
  64. package/lib/workflow_import_validator.js.map +1 -0
  65. package/lib/workflow_import_validator.mjs +64 -0
  66. package/lib/workflow_import_validator.mjs.map +1 -0
  67. package/package.json +11 -1
  68. package/pagination.d.mts +2 -0
  69. package/pagination.d.mts.map +1 -0
  70. package/pagination.d.ts +2 -0
  71. package/pagination.d.ts.map +1 -0
  72. package/pagination.js +6 -0
  73. package/pagination.js.map +1 -0
  74. package/pagination.mjs +2 -0
  75. package/pagination.mjs.map +1 -0
  76. package/resources/assets/assets.d.mts +623 -646
  77. package/resources/assets/assets.d.mts.map +1 -1
  78. package/resources/assets/assets.d.ts +623 -646
  79. package/resources/assets/assets.d.ts.map +1 -1
  80. package/resources/assets/assets.js +3 -2
  81. package/resources/assets/assets.js.map +1 -1
  82. package/resources/assets/assets.mjs +3 -2
  83. package/resources/assets/assets.mjs.map +1 -1
  84. package/resources/assets/index.d.mts +1 -1
  85. package/resources/assets/index.d.mts.map +1 -1
  86. package/resources/assets/index.d.ts +1 -1
  87. package/resources/assets/index.d.ts.map +1 -1
  88. package/resources/assets/index.js.map +1 -1
  89. package/resources/assets/index.mjs.map +1 -1
  90. package/resources/collections/collections.d.mts +38 -49
  91. package/resources/collections/collections.d.mts.map +1 -1
  92. package/resources/collections/collections.d.ts +38 -49
  93. package/resources/collections/collections.d.ts.map +1 -1
  94. package/resources/collections/collections.js +5 -1
  95. package/resources/collections/collections.js.map +1 -1
  96. package/resources/collections/collections.mjs +5 -1
  97. package/resources/collections/collections.mjs.map +1 -1
  98. package/resources/collections/index.d.mts +1 -1
  99. package/resources/collections/index.d.mts.map +1 -1
  100. package/resources/collections/index.d.ts +1 -1
  101. package/resources/collections/index.d.ts.map +1 -1
  102. package/resources/collections/index.js.map +1 -1
  103. package/resources/collections/index.mjs.map +1 -1
  104. package/resources/index.d.mts +7 -7
  105. package/resources/index.d.mts.map +1 -1
  106. package/resources/index.d.ts +7 -7
  107. package/resources/index.d.ts.map +1 -1
  108. package/resources/index.js.map +1 -1
  109. package/resources/index.mjs.map +1 -1
  110. package/resources/jobs.d.mts +369 -380
  111. package/resources/jobs.d.mts.map +1 -1
  112. package/resources/jobs.d.ts +369 -380
  113. package/resources/jobs.d.ts.map +1 -1
  114. package/resources/jobs.js +2 -1
  115. package/resources/jobs.js.map +1 -1
  116. package/resources/jobs.mjs +2 -1
  117. package/resources/jobs.mjs.map +1 -1
  118. package/resources/models/index.d.mts +1 -1
  119. package/resources/models/index.d.mts.map +1 -1
  120. package/resources/models/index.d.ts +1 -1
  121. package/resources/models/index.d.ts.map +1 -1
  122. package/resources/models/index.js.map +1 -1
  123. package/resources/models/index.mjs.map +1 -1
  124. package/resources/models/models.d.mts +839 -850
  125. package/resources/models/models.d.mts.map +1 -1
  126. package/resources/models/models.d.ts +839 -850
  127. package/resources/models/models.d.ts.map +1 -1
  128. package/resources/models/models.js +2 -1
  129. package/resources/models/models.js.map +1 -1
  130. package/resources/models/models.mjs +2 -1
  131. package/resources/models/models.mjs.map +1 -1
  132. package/resources/search.d.mts +215 -295
  133. package/resources/search.d.mts.map +1 -1
  134. package/resources/search.d.ts +215 -295
  135. package/resources/search.d.ts.map +1 -1
  136. package/resources/search.js +9 -2
  137. package/resources/search.js.map +1 -1
  138. package/resources/search.mjs +9 -2
  139. package/resources/search.mjs.map +1 -1
  140. package/resources/tags.d.mts +23 -35
  141. package/resources/tags.d.mts.map +1 -1
  142. package/resources/tags.d.ts +23 -35
  143. package/resources/tags.d.ts.map +1 -1
  144. package/resources/tags.js +2 -1
  145. package/resources/tags.js.map +1 -1
  146. package/resources/tags.mjs +2 -1
  147. package/resources/tags.mjs.map +1 -1
  148. package/resources/workflows.d.mts +688 -704
  149. package/resources/workflows.d.mts.map +1 -1
  150. package/resources/workflows.d.ts +688 -704
  151. package/resources/workflows.d.ts.map +1 -1
  152. package/resources/workflows.js +5 -1
  153. package/resources/workflows.js.map +1 -1
  154. package/resources/workflows.mjs +5 -1
  155. package/resources/workflows.mjs.map +1 -1
  156. package/src/client.ts +103 -2
  157. package/src/core/pagination.ts +497 -0
  158. package/src/index.ts +8 -0
  159. package/src/lib/models.ts +62 -2
  160. package/src/lib/scenario.ts +2 -0
  161. package/src/lib/upload.ts +250 -0
  162. package/src/lib/workflow.ts +29 -4
  163. package/src/lib/workflow_import_validator.ts +104 -0
  164. package/src/pagination.ts +2 -0
  165. package/src/resources/assets/assets.ts +887 -902
  166. package/src/resources/assets/index.ts +2 -0
  167. package/src/resources/collections/collections.ts +45 -54
  168. package/src/resources/collections/index.ts +1 -0
  169. package/src/resources/index.ts +9 -1
  170. package/src/resources/jobs.ts +613 -622
  171. package/src/resources/models/index.ts +1 -0
  172. package/src/resources/models/models.ts +1052 -1064
  173. package/src/resources/search.ts +239 -327
  174. package/src/resources/tags.ts +32 -39
  175. package/src/resources/workflows.ts +850 -864
  176. package/src/version.ts +1 -1
  177. package/version.d.mts +1 -1
  178. package/version.d.ts +1 -1
  179. package/version.js +1 -1
  180. package/version.mjs +1 -1
@@ -1,5 +1,6 @@
1
1
  import { APIResource } from "../core/resource.js";
2
2
  import { APIPromise } from "../core/api-promise.js";
3
+ import { PagePromise, WorkflowsCursor, type WorkflowsCursorParams } from "../core/pagination.js";
3
4
  import { RequestOptions } from "../internal/request-options.js";
4
5
  export declare class Workflows extends APIResource {
5
6
  /**
@@ -17,7 +18,7 @@ export declare class Workflows extends APIResource {
17
18
  /**
18
19
  * List workflows
19
20
  */
20
- list(query?: WorkflowListParams | null | undefined, options?: RequestOptions): APIPromise<WorkflowListResponse>;
21
+ list(query?: WorkflowListParams | null | undefined, options?: RequestOptions): PagePromise<WorkflowListResponsesWorkflowsCursor, WorkflowListResponse>;
21
22
  /**
22
23
  * Delete workflow
23
24
  */
@@ -36,6 +37,7 @@ export declare class Workflows extends APIResource {
36
37
  */
37
38
  run(workflowID: string, params: WorkflowRunParams, options?: RequestOptions): APIPromise<WorkflowRunResponse>;
38
39
  }
40
+ export type WorkflowListResponsesWorkflowsCursor = WorkflowsCursor<WorkflowListResponse>;
39
41
  export interface WorkflowCreateResponse {
40
42
  workflow: WorkflowCreateResponse.Workflow;
41
43
  }
@@ -2991,204 +2993,349 @@ export declare namespace WorkflowUpdateResponse {
2991
2993
  }
2992
2994
  }
2993
2995
  }
2994
- /**
2995
- * Returns a paginated list of workflows. Supports both public access (via the
2996
- * `Authorization` header set to `public-auth-token`) and authenticated user access
2997
- * (including API keys). Public responses exclude some attributes.
2998
- */
2999
2996
  export interface WorkflowListResponse {
3000
- workflows: Array<WorkflowListResponse.Workflow>;
3001
2997
  /**
3002
- * A token to query the next page of workflows
2998
+ * Unique identifier of the workflow.
3003
2999
  */
3004
- nextPaginationToken?: string;
3000
+ id: string;
3001
+ /**
3002
+ * User that created the workflow.
3003
+ */
3004
+ authorId: string;
3005
+ /**
3006
+ * ISO string
3007
+ */
3008
+ createdAt: string;
3009
+ /**
3010
+ * Full description of what the workflow does.
3011
+ */
3012
+ description: string;
3013
+ /**
3014
+ * The UI data about the workflow. This is managed by scenario webapp.
3015
+ */
3016
+ editorInfo: {
3017
+ [key: string]: unknown;
3018
+ };
3019
+ /**
3020
+ * The flow of the workflow.
3021
+ */
3022
+ flow: Array<WorkflowListResponse.Flow>;
3023
+ /**
3024
+ * The inputs of the workflow.
3025
+ */
3026
+ inputs: Array<WorkflowListResponse.Input>;
3027
+ /**
3028
+ * Human-readable name of the workflow.
3029
+ */
3030
+ name: string;
3031
+ /**
3032
+ * Project that owns the workflow.
3033
+ */
3034
+ ownerId: string;
3035
+ /**
3036
+ * Visibility setting for the workflow.
3037
+ */
3038
+ privacy: 'private' | 'public' | 'unlisted';
3039
+ /**
3040
+ * Short summary of the workflow.
3041
+ */
3042
+ shortDescription: string;
3043
+ /**
3044
+ * Current lifecycle status (draft, ready, deleted).
3045
+ */
3046
+ status: 'deleted' | 'draft' | 'ready';
3047
+ /**
3048
+ * The tag set of the workflow.
3049
+ */
3050
+ tagSet: Array<string>;
3051
+ /**
3052
+ * ISO string
3053
+ */
3054
+ updatedAt: string;
3055
+ /**
3056
+ * A representation of an asset after being processed by the workflow
3057
+ */
3058
+ after?: WorkflowListResponse.After;
3059
+ /**
3060
+ * A representation of an asset before being processed by the workflow
3061
+ */
3062
+ before?: WorkflowListResponse.Before;
3063
+ /**
3064
+ * Embedding is a map of embedding version into embedding date
3065
+ */
3066
+ embedding?: unknown;
3067
+ /**
3068
+ * Whether the workflow is locked. Locked workflows cannot be modified or deleted
3069
+ * except by the author or a project admin.
3070
+ */
3071
+ isLocked?: boolean;
3072
+ lastIndexedAt?: string;
3073
+ /**
3074
+ * The type of indexing operation to perform in MeiliSearch
3075
+ */
3076
+ lastIndexingType?: 'CREATE' | 'DELETE' | 'UPDATE';
3077
+ /**
3078
+ * Timestamp when the workflow flow was last saved as a Ready (App) snapshot. Used
3079
+ * to compute the WorkflowNodes snapshot key. Only set for workflows that have been
3080
+ * in the Ready state.
3081
+ */
3082
+ lastReadyFlowUpdatedAt?: string;
3083
+ /**
3084
+ * ISO string timestamp when lock state was last changed.
3085
+ */
3086
+ lockedStateChangedAt?: string;
3087
+ /**
3088
+ * UserId of the user who last changed the lock state.
3089
+ */
3090
+ lockedStateChangedBy?: string;
3091
+ /**
3092
+ * Asset kinds produced by this workflow (if specified).
3093
+ */
3094
+ outputAssetKinds?: Array<'3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video'>;
3095
+ /**
3096
+ * Currently the thumbnail is identical to the after asset.
3097
+ */
3098
+ thumbnail?: WorkflowListResponse.Thumbnail;
3099
+ /**
3100
+ * The UI configuration for the workflow. This is managed by scenario webapp.
3101
+ */
3102
+ uiConfig?: WorkflowListResponse.UiConfig;
3005
3103
  }
3006
3104
  export declare namespace WorkflowListResponse {
3007
- interface Workflow {
3105
+ interface Flow {
3008
3106
  /**
3009
- * Unique identifier of the workflow.
3107
+ * The id of the node.
3010
3108
  */
3011
3109
  id: string;
3012
3110
  /**
3013
- * User that created the workflow.
3014
- */
3015
- authorId: string;
3016
- /**
3017
- * ISO string
3018
- */
3019
- createdAt: string;
3020
- /**
3021
- * Full description of what the workflow does.
3022
- */
3023
- description: string;
3024
- /**
3025
- * The UI data about the workflow. This is managed by scenario webapp.
3026
- */
3027
- editorInfo: {
3028
- [key: string]: unknown;
3029
- };
3030
- /**
3031
- * The flow of the workflow.
3032
- */
3033
- flow: Array<Workflow.Flow>;
3034
- /**
3035
- * The inputs of the workflow.
3036
- */
3037
- inputs: Array<Workflow.Input>;
3038
- /**
3039
- * Human-readable name of the workflow.
3040
- */
3041
- name: string;
3042
- /**
3043
- * Project that owns the workflow.
3044
- */
3045
- ownerId: string;
3046
- /**
3047
- * Visibility setting for the workflow.
3048
- */
3049
- privacy: 'private' | 'public' | 'unlisted';
3050
- /**
3051
- * Short summary of the workflow.
3052
- */
3053
- shortDescription: string;
3054
- /**
3055
- * Current lifecycle status (draft, ready, deleted).
3111
+ * The type of the job for the node.
3056
3112
  */
3057
- status: 'deleted' | 'draft' | 'ready';
3113
+ type: 'custom-model' | 'for-each' | 'generate-prompt' | 'list' | 'logic' | 'model' | 'remove-background' | 'transform' | 'user-approval' | 'workflow';
3058
3114
  /**
3059
- * The tag set of the workflow.
3115
+ * Fixed number of iterations for a ForEach node. When set, the loop runs exactly
3116
+ * `count` times regardless of array input. When not set, the loop iterates over
3117
+ * the resolved array input. Only available for ForEach nodes.
3060
3118
  */
3061
- tagSet: Array<string>;
3119
+ count?: number;
3062
3120
  /**
3063
- * ISO string
3121
+ * The nodes that this node depends on. Only available for nodes that have
3122
+ * dependencies. Mainly used for user approval nodes.
3064
3123
  */
3065
- updatedAt: string;
3124
+ dependsOn?: Array<string>;
3066
3125
  /**
3067
- * A representation of an asset after being processed by the workflow
3126
+ * If true, the outputs of this node will be included in the workflow job's final
3127
+ * output. Only applicable to producing nodes (custom-model, inference, etc.). By
3128
+ * default, only last nodes (nodes not referenced by other nodes) contribute to
3129
+ * outputs. Set this to true to also include intermediate nodes in the final
3130
+ * output. Note: This should only be set to `true` or left undefined.
3068
3131
  */
3069
- after?: Workflow.After;
3132
+ includeOutputsInWorkflowJob?: true;
3070
3133
  /**
3071
- * A representation of an asset before being processed by the workflow
3134
+ * The inputs of the node.
3072
3135
  */
3073
- before?: Workflow.Before;
3136
+ inputs?: Array<Flow.Input>;
3074
3137
  /**
3075
- * Embedding is a map of embedding version into embedding date
3138
+ * Statically-configured items for a List node. The node outputs this array as-is
3139
+ * when executed. Only available for List nodes. The values can be strings,
3140
+ * numbers, or asset IDs.
3076
3141
  */
3077
- embedding?: unknown;
3142
+ items?: Array<string>;
3078
3143
  /**
3079
- * Whether the workflow is locked. Locked workflows cannot be modified or deleted
3080
- * except by the author or a project admin.
3144
+ * Zero-based index of the iteration this node copy belongs to. Set on
3145
+ * dynamically-created copies of loop body nodes.
3081
3146
  */
3082
- isLocked?: boolean;
3083
- lastIndexedAt?: string;
3147
+ iterationIndex?: number;
3084
3148
  /**
3085
- * The type of indexing operation to perform in MeiliSearch
3149
+ * The logic of the node. Only available for logic nodes.
3086
3150
  */
3087
- lastIndexingType?: 'CREATE' | 'DELETE' | 'UPDATE';
3151
+ logic?: Flow.Logic;
3088
3152
  /**
3089
- * Timestamp when the workflow flow was last saved as a Ready (App) snapshot. Used
3090
- * to compute the WorkflowNodes snapshot key. Only set for workflows that have been
3091
- * in the Ready state.
3153
+ * The type of the logic for the node. Only available for logic nodes.
3092
3154
  */
3093
- lastReadyFlowUpdatedAt?: string;
3155
+ logicType?: 'if-else';
3094
3156
  /**
3095
- * ISO string timestamp when lock state was last changed.
3157
+ * IDs of the body template nodes that belong to this ForEach loop. At runtime
3158
+ * these templates are cloned once per iteration and marked Skipped. Only available
3159
+ * for ForEach nodes.
3096
3160
  */
3097
- lockedStateChangedAt?: string;
3161
+ loopBodyNodeIds?: Array<string>;
3098
3162
  /**
3099
- * UserId of the user who last changed the lock state.
3163
+ * ID of the ForEach node that spawned this iteration copy. Set on
3164
+ * dynamically-created copies of loop body nodes.
3100
3165
  */
3101
- lockedStateChangedBy?: string;
3166
+ loopNodeId?: string;
3102
3167
  /**
3103
- * Asset kinds produced by this workflow (if specified).
3168
+ * The model id for the node. Mainly used for custom model tasks.
3104
3169
  */
3105
- outputAssetKinds?: Array<'3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video'>;
3170
+ modelId?: string;
3106
3171
  /**
3107
- * Currently the thumbnail is identical to the after asset.
3172
+ * The workflow id for the node. Mainly used for workflow tasks.
3108
3173
  */
3109
- thumbnail?: Workflow.Thumbnail;
3174
+ workflowId?: string;
3175
+ }
3176
+ namespace Flow {
3110
3177
  /**
3111
- * The UI configuration for the workflow. This is managed by scenario webapp.
3178
+ * This is used to run the flow.
3112
3179
  */
3113
- uiConfig?: Workflow.UiConfig;
3114
- }
3115
- namespace Workflow {
3116
- interface Flow {
3180
+ interface Input {
3117
3181
  /**
3118
- * The id of the node.
3182
+ * The name that must be user to call the model through the API
3119
3183
  */
3120
- id: string;
3184
+ name: string;
3121
3185
  /**
3122
- * The type of the job for the node.
3186
+ * The data type of the input
3123
3187
  */
3124
- type: 'custom-model' | 'for-each' | 'generate-prompt' | 'list' | 'logic' | 'model' | 'remove-background' | 'transform' | 'user-approval' | 'workflow';
3188
+ type: 'boolean' | 'file' | 'file_array' | 'inputs_array' | 'model' | 'model_array' | 'number' | 'number_array' | 'string' | 'string_array';
3125
3189
  /**
3126
- * Fixed number of iterations for a ForEach node. When set, the loop runs exactly
3127
- * `count` times regardless of array input. When not set, the loop iterates over
3128
- * the resolved array input. Only available for ForEach nodes.
3190
+ * The allowed values for the input. For \`string\` or \`number\` types, creates a
3191
+ * single-select dropdown. For \`string_array\` type, creates a multi-select
3192
+ * dropdown.
3129
3193
  */
3130
- count?: number;
3194
+ allowedValues?: Array<unknown>;
3131
3195
  /**
3132
- * The nodes that this node depends on. Only available for nodes that have
3133
- * dependencies. Mainly used for user approval nodes.
3196
+ * Specifies the background behavior for the input. Only available for \`file\` and
3197
+ * \`file_array\` input types with kind \`image\`.
3134
3198
  */
3135
- dependsOn?: Array<string>;
3199
+ backgroundBehavior?: 'opaque' | 'transparent';
3136
3200
  /**
3137
- * If true, the outputs of this node will be included in the workflow job's final
3138
- * output. Only applicable to producing nodes (custom-model, inference, etc.). By
3139
- * default, only last nodes (nodes not referenced by other nodes) contribute to
3140
- * outputs. Set this to true to also include intermediate nodes in the final
3141
- * output. Note: This should only be set to `true` or left undefined.
3201
+ * Whether the input is a color or not. Only available for \`string\` input type.
3142
3202
  */
3143
- includeOutputsInWorkflowJob?: true;
3203
+ color?: boolean;
3144
3204
  /**
3145
- * The inputs of the node.
3205
+ * Whether this input affects the model's cost calculation
3146
3206
  */
3147
- inputs?: Array<Flow.Input>;
3207
+ costImpact?: boolean;
3148
3208
  /**
3149
- * Statically-configured items for a List node. The node outputs this array as-is
3150
- * when executed. Only available for List nodes. The values can be strings,
3151
- * numbers, or asset IDs.
3209
+ * The default value for the input
3152
3210
  */
3153
- items?: Array<string>;
3211
+ default?: unknown;
3154
3212
  /**
3155
- * Zero-based index of the iteration this node copy belongs to. Set on
3156
- * dynamically-created copies of loop body nodes.
3213
+ * Help text displayed in the UI to provide additional information about the input
3157
3214
  */
3158
- iterationIndex?: number;
3215
+ description?: string;
3159
3216
  /**
3160
- * The logic of the node. Only available for logic nodes.
3217
+ * Used to visually group inputs together in the UI. Inputs with the same group
3218
+ * value appear consecutively in the UI.
3161
3219
  */
3162
- logic?: Flow.Logic;
3220
+ group?: string;
3163
3221
  /**
3164
- * The type of the logic for the node. Only available for logic nodes.
3222
+ * Hint text displayed in the UI as a tooltip to guide the user
3165
3223
  */
3166
- logicType?: 'if-else';
3224
+ hint?: string;
3167
3225
  /**
3168
- * IDs of the body template nodes that belong to this ForEach loop. At runtime
3169
- * these templates are cloned once per iteration and marked Skipped. Only available
3170
- * for ForEach nodes.
3226
+ * The list of inputs which form an object within a container array. All inputs are
3227
+ * the same as the current object. This is only available for type inputs_array
3228
+ * inputs.
3171
3229
  */
3172
- loopBodyNodeIds?: Array<string>;
3230
+ inputs?: Array<{
3231
+ [key: string]: unknown;
3232
+ }>;
3173
3233
  /**
3174
- * ID of the ForEach node that spawned this iteration copy. Set on
3175
- * dynamically-created copies of loop body nodes.
3234
+ * The configured items for inputs_array type inputs. Each item is an array of
3235
+ * SubNodeInput that need ref/value resolution. Only available for inputs_array
3236
+ * type.
3176
3237
  */
3177
- loopNodeId?: string;
3238
+ items?: Array<Array<Input.Item>>;
3178
3239
  /**
3179
- * The model id for the node. Mainly used for custom model tasks.
3180
- */
3181
- modelId?: string;
3240
+ * The asset kind of the input. Only taken into account for \`file\` and
3241
+ * \`file_array\` input types. If model provides multiple kinds, the input will be
3242
+ * not able to create the asset on the flight on API side with dataurl without
3243
+ * data:kind, prefix
3244
+ */
3245
+ kind?: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
3182
3246
  /**
3183
- * The workflow id for the node. Mainly used for workflow tasks.
3247
+ * The label displayed in the UI for this input
3184
3248
  */
3185
- workflowId?: string;
3249
+ label?: string;
3250
+ /**
3251
+ * The name of the file input field to use as the mask source
3252
+ */
3253
+ maskFrom?: string;
3254
+ /**
3255
+ * The maximum allowed value. Only available for \`number\` and \`array\` input
3256
+ * types.
3257
+ */
3258
+ max?: number;
3259
+ /**
3260
+ * The maximum allowed length for \`string\` inputs. Also applies to each item in
3261
+ * \`string_array\`.
3262
+ */
3263
+ maxLength?: number;
3264
+ /**
3265
+ * The maximum allowed file size in bytes. Only applies to \`file\` and
3266
+ * \`file_array\` input types. Validated against \`asset.properties.size\` at job
3267
+ * creation time.
3268
+ */
3269
+ maxSize?: number;
3270
+ /**
3271
+ * The minimum allowed value. Only available for \`number\` and array input types.
3272
+ */
3273
+ min?: number;
3274
+ /**
3275
+ * The minimum allowed length for string inputs. Also applies to each item in
3276
+ * \`string_array\`.
3277
+ */
3278
+ minLength?: number;
3279
+ /**
3280
+ * The allowed model types for this input. Example: \`["flux.1-lora"]\`. Only
3281
+ * available for \`model_array\` input type.
3282
+ */
3283
+ modelTypes?: Array<'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' | 'sd-1_5' | 'sd-1_5-composition' | 'sd-1_5-lora' | 'sd-xl' | 'sd-xl-composition' | 'sd-xl-lora' | 'zimage-de-turbo-lora' | 'zimage-lora' | 'zimage-turbo-lora'>;
3284
+ /**
3285
+ * Whether this input represents a parent asset to assign to the produced assets.
3286
+ * Only available for \`file\` and \`file_array\` input types.
3287
+ *
3288
+ * For \`file_array\`, the parent asset is the first item in the array.
3289
+ */
3290
+ parent?: boolean;
3291
+ /**
3292
+ * Placeholder text for the input. Only available for 'string' input type.
3293
+ */
3294
+ placeholder?: string;
3295
+ /**
3296
+ * Whether the input is a prompt. When true, displays as a text area with prompt
3297
+ * spark feature. Only available for \`string\` input type.
3298
+ */
3299
+ prompt?: boolean;
3300
+ /**
3301
+ * Whether the input is used with prompt spark. Only available for \`string\` input
3302
+ * type.
3303
+ */
3304
+ promptSpark?: boolean;
3305
+ /**
3306
+ * The reference to another input or output of the same workflow. Must have at
3307
+ * least one of node or conditional.
3308
+ */
3309
+ ref?: Input.Ref;
3310
+ /**
3311
+ * Set of rules that describes when this input is required:
3312
+ *
3313
+ * - \`always\`: Input is always required
3314
+ * - \`ifNotDefined\`: Input is required when another specified input is not
3315
+ * defined
3316
+ * - \`ifDefined\`: Input is required when another specified input is defined
3317
+ * - \`conditionalValues\`: Input is required when another input has a specific
3318
+ * value
3319
+ *
3320
+ * By default, the input is not required.
3321
+ */
3322
+ required?: Input.Required;
3323
+ /**
3324
+ * The step increment for numeric inputs. Only available for \`number\` input type.
3325
+ */
3326
+ step?: number;
3327
+ /**
3328
+ * The value of the input. This is the value of the input that will be used to run
3329
+ * the node. Only available for flows managed by a WorkflowJob.
3330
+ */
3331
+ value?: unknown;
3186
3332
  }
3187
- namespace Flow {
3333
+ namespace Input {
3188
3334
  /**
3189
- * This is used to run the flow.
3335
+ * A sub-input within an inputs_array item. Same as NodeInput but without the
3336
+ * recursive items field.
3190
3337
  */
3191
- interface Input {
3338
+ interface Item {
3192
3339
  /**
3193
3340
  * The name that must be user to call the model through the API
3194
3341
  */
@@ -3241,12 +3388,6 @@ export declare namespace WorkflowListResponse {
3241
3388
  inputs?: Array<{
3242
3389
  [key: string]: unknown;
3243
3390
  }>;
3244
- /**
3245
- * The configured items for inputs_array type inputs. Each item is an array of
3246
- * SubNodeInput that need ref/value resolution. Only available for inputs_array
3247
- * type.
3248
- */
3249
- items?: Array<Array<Input.Item>>;
3250
3391
  /**
3251
3392
  * The asset kind of the input. Only taken into account for \`file\` and
3252
3393
  * \`file_array\` input types. If model provides multiple kinds, the input will be
@@ -3317,7 +3458,7 @@ export declare namespace WorkflowListResponse {
3317
3458
  * The reference to another input or output of the same workflow. Must have at
3318
3459
  * least one of node or conditional.
3319
3460
  */
3320
- ref?: Input.Ref;
3461
+ ref?: Item.Ref;
3321
3462
  /**
3322
3463
  * Set of rules that describes when this input is required:
3323
3464
  *
@@ -3330,7 +3471,7 @@ export declare namespace WorkflowListResponse {
3330
3471
  *
3331
3472
  * By default, the input is not required.
3332
3473
  */
3333
- required?: Input.Required;
3474
+ required?: Item.Required;
3334
3475
  /**
3335
3476
  * The step increment for numeric inputs. Only available for \`number\` input type.
3336
3477
  */
@@ -3341,647 +3482,494 @@ export declare namespace WorkflowListResponse {
3341
3482
  */
3342
3483
  value?: unknown;
3343
3484
  }
3344
- namespace Input {
3485
+ namespace Item {
3345
3486
  /**
3346
- * A sub-input within an inputs_array item. Same as NodeInput but without the
3347
- * recursive items field.
3487
+ * The reference to another input or output of the same workflow. Must have at
3488
+ * least one of node or conditional.
3348
3489
  */
3349
- interface Item {
3350
- /**
3351
- * The name that must be user to call the model through the API
3352
- */
3353
- name: string;
3354
- /**
3355
- * The data type of the input
3356
- */
3357
- type: 'boolean' | 'file' | 'file_array' | 'inputs_array' | 'model' | 'model_array' | 'number' | 'number_array' | 'string' | 'string_array';
3358
- /**
3359
- * The allowed values for the input. For \`string\` or \`number\` types, creates a
3360
- * single-select dropdown. For \`string_array\` type, creates a multi-select
3361
- * dropdown.
3362
- */
3363
- allowedValues?: Array<unknown>;
3364
- /**
3365
- * Specifies the background behavior for the input. Only available for \`file\` and
3366
- * \`file_array\` input types with kind \`image\`.
3367
- */
3368
- backgroundBehavior?: 'opaque' | 'transparent';
3369
- /**
3370
- * Whether the input is a color or not. Only available for \`string\` input type.
3371
- */
3372
- color?: boolean;
3373
- /**
3374
- * Whether this input affects the model's cost calculation
3375
- */
3376
- costImpact?: boolean;
3377
- /**
3378
- * The default value for the input
3379
- */
3380
- default?: unknown;
3381
- /**
3382
- * Help text displayed in the UI to provide additional information about the input
3383
- */
3384
- description?: string;
3385
- /**
3386
- * Used to visually group inputs together in the UI. Inputs with the same group
3387
- * value appear consecutively in the UI.
3388
- */
3389
- group?: string;
3390
- /**
3391
- * Hint text displayed in the UI as a tooltip to guide the user
3392
- */
3393
- hint?: string;
3394
- /**
3395
- * The list of inputs which form an object within a container array. All inputs are
3396
- * the same as the current object. This is only available for type inputs_array
3397
- * inputs.
3398
- */
3399
- inputs?: Array<{
3400
- [key: string]: unknown;
3401
- }>;
3402
- /**
3403
- * The asset kind of the input. Only taken into account for \`file\` and
3404
- * \`file_array\` input types. If model provides multiple kinds, the input will be
3405
- * not able to create the asset on the flight on API side with dataurl without
3406
- * data:kind, prefix
3407
- */
3408
- kind?: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
3409
- /**
3410
- * The label displayed in the UI for this input
3411
- */
3412
- label?: string;
3413
- /**
3414
- * The name of the file input field to use as the mask source
3415
- */
3416
- maskFrom?: string;
3417
- /**
3418
- * The maximum allowed value. Only available for \`number\` and \`array\` input
3419
- * types.
3420
- */
3421
- max?: number;
3490
+ interface Ref {
3422
3491
  /**
3423
- * The maximum allowed length for \`string\` inputs. Also applies to each item in
3424
- * \`string_array\`.
3492
+ * The conditional nodes to reference. If the conditional nodes are successful, the
3493
+ * node will be successful. If the conditional nodes are skipped, the node will be
3494
+ * skipped. Contains an array of node ids used to check the status of the nodes.
3425
3495
  */
3426
- maxLength?: number;
3496
+ conditional?: Array<string>;
3427
3497
  /**
3428
- * The maximum allowed file size in bytes. Only applies to \`file\` and
3429
- * \`file_array\` input types. Validated against \`asset.properties.size\` at job
3430
- * creation time.
3498
+ * This is the desired node output value if ref is an if/else node.
3431
3499
  */
3432
- maxSize?: number;
3500
+ equal?: string;
3433
3501
  /**
3434
- * The minimum allowed value. Only available for \`number\` and array input types.
3502
+ * The name of the input or output to reference. If the type is 'workflow', the
3503
+ * name is the name of the input of the workflow is required If the type is 'node',
3504
+ * the name is not mandatory, except if you want all outputs of the node. To get
3505
+ * all outputs of a node, you can use the name 'all'.
3435
3506
  */
3436
- min?: number;
3507
+ name?: string;
3437
3508
  /**
3438
- * The minimum allowed length for string inputs. Also applies to each item in
3439
- * \`string_array\`.
3509
+ * The node id or 'workflow' if the source is a workflow input.
3440
3510
  */
3441
- minLength?: number;
3511
+ node?: string;
3512
+ }
3513
+ /**
3514
+ * Set of rules that describes when this input is required:
3515
+ *
3516
+ * - \`always\`: Input is always required
3517
+ * - \`ifNotDefined\`: Input is required when another specified input is not
3518
+ * defined
3519
+ * - \`ifDefined\`: Input is required when another specified input is defined
3520
+ * - \`conditionalValues\`: Input is required when another input has a specific
3521
+ * value
3522
+ *
3523
+ * By default, the input is not required.
3524
+ */
3525
+ interface Required {
3442
3526
  /**
3443
- * The allowed model types for this input. Example: \`["flux.1-lora"]\`. Only
3444
- * available for \`model_array\` input type.
3527
+ * Whether the input is always required
3445
3528
  */
3446
- modelTypes?: Array<'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' | 'sd-1_5' | 'sd-1_5-composition' | 'sd-1_5-lora' | 'sd-xl' | 'sd-xl-composition' | 'sd-xl-lora' | 'zimage-de-turbo-lora' | 'zimage-lora' | 'zimage-turbo-lora'>;
3529
+ always?: boolean;
3447
3530
  /**
3448
- * Whether this input represents a parent asset to assign to the produced assets.
3449
- * Only available for \`file\` and \`file_array\` input types.
3531
+ * Makes this input required when another input has a specific value:
3450
3532
  *
3451
- * For \`file_array\`, the parent asset is the first item in the array.
3533
+ * - Key: name of the input to check
3534
+ * - Value: operation and allowed values that trigger the requirement
3452
3535
  */
3453
- parent?: boolean;
3536
+ conditionalValues?: unknown;
3454
3537
  /**
3455
- * Placeholder text for the input. Only available for 'string' input type.
3538
+ * Makes this input required when another input is defined:
3539
+ *
3540
+ * - Key: name of the input that must be defined
3541
+ * - Value: message to display when this input is required
3456
3542
  */
3457
- placeholder?: string;
3543
+ ifDefined?: unknown;
3458
3544
  /**
3459
- * Whether the input is a prompt. When true, displays as a text area with prompt
3460
- * spark feature. Only available for \`string\` input type.
3545
+ * Makes this input required when another input is not defined:
3546
+ *
3547
+ * - Key: name of the input that must be undefined
3548
+ * - Value: message to display when this input is required
3461
3549
  */
3462
- prompt?: boolean;
3463
- /**
3464
- * Whether the input is used with prompt spark. Only available for \`string\` input
3465
- * type.
3466
- */
3467
- promptSpark?: boolean;
3468
- /**
3469
- * The reference to another input or output of the same workflow. Must have at
3470
- * least one of node or conditional.
3471
- */
3472
- ref?: Item.Ref;
3473
- /**
3474
- * Set of rules that describes when this input is required:
3475
- *
3476
- * - \`always\`: Input is always required
3477
- * - \`ifNotDefined\`: Input is required when another specified input is not
3478
- * defined
3479
- * - \`ifDefined\`: Input is required when another specified input is defined
3480
- * - \`conditionalValues\`: Input is required when another input has a specific
3481
- * value
3482
- *
3483
- * By default, the input is not required.
3484
- */
3485
- required?: Item.Required;
3486
- /**
3487
- * The step increment for numeric inputs. Only available for \`number\` input type.
3488
- */
3489
- step?: number;
3490
- /**
3491
- * The value of the input. This is the value of the input that will be used to run
3492
- * the node. Only available for flows managed by a WorkflowJob.
3493
- */
3494
- value?: unknown;
3495
- }
3496
- namespace Item {
3497
- /**
3498
- * The reference to another input or output of the same workflow. Must have at
3499
- * least one of node or conditional.
3500
- */
3501
- interface Ref {
3502
- /**
3503
- * The conditional nodes to reference. If the conditional nodes are successful, the
3504
- * node will be successful. If the conditional nodes are skipped, the node will be
3505
- * skipped. Contains an array of node ids used to check the status of the nodes.
3506
- */
3507
- conditional?: Array<string>;
3508
- /**
3509
- * This is the desired node output value if ref is an if/else node.
3510
- */
3511
- equal?: string;
3512
- /**
3513
- * The name of the input or output to reference. If the type is 'workflow', the
3514
- * name is the name of the input of the workflow is required If the type is 'node',
3515
- * the name is not mandatory, except if you want all outputs of the node. To get
3516
- * all outputs of a node, you can use the name 'all'.
3517
- */
3518
- name?: string;
3519
- /**
3520
- * The node id or 'workflow' if the source is a workflow input.
3521
- */
3522
- node?: string;
3523
- }
3524
- /**
3525
- * Set of rules that describes when this input is required:
3526
- *
3527
- * - \`always\`: Input is always required
3528
- * - \`ifNotDefined\`: Input is required when another specified input is not
3529
- * defined
3530
- * - \`ifDefined\`: Input is required when another specified input is defined
3531
- * - \`conditionalValues\`: Input is required when another input has a specific
3532
- * value
3533
- *
3534
- * By default, the input is not required.
3535
- */
3536
- interface Required {
3537
- /**
3538
- * Whether the input is always required
3539
- */
3540
- always?: boolean;
3541
- /**
3542
- * Makes this input required when another input has a specific value:
3543
- *
3544
- * - Key: name of the input to check
3545
- * - Value: operation and allowed values that trigger the requirement
3546
- */
3547
- conditionalValues?: unknown;
3548
- /**
3549
- * Makes this input required when another input is defined:
3550
- *
3551
- * - Key: name of the input that must be defined
3552
- * - Value: message to display when this input is required
3553
- */
3554
- ifDefined?: unknown;
3555
- /**
3556
- * Makes this input required when another input is not defined:
3557
- *
3558
- * - Key: name of the input that must be undefined
3559
- * - Value: message to display when this input is required
3560
- */
3561
- ifNotDefined?: unknown;
3562
- }
3550
+ ifNotDefined?: unknown;
3563
3551
  }
3552
+ }
3553
+ /**
3554
+ * The reference to another input or output of the same workflow. Must have at
3555
+ * least one of node or conditional.
3556
+ */
3557
+ interface Ref {
3564
3558
  /**
3565
- * The reference to another input or output of the same workflow. Must have at
3566
- * least one of node or conditional.
3559
+ * The conditional nodes to reference. If the conditional nodes are successful, the
3560
+ * node will be successful. If the conditional nodes are skipped, the node will be
3561
+ * skipped. Contains an array of node ids used to check the status of the nodes.
3567
3562
  */
3568
- interface Ref {
3569
- /**
3570
- * The conditional nodes to reference. If the conditional nodes are successful, the
3571
- * node will be successful. If the conditional nodes are skipped, the node will be
3572
- * skipped. Contains an array of node ids used to check the status of the nodes.
3573
- */
3574
- conditional?: Array<string>;
3575
- /**
3576
- * This is the desired node output value if ref is an if/else node.
3577
- */
3578
- equal?: string;
3579
- /**
3580
- * The name of the input or output to reference. If the type is 'workflow', the
3581
- * name is the name of the input of the workflow is required If the type is 'node',
3582
- * the name is not mandatory, except if you want all outputs of the node. To get
3583
- * all outputs of a node, you can use the name 'all'.
3584
- */
3585
- name?: string;
3586
- /**
3587
- * The node id or 'workflow' if the source is a workflow input.
3588
- */
3589
- node?: string;
3590
- }
3563
+ conditional?: Array<string>;
3591
3564
  /**
3592
- * Set of rules that describes when this input is required:
3593
- *
3594
- * - \`always\`: Input is always required
3595
- * - \`ifNotDefined\`: Input is required when another specified input is not
3596
- * defined
3597
- * - \`ifDefined\`: Input is required when another specified input is defined
3598
- * - \`conditionalValues\`: Input is required when another input has a specific
3599
- * value
3600
- *
3601
- * By default, the input is not required.
3565
+ * This is the desired node output value if ref is an if/else node.
3602
3566
  */
3603
- interface Required {
3604
- /**
3605
- * Whether the input is always required
3606
- */
3607
- always?: boolean;
3608
- /**
3609
- * Makes this input required when another input has a specific value:
3610
- *
3611
- * - Key: name of the input to check
3612
- * - Value: operation and allowed values that trigger the requirement
3613
- */
3614
- conditionalValues?: unknown;
3615
- /**
3616
- * Makes this input required when another input is defined:
3617
- *
3618
- * - Key: name of the input that must be defined
3619
- * - Value: message to display when this input is required
3620
- */
3621
- ifDefined?: unknown;
3622
- /**
3623
- * Makes this input required when another input is not defined:
3624
- *
3625
- * - Key: name of the input that must be undefined
3626
- * - Value: message to display when this input is required
3627
- */
3628
- ifNotDefined?: unknown;
3629
- }
3567
+ equal?: string;
3568
+ /**
3569
+ * The name of the input or output to reference. If the type is 'workflow', the
3570
+ * name is the name of the input of the workflow is required If the type is 'node',
3571
+ * the name is not mandatory, except if you want all outputs of the node. To get
3572
+ * all outputs of a node, you can use the name 'all'.
3573
+ */
3574
+ name?: string;
3575
+ /**
3576
+ * The node id or 'workflow' if the source is a workflow input.
3577
+ */
3578
+ node?: string;
3630
3579
  }
3631
3580
  /**
3632
- * The logic of the node. Only available for logic nodes.
3581
+ * Set of rules that describes when this input is required:
3582
+ *
3583
+ * - \`always\`: Input is always required
3584
+ * - \`ifNotDefined\`: Input is required when another specified input is not
3585
+ * defined
3586
+ * - \`ifDefined\`: Input is required when another specified input is defined
3587
+ * - \`conditionalValues\`: Input is required when another input has a specific
3588
+ * value
3589
+ *
3590
+ * By default, the input is not required.
3633
3591
  */
3634
- interface Logic {
3592
+ interface Required {
3635
3593
  /**
3636
- * The cases of the logic. Only available for if/else nodes.
3594
+ * Whether the input is always required
3637
3595
  */
3638
- cases?: Array<Logic.Case>;
3596
+ always?: boolean;
3639
3597
  /**
3640
- * The default case of the logic. Contains the id/output of the node to execute if
3641
- * no case is matched. Only available for if/else nodes.
3598
+ * Makes this input required when another input has a specific value:
3599
+ *
3600
+ * - Key: name of the input to check
3601
+ * - Value: operation and allowed values that trigger the requirement
3642
3602
  */
3643
- default?: string;
3603
+ conditionalValues?: unknown;
3644
3604
  /**
3645
- * The transform of the logic. Only available for transform nodes.
3605
+ * Makes this input required when another input is defined:
3606
+ *
3607
+ * - Key: name of the input that must be defined
3608
+ * - Value: message to display when this input is required
3646
3609
  */
3647
- transform?: string;
3648
- }
3649
- namespace Logic {
3650
- interface Case {
3651
- condition: string;
3652
- value: string;
3653
- }
3610
+ ifDefined?: unknown;
3611
+ /**
3612
+ * Makes this input required when another input is not defined:
3613
+ *
3614
+ * - Key: name of the input that must be undefined
3615
+ * - Value: message to display when this input is required
3616
+ */
3617
+ ifNotDefined?: unknown;
3654
3618
  }
3655
3619
  }
3656
3620
  /**
3657
- * Defines the input parameters for a model. Use this to understand the available
3658
- * input parameters for a given `modelId` when calling
3659
- * `POST /generate/custom/{modelId}`. See {@link
3660
- * https://docs.scenario.com/docs/video-generation} for examples.
3621
+ * The logic of the node. Only available for logic nodes.
3661
3622
  */
3662
- interface Input {
3663
- /**
3664
- * The name that must be user to call the model through the API
3665
- */
3666
- name: string;
3667
- /**
3668
- * The data type of the input
3669
- */
3670
- type: 'boolean' | 'file' | 'file_array' | 'inputs_array' | 'model' | 'model_array' | 'number' | 'number_array' | 'string' | 'string_array';
3671
- /**
3672
- * The allowed values for the input. For \`string\` or \`number\` types, creates a
3673
- * single-select dropdown. For \`string_array\` type, creates a multi-select
3674
- * dropdown.
3675
- */
3676
- allowedValues?: Array<unknown>;
3677
- /**
3678
- * Specifies the background behavior for the input. Only available for \`file\` and
3679
- * \`file_array\` input types with kind \`image\`.
3680
- */
3681
- backgroundBehavior?: 'opaque' | 'transparent';
3682
- /**
3683
- * Whether the input is a color or not. Only available for \`string\` input type.
3684
- */
3685
- color?: boolean;
3686
- /**
3687
- * Whether this input affects the model's cost calculation
3688
- */
3689
- costImpact?: boolean;
3690
- /**
3691
- * The default value for the input
3692
- */
3693
- default?: unknown;
3694
- /**
3695
- * Help text displayed in the UI to provide additional information about the input
3696
- */
3697
- description?: string;
3698
- /**
3699
- * Used to visually group inputs together in the UI. Inputs with the same group
3700
- * value appear consecutively in the UI.
3701
- */
3702
- group?: string;
3703
- /**
3704
- * Hint text displayed in the UI as a tooltip to guide the user
3705
- */
3706
- hint?: string;
3707
- /**
3708
- * The list of inputs which form an object within a container array. All inputs are
3709
- * the same as the current object. This is only available for type inputs_array
3710
- * inputs.
3711
- */
3712
- inputs?: Array<{
3713
- [key: string]: unknown;
3714
- }>;
3715
- /**
3716
- * The asset kind of the input. Only taken into account for \`file\` and
3717
- * \`file_array\` input types. If model provides multiple kinds, the input will be
3718
- * not able to create the asset on the flight on API side with dataurl without
3719
- * data:kind, prefix
3720
- */
3721
- kind?: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
3722
- /**
3723
- * The label displayed in the UI for this input
3724
- */
3725
- label?: string;
3726
- /**
3727
- * The name of the file input field to use as the mask source
3728
- */
3729
- maskFrom?: string;
3730
- /**
3731
- * The maximum allowed value. Only available for \`number\` and \`array\` input
3732
- * types.
3733
- */
3734
- max?: number;
3735
- /**
3736
- * The maximum allowed length for \`string\` inputs. Also applies to each item in
3737
- * \`string_array\`.
3738
- */
3739
- maxLength?: number;
3623
+ interface Logic {
3740
3624
  /**
3741
- * The maximum allowed file size in bytes. Only applies to \`file\` and
3742
- * \`file_array\` input types. Validated against \`asset.properties.size\` at job
3743
- * creation time.
3625
+ * The cases of the logic. Only available for if/else nodes.
3744
3626
  */
3745
- maxSize?: number;
3627
+ cases?: Array<Logic.Case>;
3746
3628
  /**
3747
- * The minimum allowed value. Only available for \`number\` and array input types.
3629
+ * The default case of the logic. Contains the id/output of the node to execute if
3630
+ * no case is matched. Only available for if/else nodes.
3748
3631
  */
3749
- min?: number;
3632
+ default?: string;
3750
3633
  /**
3751
- * The minimum allowed length for string inputs. Also applies to each item in
3752
- * \`string_array\`.
3634
+ * The transform of the logic. Only available for transform nodes.
3753
3635
  */
3754
- minLength?: number;
3636
+ transform?: string;
3637
+ }
3638
+ namespace Logic {
3639
+ interface Case {
3640
+ condition: string;
3641
+ value: string;
3642
+ }
3643
+ }
3644
+ }
3645
+ /**
3646
+ * Defines the input parameters for a model. Use this to understand the available
3647
+ * input parameters for a given `modelId` when calling
3648
+ * `POST /generate/custom/{modelId}`. See {@link
3649
+ * https://docs.scenario.com/docs/video-generation} for examples.
3650
+ */
3651
+ interface Input {
3652
+ /**
3653
+ * The name that must be user to call the model through the API
3654
+ */
3655
+ name: string;
3656
+ /**
3657
+ * The data type of the input
3658
+ */
3659
+ type: 'boolean' | 'file' | 'file_array' | 'inputs_array' | 'model' | 'model_array' | 'number' | 'number_array' | 'string' | 'string_array';
3660
+ /**
3661
+ * The allowed values for the input. For \`string\` or \`number\` types, creates a
3662
+ * single-select dropdown. For \`string_array\` type, creates a multi-select
3663
+ * dropdown.
3664
+ */
3665
+ allowedValues?: Array<unknown>;
3666
+ /**
3667
+ * Specifies the background behavior for the input. Only available for \`file\` and
3668
+ * \`file_array\` input types with kind \`image\`.
3669
+ */
3670
+ backgroundBehavior?: 'opaque' | 'transparent';
3671
+ /**
3672
+ * Whether the input is a color or not. Only available for \`string\` input type.
3673
+ */
3674
+ color?: boolean;
3675
+ /**
3676
+ * Whether this input affects the model's cost calculation
3677
+ */
3678
+ costImpact?: boolean;
3679
+ /**
3680
+ * The default value for the input
3681
+ */
3682
+ default?: unknown;
3683
+ /**
3684
+ * Help text displayed in the UI to provide additional information about the input
3685
+ */
3686
+ description?: string;
3687
+ /**
3688
+ * Used to visually group inputs together in the UI. Inputs with the same group
3689
+ * value appear consecutively in the UI.
3690
+ */
3691
+ group?: string;
3692
+ /**
3693
+ * Hint text displayed in the UI as a tooltip to guide the user
3694
+ */
3695
+ hint?: string;
3696
+ /**
3697
+ * The list of inputs which form an object within a container array. All inputs are
3698
+ * the same as the current object. This is only available for type inputs_array
3699
+ * inputs.
3700
+ */
3701
+ inputs?: Array<{
3702
+ [key: string]: unknown;
3703
+ }>;
3704
+ /**
3705
+ * The asset kind of the input. Only taken into account for \`file\` and
3706
+ * \`file_array\` input types. If model provides multiple kinds, the input will be
3707
+ * not able to create the asset on the flight on API side with dataurl without
3708
+ * data:kind, prefix
3709
+ */
3710
+ kind?: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
3711
+ /**
3712
+ * The label displayed in the UI for this input
3713
+ */
3714
+ label?: string;
3715
+ /**
3716
+ * The name of the file input field to use as the mask source
3717
+ */
3718
+ maskFrom?: string;
3719
+ /**
3720
+ * The maximum allowed value. Only available for \`number\` and \`array\` input
3721
+ * types.
3722
+ */
3723
+ max?: number;
3724
+ /**
3725
+ * The maximum allowed length for \`string\` inputs. Also applies to each item in
3726
+ * \`string_array\`.
3727
+ */
3728
+ maxLength?: number;
3729
+ /**
3730
+ * The maximum allowed file size in bytes. Only applies to \`file\` and
3731
+ * \`file_array\` input types. Validated against \`asset.properties.size\` at job
3732
+ * creation time.
3733
+ */
3734
+ maxSize?: number;
3735
+ /**
3736
+ * The minimum allowed value. Only available for \`number\` and array input types.
3737
+ */
3738
+ min?: number;
3739
+ /**
3740
+ * The minimum allowed length for string inputs. Also applies to each item in
3741
+ * \`string_array\`.
3742
+ */
3743
+ minLength?: number;
3744
+ /**
3745
+ * The allowed model types for this input. Example: \`["flux.1-lora"]\`. Only
3746
+ * available for \`model_array\` input type.
3747
+ */
3748
+ modelTypes?: Array<'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' | 'sd-1_5' | 'sd-1_5-composition' | 'sd-1_5-lora' | 'sd-xl' | 'sd-xl-composition' | 'sd-xl-lora' | 'zimage-de-turbo-lora' | 'zimage-lora' | 'zimage-turbo-lora'>;
3749
+ /**
3750
+ * Whether this input represents a parent asset to assign to the produced assets.
3751
+ * Only available for \`file\` and \`file_array\` input types.
3752
+ *
3753
+ * For \`file_array\`, the parent asset is the first item in the array.
3754
+ */
3755
+ parent?: boolean;
3756
+ /**
3757
+ * Placeholder text for the input. Only available for 'string' input type.
3758
+ */
3759
+ placeholder?: string;
3760
+ /**
3761
+ * Whether the input is a prompt. When true, displays as a text area with prompt
3762
+ * spark feature. Only available for \`string\` input type.
3763
+ */
3764
+ prompt?: boolean;
3765
+ /**
3766
+ * Whether the input is used with prompt spark. Only available for \`string\` input
3767
+ * type.
3768
+ */
3769
+ promptSpark?: boolean;
3770
+ /**
3771
+ * Set of rules that describes when this input is required:
3772
+ *
3773
+ * - \`always\`: Input is always required
3774
+ * - \`ifNotDefined\`: Input is required when another specified input is not
3775
+ * defined
3776
+ * - \`ifDefined\`: Input is required when another specified input is defined
3777
+ * - \`conditionalValues\`: Input is required when another input has a specific
3778
+ * value
3779
+ *
3780
+ * By default, the input is not required.
3781
+ */
3782
+ required?: Input.Required;
3783
+ /**
3784
+ * The step increment for numeric inputs. Only available for \`number\` input type.
3785
+ */
3786
+ step?: number;
3787
+ }
3788
+ namespace Input {
3789
+ /**
3790
+ * Set of rules that describes when this input is required:
3791
+ *
3792
+ * - \`always\`: Input is always required
3793
+ * - \`ifNotDefined\`: Input is required when another specified input is not
3794
+ * defined
3795
+ * - \`ifDefined\`: Input is required when another specified input is defined
3796
+ * - \`conditionalValues\`: Input is required when another input has a specific
3797
+ * value
3798
+ *
3799
+ * By default, the input is not required.
3800
+ */
3801
+ interface Required {
3755
3802
  /**
3756
- * The allowed model types for this input. Example: \`["flux.1-lora"]\`. Only
3757
- * available for \`model_array\` input type.
3803
+ * Whether the input is always required
3758
3804
  */
3759
- modelTypes?: Array<'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' | 'sd-1_5' | 'sd-1_5-composition' | 'sd-1_5-lora' | 'sd-xl' | 'sd-xl-composition' | 'sd-xl-lora' | 'zimage-de-turbo-lora' | 'zimage-lora' | 'zimage-turbo-lora'>;
3805
+ always?: boolean;
3760
3806
  /**
3761
- * Whether this input represents a parent asset to assign to the produced assets.
3762
- * Only available for \`file\` and \`file_array\` input types.
3807
+ * Makes this input required when another input has a specific value:
3763
3808
  *
3764
- * For \`file_array\`, the parent asset is the first item in the array.
3765
- */
3766
- parent?: boolean;
3767
- /**
3768
- * Placeholder text for the input. Only available for 'string' input type.
3769
- */
3770
- placeholder?: string;
3771
- /**
3772
- * Whether the input is a prompt. When true, displays as a text area with prompt
3773
- * spark feature. Only available for \`string\` input type.
3774
- */
3775
- prompt?: boolean;
3776
- /**
3777
- * Whether the input is used with prompt spark. Only available for \`string\` input
3778
- * type.
3809
+ * - Key: name of the input to check
3810
+ * - Value: operation and allowed values that trigger the requirement
3779
3811
  */
3780
- promptSpark?: boolean;
3812
+ conditionalValues?: unknown;
3781
3813
  /**
3782
- * Set of rules that describes when this input is required:
3783
- *
3784
- * - \`always\`: Input is always required
3785
- * - \`ifNotDefined\`: Input is required when another specified input is not
3786
- * defined
3787
- * - \`ifDefined\`: Input is required when another specified input is defined
3788
- * - \`conditionalValues\`: Input is required when another input has a specific
3789
- * value
3814
+ * Makes this input required when another input is defined:
3790
3815
  *
3791
- * By default, the input is not required.
3792
- */
3793
- required?: Input.Required;
3794
- /**
3795
- * The step increment for numeric inputs. Only available for \`number\` input type.
3816
+ * - Key: name of the input that must be defined
3817
+ * - Value: message to display when this input is required
3796
3818
  */
3797
- step?: number;
3798
- }
3799
- namespace Input {
3819
+ ifDefined?: unknown;
3800
3820
  /**
3801
- * Set of rules that describes when this input is required:
3802
- *
3803
- * - \`always\`: Input is always required
3804
- * - \`ifNotDefined\`: Input is required when another specified input is not
3805
- * defined
3806
- * - \`ifDefined\`: Input is required when another specified input is defined
3807
- * - \`conditionalValues\`: Input is required when another input has a specific
3808
- * value
3821
+ * Makes this input required when another input is not defined:
3809
3822
  *
3810
- * By default, the input is not required.
3823
+ * - Key: name of the input that must be undefined
3824
+ * - Value: message to display when this input is required
3811
3825
  */
3812
- interface Required {
3813
- /**
3814
- * Whether the input is always required
3815
- */
3816
- always?: boolean;
3817
- /**
3818
- * Makes this input required when another input has a specific value:
3819
- *
3820
- * - Key: name of the input to check
3821
- * - Value: operation and allowed values that trigger the requirement
3822
- */
3823
- conditionalValues?: unknown;
3824
- /**
3825
- * Makes this input required when another input is defined:
3826
- *
3827
- * - Key: name of the input that must be defined
3828
- * - Value: message to display when this input is required
3829
- */
3830
- ifDefined?: unknown;
3831
- /**
3832
- * Makes this input required when another input is not defined:
3833
- *
3834
- * - Key: name of the input that must be undefined
3835
- * - Value: message to display when this input is required
3836
- */
3837
- ifNotDefined?: unknown;
3838
- }
3826
+ ifNotDefined?: unknown;
3839
3827
  }
3828
+ }
3829
+ /**
3830
+ * A representation of an asset after being processed by the workflow
3831
+ */
3832
+ interface After {
3840
3833
  /**
3841
- * A representation of an asset after being processed by the workflow
3834
+ * The AssetId of the image used as a thumbnail for your model (example:
3835
+ * "asset_GTrL3mq4SXWyMxkOHRxlpw")
3842
3836
  */
3843
- interface After {
3844
- /**
3845
- * The AssetId of the image used as a thumbnail for your model (example:
3846
- * "asset_GTrL3mq4SXWyMxkOHRxlpw")
3847
- */
3848
- assetId: string;
3849
- /**
3850
- * The url of the image used as a thumbnail for your model
3851
- */
3852
- url: string;
3853
- }
3837
+ assetId: string;
3854
3838
  /**
3855
- * A representation of an asset before being processed by the workflow
3839
+ * The url of the image used as a thumbnail for your model
3856
3840
  */
3857
- interface Before {
3858
- /**
3859
- * The AssetId of the image used as a thumbnail for your model (example:
3860
- * "asset_GTrL3mq4SXWyMxkOHRxlpw")
3861
- */
3862
- assetId: string;
3863
- /**
3864
- * The url of the image used as a thumbnail for your model
3865
- */
3866
- url: string;
3867
- }
3841
+ url: string;
3842
+ }
3843
+ /**
3844
+ * A representation of an asset before being processed by the workflow
3845
+ */
3846
+ interface Before {
3868
3847
  /**
3869
- * Currently the thumbnail is identical to the after asset.
3848
+ * The AssetId of the image used as a thumbnail for your model (example:
3849
+ * "asset_GTrL3mq4SXWyMxkOHRxlpw")
3870
3850
  */
3871
- interface Thumbnail {
3872
- assetId: string;
3873
- url: string;
3851
+ assetId: string;
3852
+ /**
3853
+ * The url of the image used as a thumbnail for your model
3854
+ */
3855
+ url: string;
3856
+ }
3857
+ /**
3858
+ * Currently the thumbnail is identical to the after asset.
3859
+ */
3860
+ interface Thumbnail {
3861
+ assetId: string;
3862
+ url: string;
3863
+ }
3864
+ /**
3865
+ * The UI configuration for the workflow. This is managed by scenario webapp.
3866
+ */
3867
+ interface UiConfig {
3868
+ /**
3869
+ * Configuration for the input properties
3870
+ */
3871
+ inputProperties?: {
3872
+ [key: string]: UiConfig.InputProperties;
3873
+ };
3874
+ /**
3875
+ * Configuration for the loras component
3876
+ */
3877
+ lorasComponent?: UiConfig.LorasComponent;
3878
+ /**
3879
+ * Configuration for the presets
3880
+ */
3881
+ presets?: Array<UiConfig.Preset>;
3882
+ /**
3883
+ * Configuration for the resolution component
3884
+ */
3885
+ resolutionComponent?: UiConfig.ResolutionComponent;
3886
+ /**
3887
+ * Configuration for the selects
3888
+ */
3889
+ selects?: {
3890
+ [key: string]: unknown;
3891
+ };
3892
+ /**
3893
+ * Configuration for the trigger generate button
3894
+ */
3895
+ triggerGenerate?: UiConfig.TriggerGenerate;
3896
+ }
3897
+ namespace UiConfig {
3898
+ interface InputProperties {
3899
+ collapsed?: boolean;
3874
3900
  }
3875
3901
  /**
3876
- * The UI configuration for the workflow. This is managed by scenario webapp.
3902
+ * Configuration for the loras component
3877
3903
  */
3878
- interface UiConfig {
3904
+ interface LorasComponent {
3879
3905
  /**
3880
- * Configuration for the input properties
3906
+ * The label of the component
3881
3907
  */
3882
- inputProperties?: {
3883
- [key: string]: UiConfig.InputProperties;
3884
- };
3908
+ label: string;
3885
3909
  /**
3886
- * Configuration for the loras component
3910
+ * The input name of the model (model_array)
3887
3911
  */
3888
- lorasComponent?: UiConfig.LorasComponent;
3912
+ modelInput: string;
3889
3913
  /**
3890
- * Configuration for the presets
3914
+ * The input name of the scale (number_array)
3891
3915
  */
3892
- presets?: Array<UiConfig.Preset>;
3916
+ scaleInput: string;
3893
3917
  /**
3894
- * Configuration for the resolution component
3918
+ * The input model id (example: a composition or a single LoRA modelId) If
3919
+ * specified, the model id will be attached to the output asset as a metadata If
3920
+ * the model-decomposer parser is specified on it, modelInput and scaleInput will
3921
+ * be automatically populated
3895
3922
  */
3896
- resolutionComponent?: UiConfig.ResolutionComponent;
3923
+ modelIdInput?: string;
3924
+ }
3925
+ interface Preset {
3926
+ fields: Array<string>;
3927
+ presets: unknown;
3928
+ }
3929
+ /**
3930
+ * Configuration for the resolution component
3931
+ */
3932
+ interface ResolutionComponent {
3897
3933
  /**
3898
- * Configuration for the selects
3934
+ * The input name of the height
3899
3935
  */
3900
- selects?: {
3901
- [key: string]: unknown;
3902
- };
3936
+ heightInput: string;
3903
3937
  /**
3904
- * Configuration for the trigger generate button
3938
+ * The label of the component
3905
3939
  */
3906
- triggerGenerate?: UiConfig.TriggerGenerate;
3907
- }
3908
- namespace UiConfig {
3909
- interface InputProperties {
3910
- collapsed?: boolean;
3911
- }
3940
+ label: string;
3912
3941
  /**
3913
- * Configuration for the loras component
3942
+ * The resolution presets
3914
3943
  */
3915
- interface LorasComponent {
3916
- /**
3917
- * The label of the component
3918
- */
3919
- label: string;
3920
- /**
3921
- * The input name of the model (model_array)
3922
- */
3923
- modelInput: string;
3924
- /**
3925
- * The input name of the scale (number_array)
3926
- */
3927
- scaleInput: string;
3928
- /**
3929
- * The input model id (example: a composition or a single LoRA modelId) If
3930
- * specified, the model id will be attached to the output asset as a metadata If
3931
- * the model-decomposer parser is specified on it, modelInput and scaleInput will
3932
- * be automatically populated
3933
- */
3934
- modelIdInput?: string;
3935
- }
3936
- interface Preset {
3937
- fields: Array<string>;
3938
- presets: unknown;
3939
- }
3944
+ presets: Array<ResolutionComponent.Preset>;
3940
3945
  /**
3941
- * Configuration for the resolution component
3946
+ * The input name of the width
3942
3947
  */
3943
- interface ResolutionComponent {
3944
- /**
3945
- * The input name of the height
3946
- */
3947
- heightInput: string;
3948
- /**
3949
- * The label of the component
3950
- */
3948
+ widthInput: string;
3949
+ }
3950
+ namespace ResolutionComponent {
3951
+ interface Preset {
3952
+ height: number;
3951
3953
  label: string;
3952
- /**
3953
- * The resolution presets
3954
- */
3955
- presets: Array<ResolutionComponent.Preset>;
3956
- /**
3957
- * The input name of the width
3958
- */
3959
- widthInput: string;
3960
- }
3961
- namespace ResolutionComponent {
3962
- interface Preset {
3963
- height: number;
3964
- label: string;
3965
- width: number;
3966
- }
3954
+ width: number;
3967
3955
  }
3956
+ }
3957
+ /**
3958
+ * Configuration for the trigger generate button
3959
+ */
3960
+ interface TriggerGenerate {
3961
+ label: string;
3968
3962
  /**
3969
- * Configuration for the trigger generate button
3963
+ * The 'name' of the input where the trigger generate button will be displayed
3964
+ * (after the input). Do not specify both position and after.
3970
3965
  */
3971
- interface TriggerGenerate {
3972
- label: string;
3973
- /**
3974
- * The 'name' of the input where the trigger generate button will be displayed
3975
- * (after the input). Do not specify both position and after.
3976
- */
3977
- after?: string;
3978
- /**
3979
- * The position of the trigger generate button. If position specified, the button
3980
- * will be displayed at the specified position. Do not specify both position and
3981
- * after.
3982
- */
3983
- position?: 'bottom' | 'top';
3984
- }
3966
+ after?: string;
3967
+ /**
3968
+ * The position of the trigger generate button. If position specified, the button
3969
+ * will be displayed at the specified position. Do not specify both position and
3970
+ * after.
3971
+ */
3972
+ position?: 'bottom' | 'top';
3985
3973
  }
3986
3974
  }
3987
3975
  }
@@ -7123,16 +7111,12 @@ export declare namespace WorkflowUpdateParams {
7123
7111
  }
7124
7112
  }
7125
7113
  }
7126
- export interface WorkflowListParams {
7114
+ export interface WorkflowListParams extends WorkflowsCursorParams {
7127
7115
  /**
7128
7116
  * The number of items to return in the response. The default value is 10, maximum
7129
7117
  * value is 200, minimum value is 1
7130
7118
  */
7131
7119
  pageSize?: number;
7132
- /**
7133
- * A token you received in a previous request to query the next page of items
7134
- */
7135
- paginationToken?: string;
7136
7120
  /**
7137
7121
  * The privacy of the workflows to return. The default value is `private`, possible
7138
7122
  * values are `private`, `public` and `unlisted`. Default value is `private`.
@@ -7171,6 +7155,6 @@ export interface WorkflowRunParams {
7171
7155
  dryRun?: unknown;
7172
7156
  }
7173
7157
  export declare namespace Workflows {
7174
- export { type WorkflowCreateResponse as WorkflowCreateResponse, type WorkflowRetrieveResponse as WorkflowRetrieveResponse, type WorkflowUpdateResponse as WorkflowUpdateResponse, type WorkflowListResponse as WorkflowListResponse, type WorkflowDeleteResponse as WorkflowDeleteResponse, type WorkflowApproveUserResponse as WorkflowApproveUserResponse, type WorkflowGetTagsResponse as WorkflowGetTagsResponse, type WorkflowRunResponse as WorkflowRunResponse, type WorkflowCreateParams as WorkflowCreateParams, type WorkflowUpdateParams as WorkflowUpdateParams, type WorkflowListParams as WorkflowListParams, type WorkflowApproveUserParams as WorkflowApproveUserParams, type WorkflowGetTagsParams as WorkflowGetTagsParams, type WorkflowRunParams as WorkflowRunParams, };
7158
+ export { type WorkflowCreateResponse as WorkflowCreateResponse, type WorkflowRetrieveResponse as WorkflowRetrieveResponse, type WorkflowUpdateResponse as WorkflowUpdateResponse, type WorkflowListResponse as WorkflowListResponse, type WorkflowDeleteResponse as WorkflowDeleteResponse, type WorkflowApproveUserResponse as WorkflowApproveUserResponse, type WorkflowGetTagsResponse as WorkflowGetTagsResponse, type WorkflowRunResponse as WorkflowRunResponse, type WorkflowListResponsesWorkflowsCursor as WorkflowListResponsesWorkflowsCursor, type WorkflowCreateParams as WorkflowCreateParams, type WorkflowUpdateParams as WorkflowUpdateParams, type WorkflowListParams as WorkflowListParams, type WorkflowApproveUserParams as WorkflowApproveUserParams, type WorkflowGetTagsParams as WorkflowGetTagsParams, type WorkflowRunParams as WorkflowRunParams, };
7175
7159
  }
7176
7160
  //# sourceMappingURL=workflows.d.ts.map