@scenario-labs/sdk 2.0.0 → 2.2.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 (269) hide show
  1. package/CHANGELOG.md +40 -0
  2. package/api-promise.d.mts +1 -0
  3. package/api-promise.d.mts.map +1 -1
  4. package/api-promise.d.ts +1 -0
  5. package/api-promise.d.ts.map +1 -1
  6. package/api-promise.mjs +1 -0
  7. package/api-promise.mjs.map +1 -1
  8. package/client.d.mts.map +1 -1
  9. package/client.d.ts.map +1 -1
  10. package/client.mjs.map +1 -1
  11. package/core/api-promise.d.mts.map +1 -1
  12. package/core/api-promise.d.ts.map +1 -1
  13. package/core/api-promise.mjs.map +1 -1
  14. package/core/error.mjs.map +1 -1
  15. package/core/pagination.d.mts.map +1 -1
  16. package/core/pagination.d.ts.map +1 -1
  17. package/core/pagination.mjs.map +1 -1
  18. package/core/resource.d.mts.map +1 -1
  19. package/core/resource.d.ts.map +1 -1
  20. package/core/uploads.d.mts.map +1 -1
  21. package/core/uploads.d.ts.map +1 -1
  22. package/core/uploads.mjs.map +1 -1
  23. package/error.d.mts +1 -0
  24. package/error.d.mts.map +1 -1
  25. package/error.d.ts +1 -0
  26. package/error.d.ts.map +1 -1
  27. package/error.mjs +1 -0
  28. package/error.mjs.map +1 -1
  29. package/index.d.mts +1 -1
  30. package/index.d.mts.map +1 -1
  31. package/index.d.ts +1 -1
  32. package/index.d.ts.map +1 -1
  33. package/index.js +6 -1
  34. package/index.js.map +1 -1
  35. package/index.mjs +1 -1
  36. package/index.mjs.map +1 -1
  37. package/internal/detect-platform.mjs.map +1 -1
  38. package/internal/headers.mjs.map +1 -1
  39. package/internal/parse.d.mts.map +1 -1
  40. package/internal/parse.d.ts.map +1 -1
  41. package/internal/parse.mjs.map +1 -1
  42. package/internal/qs/formats.d.mts.map +1 -1
  43. package/internal/qs/formats.d.ts.map +1 -1
  44. package/internal/qs/index.d.mts +2 -2
  45. package/internal/qs/index.d.mts.map +1 -1
  46. package/internal/qs/index.d.ts +2 -2
  47. package/internal/qs/index.d.ts.map +1 -1
  48. package/internal/qs/index.mjs.map +1 -1
  49. package/internal/qs/stringify.d.mts.map +1 -1
  50. package/internal/qs/stringify.d.ts.map +1 -1
  51. package/internal/qs/stringify.mjs.map +1 -1
  52. package/internal/qs/utils.d.mts.map +1 -1
  53. package/internal/qs/utils.d.ts.map +1 -1
  54. package/internal/qs/utils.mjs.map +1 -1
  55. package/internal/request-options.d.mts.map +1 -1
  56. package/internal/request-options.d.ts.map +1 -1
  57. package/internal/shims.d.mts +6 -0
  58. package/internal/shims.d.mts.map +1 -1
  59. package/internal/shims.d.ts +6 -0
  60. package/internal/shims.d.ts.map +1 -1
  61. package/internal/to-file.d.mts.map +1 -1
  62. package/internal/to-file.d.ts.map +1 -1
  63. package/internal/to-file.mjs.map +1 -1
  64. package/internal/types.d.mts +4 -4
  65. package/internal/types.d.mts.map +1 -1
  66. package/internal/types.d.ts +4 -4
  67. package/internal/types.d.ts.map +1 -1
  68. package/internal/uploads.d.mts.map +1 -1
  69. package/internal/uploads.d.ts.map +1 -1
  70. package/internal/uploads.mjs.map +1 -1
  71. package/internal/utils/base64.mjs.map +1 -1
  72. package/internal/utils/log.d.mts.map +1 -1
  73. package/internal/utils/log.d.ts.map +1 -1
  74. package/internal/utils/log.mjs.map +1 -1
  75. package/internal/utils/path.mjs.map +1 -1
  76. package/internal/utils/query.mjs.map +1 -1
  77. package/internal/utils/values.mjs.map +1 -1
  78. package/internal/utils.d.mts.map +1 -1
  79. package/internal/utils.d.ts.map +1 -1
  80. package/internal/utils.mjs.map +1 -1
  81. package/lib/asset.d.mts.map +1 -1
  82. package/lib/asset.d.ts.map +1 -1
  83. package/lib/asset.mjs.map +1 -1
  84. package/lib/generate.d.mts.map +1 -1
  85. package/lib/generate.d.ts.map +1 -1
  86. package/lib/generate.mjs.map +1 -1
  87. package/lib/job.d.mts.map +1 -1
  88. package/lib/job.d.ts.map +1 -1
  89. package/lib/job.mjs.map +1 -1
  90. package/lib/models.d.mts.map +1 -1
  91. package/lib/models.d.ts.map +1 -1
  92. package/lib/models.mjs.map +1 -1
  93. package/lib/scenario.d.mts.map +1 -1
  94. package/lib/scenario.d.ts.map +1 -1
  95. package/lib/scenario.mjs.map +1 -1
  96. package/lib/upload.d.mts.map +1 -1
  97. package/lib/upload.d.ts.map +1 -1
  98. package/lib/upload.mjs.map +1 -1
  99. package/lib/workflow.d.mts.map +1 -1
  100. package/lib/workflow.d.ts.map +1 -1
  101. package/lib/workflow.mjs.map +1 -1
  102. package/lib/workflow_converter.d.mts +58 -2
  103. package/lib/workflow_converter.d.mts.map +1 -1
  104. package/lib/workflow_converter.d.ts +58 -2
  105. package/lib/workflow_converter.d.ts.map +1 -1
  106. package/lib/workflow_converter.js +350 -35
  107. package/lib/workflow_converter.js.map +1 -1
  108. package/lib/workflow_converter.mjs +345 -35
  109. package/lib/workflow_converter.mjs.map +1 -1
  110. package/lib/workflow_import_validator.d.mts +1 -1
  111. package/lib/workflow_import_validator.d.mts.map +1 -1
  112. package/lib/workflow_import_validator.d.ts +1 -1
  113. package/lib/workflow_import_validator.d.ts.map +1 -1
  114. package/lib/workflow_import_validator.js +1 -0
  115. package/lib/workflow_import_validator.js.map +1 -1
  116. package/lib/workflow_import_validator.mjs +1 -0
  117. package/lib/workflow_import_validator.mjs.map +1 -1
  118. package/package.json +1 -1
  119. package/pagination.d.mts +1 -0
  120. package/pagination.d.mts.map +1 -1
  121. package/pagination.d.ts +1 -0
  122. package/pagination.d.ts.map +1 -1
  123. package/pagination.mjs +1 -0
  124. package/pagination.mjs.map +1 -1
  125. package/resource.d.mts +1 -0
  126. package/resource.d.mts.map +1 -1
  127. package/resource.d.ts +1 -0
  128. package/resource.d.ts.map +1 -1
  129. package/resource.mjs +1 -0
  130. package/resource.mjs.map +1 -1
  131. package/resources/assets/assets.d.mts +289 -135
  132. package/resources/assets/assets.d.mts.map +1 -1
  133. package/resources/assets/assets.d.ts +289 -135
  134. package/resources/assets/assets.d.ts.map +1 -1
  135. package/resources/assets/assets.js.map +1 -1
  136. package/resources/assets/assets.mjs.map +1 -1
  137. package/resources/assets/download.d.mts.map +1 -1
  138. package/resources/assets/download.d.ts.map +1 -1
  139. package/resources/assets/download.mjs.map +1 -1
  140. package/resources/assets/index.d.mts.map +1 -1
  141. package/resources/assets/index.d.ts.map +1 -1
  142. package/resources/assets/index.mjs.map +1 -1
  143. package/resources/assets.d.mts.map +1 -1
  144. package/resources/assets.d.ts.map +1 -1
  145. package/resources/assets.mjs.map +1 -1
  146. package/resources/collections/assets.d.mts.map +1 -1
  147. package/resources/collections/assets.d.ts.map +1 -1
  148. package/resources/collections/assets.mjs.map +1 -1
  149. package/resources/collections/collections.d.mts.map +1 -1
  150. package/resources/collections/collections.d.ts.map +1 -1
  151. package/resources/collections/collections.mjs.map +1 -1
  152. package/resources/collections/index.d.mts.map +1 -1
  153. package/resources/collections/index.d.ts.map +1 -1
  154. package/resources/collections/index.mjs.map +1 -1
  155. package/resources/collections/models.d.mts.map +1 -1
  156. package/resources/collections/models.d.ts.map +1 -1
  157. package/resources/collections/models.mjs.map +1 -1
  158. package/resources/collections.d.mts.map +1 -1
  159. package/resources/collections.d.ts.map +1 -1
  160. package/resources/collections.mjs.map +1 -1
  161. package/resources/generate.d.mts +86 -48
  162. package/resources/generate.d.mts.map +1 -1
  163. package/resources/generate.d.ts +86 -48
  164. package/resources/generate.d.ts.map +1 -1
  165. package/resources/generate.mjs.map +1 -1
  166. package/resources/index.d.mts.map +1 -1
  167. package/resources/index.d.ts.map +1 -1
  168. package/resources/index.mjs.map +1 -1
  169. package/resources/jobs.d.mts +6 -6
  170. package/resources/jobs.d.mts.map +1 -1
  171. package/resources/jobs.d.ts +6 -6
  172. package/resources/jobs.d.ts.map +1 -1
  173. package/resources/jobs.mjs.map +1 -1
  174. package/resources/models/description.d.mts +54 -4
  175. package/resources/models/description.d.mts.map +1 -1
  176. package/resources/models/description.d.ts +54 -4
  177. package/resources/models/description.d.ts.map +1 -1
  178. package/resources/models/description.mjs.map +1 -1
  179. package/resources/models/examples.d.mts +74 -36
  180. package/resources/models/examples.d.mts.map +1 -1
  181. package/resources/models/examples.d.ts +74 -36
  182. package/resources/models/examples.d.ts.map +1 -1
  183. package/resources/models/examples.mjs.map +1 -1
  184. package/resources/models/index.d.mts.map +1 -1
  185. package/resources/models/index.d.ts.map +1 -1
  186. package/resources/models/index.mjs.map +1 -1
  187. package/resources/models/models.d.mts +21 -21
  188. package/resources/models/models.d.mts.map +1 -1
  189. package/resources/models/models.d.ts +21 -21
  190. package/resources/models/models.d.ts.map +1 -1
  191. package/resources/models/models.js.map +1 -1
  192. package/resources/models/models.mjs.map +1 -1
  193. package/resources/models/train.d.mts +8 -8
  194. package/resources/models/train.d.mts.map +1 -1
  195. package/resources/models/train.d.ts +8 -8
  196. package/resources/models/train.d.ts.map +1 -1
  197. package/resources/models/train.mjs.map +1 -1
  198. package/resources/models/training-images.d.mts.map +1 -1
  199. package/resources/models/training-images.d.ts.map +1 -1
  200. package/resources/models/training-images.mjs.map +1 -1
  201. package/resources/models.d.mts.map +1 -1
  202. package/resources/models.d.ts.map +1 -1
  203. package/resources/models.mjs.map +1 -1
  204. package/resources/oscu.d.mts.map +1 -1
  205. package/resources/oscu.d.ts.map +1 -1
  206. package/resources/oscu.mjs.map +1 -1
  207. package/resources/pricing/index.d.mts.map +1 -1
  208. package/resources/pricing/index.d.ts.map +1 -1
  209. package/resources/pricing/index.mjs.map +1 -1
  210. package/resources/pricing/oscu.d.mts.map +1 -1
  211. package/resources/pricing/oscu.d.ts.map +1 -1
  212. package/resources/pricing/oscu.mjs.map +1 -1
  213. package/resources/pricing/pricing.d.mts.map +1 -1
  214. package/resources/pricing/pricing.d.ts.map +1 -1
  215. package/resources/pricing/pricing.mjs.map +1 -1
  216. package/resources/pricing.d.mts.map +1 -1
  217. package/resources/pricing.d.ts.map +1 -1
  218. package/resources/pricing.mjs.map +1 -1
  219. package/resources/search.d.mts +6 -0
  220. package/resources/search.d.mts.map +1 -1
  221. package/resources/search.d.ts +6 -0
  222. package/resources/search.d.ts.map +1 -1
  223. package/resources/search.mjs.map +1 -1
  224. package/resources/tags.d.mts.map +1 -1
  225. package/resources/tags.d.ts.map +1 -1
  226. package/resources/tags.mjs.map +1 -1
  227. package/resources/uploads.d.mts +4 -4
  228. package/resources/uploads.d.mts.map +1 -1
  229. package/resources/uploads.d.ts +4 -4
  230. package/resources/uploads.d.ts.map +1 -1
  231. package/resources/uploads.mjs.map +1 -1
  232. package/resources/usages.d.mts +31 -6
  233. package/resources/usages.d.mts.map +1 -1
  234. package/resources/usages.d.ts +31 -6
  235. package/resources/usages.d.ts.map +1 -1
  236. package/resources/usages.mjs.map +1 -1
  237. package/resources/workflows.d.mts +36 -36
  238. package/resources/workflows.d.mts.map +1 -1
  239. package/resources/workflows.d.ts +36 -36
  240. package/resources/workflows.d.ts.map +1 -1
  241. package/resources/workflows.mjs.map +1 -1
  242. package/resources.d.mts.map +1 -1
  243. package/resources.d.ts.map +1 -1
  244. package/resources.mjs.map +1 -1
  245. package/src/index.ts +9 -0
  246. package/src/lib/workflow_converter.ts +487 -28
  247. package/src/lib/workflow_import_validator.ts +2 -0
  248. package/src/resources/assets/assets.ts +376 -118
  249. package/src/resources/generate.ts +106 -44
  250. package/src/resources/jobs.ts +6 -6
  251. package/src/resources/models/description.ts +68 -2
  252. package/src/resources/models/examples.ts +94 -32
  253. package/src/resources/models/models.ts +21 -14
  254. package/src/resources/models/train.ts +8 -6
  255. package/src/resources/search.ts +7 -0
  256. package/src/resources/uploads.ts +4 -4
  257. package/src/resources/usages.ts +41 -4
  258. package/src/resources/workflows.ts +36 -36
  259. package/src/version.ts +1 -1
  260. package/uploads.d.mts +1 -0
  261. package/uploads.d.mts.map +1 -1
  262. package/uploads.d.ts +1 -0
  263. package/uploads.d.ts.map +1 -1
  264. package/uploads.mjs +1 -0
  265. package/uploads.mjs.map +1 -1
  266. package/version.d.mts +1 -1
  267. package/version.d.ts +1 -1
  268. package/version.js +1 -1
  269. package/version.mjs +1 -1
@@ -193,7 +193,7 @@ export namespace AssetRetrieveResponse {
193
193
  /**
194
194
  * The kind of asset
195
195
  */
196
- kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
196
+ kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'text' | 'video';
197
197
 
198
198
  /**
199
199
  * Metadata of the asset with some additional information
@@ -234,6 +234,7 @@ export namespace AssetRetrieveResponse {
234
234
  | '3d:texture:normal'
235
235
  | '3d:texture:roughness'
236
236
  | 'audio2audio'
237
+ | 'audio2txt'
237
238
  | 'audio2video'
238
239
  | 'background-removal'
239
240
  | 'canvas'
@@ -244,6 +245,7 @@ export namespace AssetRetrieveResponse {
244
245
  | 'image-prompt-editing'
245
246
  | 'img23d'
246
247
  | 'img2img'
248
+ | 'img2txt'
247
249
  | 'img2video'
248
250
  | 'inference-control-net'
249
251
  | 'inference-control-net-img'
@@ -283,12 +285,14 @@ export namespace AssetRetrieveResponse {
283
285
  | 'txt23d'
284
286
  | 'txt2audio'
285
287
  | 'txt2img'
288
+ | 'txt2txt'
286
289
  | 'txt2video'
287
290
  | 'unknown'
288
291
  | 'uploaded'
289
292
  | 'uploaded-3d'
290
293
  | 'uploaded-audio'
291
294
  | 'uploaded-avatar'
295
+ | 'uploaded-text'
292
296
  | 'uploaded-video'
293
297
  | 'upscale'
294
298
  | 'upscale-skybox'
@@ -403,7 +407,7 @@ export namespace AssetRetrieveResponse {
403
407
  * Metadata of the asset with some additional information
404
408
  */
405
409
  export interface Metadata {
406
- kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
410
+ kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'text' | 'video';
407
411
 
408
412
  /**
409
413
  * The type of the asset. Ex: 'inference-txt2img' will represent an asset generated
@@ -419,6 +423,7 @@ export namespace AssetRetrieveResponse {
419
423
  | '3d23d'
420
424
  | '3d23d-texture'
421
425
  | 'audio2audio'
426
+ | 'audio2txt'
422
427
  | 'audio2video'
423
428
  | 'background-removal'
424
429
  | 'canvas'
@@ -429,6 +434,7 @@ export namespace AssetRetrieveResponse {
429
434
  | 'image-prompt-editing'
430
435
  | 'img23d'
431
436
  | 'img2img'
437
+ | 'img2txt'
432
438
  | 'img2video'
433
439
  | 'inference-controlnet'
434
440
  | 'inference-controlnet-img2img'
@@ -468,12 +474,14 @@ export namespace AssetRetrieveResponse {
468
474
  | 'txt23d'
469
475
  | 'txt2audio'
470
476
  | 'txt2img'
477
+ | 'txt2txt'
471
478
  | 'txt2video'
472
479
  | 'unknown'
473
480
  | 'uploaded'
474
481
  | 'uploaded-3d'
475
482
  | 'uploaded-audio'
476
483
  | 'uploaded-avatar'
484
+ | 'uploaded-text'
477
485
  | 'uploaded-video'
478
486
  | 'upscale'
479
487
  | 'upscale-skybox'
@@ -497,10 +505,6 @@ export namespace AssetRetrieveResponse {
497
505
  */
498
506
  aspectRatio?: string;
499
507
 
500
- /**
501
- * Int to set between 0 and 255 for the opacity of the background in the result
502
- * images.
503
- */
504
508
  backgroundOpacity?: number;
505
509
 
506
510
  /**
@@ -513,9 +517,6 @@ export namespace AssetRetrieveResponse {
513
517
  */
514
518
  bbox?: Array<number>;
515
519
 
516
- /**
517
- * Remove small dark spots (i.e. “pepper”) and connect small bright cracks.
518
- */
519
520
  betterQuality?: boolean;
520
521
 
521
522
  /**
@@ -591,9 +592,6 @@ export namespace AssetRetrieveResponse {
591
592
  */
592
593
  detailsLevel?: number;
593
594
 
594
- /**
595
- * The number of pixels to dilate the result masks.
596
- */
597
595
  dilate?: number;
598
596
 
599
597
  /**
@@ -898,12 +896,16 @@ export namespace AssetRetrieveResponse {
898
896
  resultContours?: boolean;
899
897
 
900
898
  /**
901
- * Boolean to able output the cut out object.
899
+ * Boolean to return the source image with the mask applied as alpha channel (RGBA
900
+ * PNG, transparent background) instead of the binary mask. Mutually exclusive with
901
+ * `resultMask` — passing both as `true` returns a 400 error. Note:
902
+ * `backgroundOpacity` is no longer honored — alpha is binary (0/255) only.
902
903
  */
903
904
  resultImage?: boolean;
904
905
 
905
906
  /**
906
- * Boolean to able return the masks (binary image) in the response.
907
+ * Boolean to return the binary masks in the response. Mutually exclusive with
908
+ * `resultImage` — passing both as `true` returns a 400 error.
907
909
  */
908
910
  resultMask?: boolean;
909
911
 
@@ -1123,6 +1125,13 @@ export namespace AssetRetrieveResponse {
1123
1125
  */
1124
1126
  channels?: number;
1125
1127
 
1128
+ /**
1129
+ * Number of Unicode code points in the text. Code-point-aware (so a non-BMP emoji
1130
+ * counts as 1) but not full grapheme-cluster aware (a ZWJ sequence still counts as
1131
+ * several).
1132
+ */
1133
+ charCount?: number;
1134
+
1126
1135
  /**
1127
1136
  * Classification of the audio
1128
1137
  */
@@ -1168,6 +1177,14 @@ export namespace AssetRetrieveResponse {
1168
1177
  */
1169
1178
  hasAnimations?: boolean;
1170
1179
 
1180
+ /**
1181
+ * True when `preview` holds the entire content unmodified — consumers can use it
1182
+ * directly without fetching `asset.url`. False or undefined means the content
1183
+ * exceeds the preview budget and consumers must fetch the full body from S3 to
1184
+ * read past the preview.
1185
+ */
1186
+ hasFullPreview?: boolean;
1187
+
1171
1188
  /**
1172
1189
  * Whether the mesh has normal vectors
1173
1190
  */
@@ -1190,6 +1207,15 @@ export namespace AssetRetrieveResponse {
1190
1207
  */
1191
1208
  nbFrames?: number;
1192
1209
 
1210
+ /**
1211
+ * Leading slice of the content used for inline UI display and as a search
1212
+ * shortcut. Capped at TEXT_PREVIEW_MAX_BYTES (UTF-8) and always cut on a
1213
+ * code-point boundary so no character is split. Number of characters in the
1214
+ * preview varies by script (around 1024 for ASCII, ~340 for CJK, ~256 for
1215
+ * emoji-heavy text at the default 1 KB budget).
1216
+ */
1217
+ preview?: string;
1218
+
1193
1219
  /**
1194
1220
  * Sample rate of the media in Hz
1195
1221
  */
@@ -1206,6 +1232,11 @@ export namespace AssetRetrieveResponse {
1206
1232
  vertexCount?: number;
1207
1233
 
1208
1234
  width?: number;
1235
+
1236
+ /**
1237
+ * Number of whitespace-separated words in the text
1238
+ */
1239
+ wordCount?: number;
1209
1240
  }
1210
1241
 
1211
1242
  export namespace Properties {
@@ -1309,7 +1340,7 @@ export namespace AssetUpdateResponse {
1309
1340
  /**
1310
1341
  * The kind of asset
1311
1342
  */
1312
- kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
1343
+ kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'text' | 'video';
1313
1344
 
1314
1345
  /**
1315
1346
  * Metadata of the asset with some additional information
@@ -1350,6 +1381,7 @@ export namespace AssetUpdateResponse {
1350
1381
  | '3d:texture:normal'
1351
1382
  | '3d:texture:roughness'
1352
1383
  | 'audio2audio'
1384
+ | 'audio2txt'
1353
1385
  | 'audio2video'
1354
1386
  | 'background-removal'
1355
1387
  | 'canvas'
@@ -1360,6 +1392,7 @@ export namespace AssetUpdateResponse {
1360
1392
  | 'image-prompt-editing'
1361
1393
  | 'img23d'
1362
1394
  | 'img2img'
1395
+ | 'img2txt'
1363
1396
  | 'img2video'
1364
1397
  | 'inference-control-net'
1365
1398
  | 'inference-control-net-img'
@@ -1399,12 +1432,14 @@ export namespace AssetUpdateResponse {
1399
1432
  | 'txt23d'
1400
1433
  | 'txt2audio'
1401
1434
  | 'txt2img'
1435
+ | 'txt2txt'
1402
1436
  | 'txt2video'
1403
1437
  | 'unknown'
1404
1438
  | 'uploaded'
1405
1439
  | 'uploaded-3d'
1406
1440
  | 'uploaded-audio'
1407
1441
  | 'uploaded-avatar'
1442
+ | 'uploaded-text'
1408
1443
  | 'uploaded-video'
1409
1444
  | 'upscale'
1410
1445
  | 'upscale-skybox'
@@ -1519,7 +1554,7 @@ export namespace AssetUpdateResponse {
1519
1554
  * Metadata of the asset with some additional information
1520
1555
  */
1521
1556
  export interface Metadata {
1522
- kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
1557
+ kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'text' | 'video';
1523
1558
 
1524
1559
  /**
1525
1560
  * The type of the asset. Ex: 'inference-txt2img' will represent an asset generated
@@ -1535,6 +1570,7 @@ export namespace AssetUpdateResponse {
1535
1570
  | '3d23d'
1536
1571
  | '3d23d-texture'
1537
1572
  | 'audio2audio'
1573
+ | 'audio2txt'
1538
1574
  | 'audio2video'
1539
1575
  | 'background-removal'
1540
1576
  | 'canvas'
@@ -1545,6 +1581,7 @@ export namespace AssetUpdateResponse {
1545
1581
  | 'image-prompt-editing'
1546
1582
  | 'img23d'
1547
1583
  | 'img2img'
1584
+ | 'img2txt'
1548
1585
  | 'img2video'
1549
1586
  | 'inference-controlnet'
1550
1587
  | 'inference-controlnet-img2img'
@@ -1584,12 +1621,14 @@ export namespace AssetUpdateResponse {
1584
1621
  | 'txt23d'
1585
1622
  | 'txt2audio'
1586
1623
  | 'txt2img'
1624
+ | 'txt2txt'
1587
1625
  | 'txt2video'
1588
1626
  | 'unknown'
1589
1627
  | 'uploaded'
1590
1628
  | 'uploaded-3d'
1591
1629
  | 'uploaded-audio'
1592
1630
  | 'uploaded-avatar'
1631
+ | 'uploaded-text'
1593
1632
  | 'uploaded-video'
1594
1633
  | 'upscale'
1595
1634
  | 'upscale-skybox'
@@ -1613,10 +1652,6 @@ export namespace AssetUpdateResponse {
1613
1652
  */
1614
1653
  aspectRatio?: string;
1615
1654
 
1616
- /**
1617
- * Int to set between 0 and 255 for the opacity of the background in the result
1618
- * images.
1619
- */
1620
1655
  backgroundOpacity?: number;
1621
1656
 
1622
1657
  /**
@@ -1629,9 +1664,6 @@ export namespace AssetUpdateResponse {
1629
1664
  */
1630
1665
  bbox?: Array<number>;
1631
1666
 
1632
- /**
1633
- * Remove small dark spots (i.e. “pepper”) and connect small bright cracks.
1634
- */
1635
1667
  betterQuality?: boolean;
1636
1668
 
1637
1669
  /**
@@ -1707,9 +1739,6 @@ export namespace AssetUpdateResponse {
1707
1739
  */
1708
1740
  detailsLevel?: number;
1709
1741
 
1710
- /**
1711
- * The number of pixels to dilate the result masks.
1712
- */
1713
1742
  dilate?: number;
1714
1743
 
1715
1744
  /**
@@ -2014,12 +2043,16 @@ export namespace AssetUpdateResponse {
2014
2043
  resultContours?: boolean;
2015
2044
 
2016
2045
  /**
2017
- * Boolean to able output the cut out object.
2046
+ * Boolean to return the source image with the mask applied as alpha channel (RGBA
2047
+ * PNG, transparent background) instead of the binary mask. Mutually exclusive with
2048
+ * `resultMask` — passing both as `true` returns a 400 error. Note:
2049
+ * `backgroundOpacity` is no longer honored — alpha is binary (0/255) only.
2018
2050
  */
2019
2051
  resultImage?: boolean;
2020
2052
 
2021
2053
  /**
2022
- * Boolean to able return the masks (binary image) in the response.
2054
+ * Boolean to return the binary masks in the response. Mutually exclusive with
2055
+ * `resultImage` — passing both as `true` returns a 400 error.
2023
2056
  */
2024
2057
  resultMask?: boolean;
2025
2058
 
@@ -2239,6 +2272,13 @@ export namespace AssetUpdateResponse {
2239
2272
  */
2240
2273
  channels?: number;
2241
2274
 
2275
+ /**
2276
+ * Number of Unicode code points in the text. Code-point-aware (so a non-BMP emoji
2277
+ * counts as 1) but not full grapheme-cluster aware (a ZWJ sequence still counts as
2278
+ * several).
2279
+ */
2280
+ charCount?: number;
2281
+
2242
2282
  /**
2243
2283
  * Classification of the audio
2244
2284
  */
@@ -2284,6 +2324,14 @@ export namespace AssetUpdateResponse {
2284
2324
  */
2285
2325
  hasAnimations?: boolean;
2286
2326
 
2327
+ /**
2328
+ * True when `preview` holds the entire content unmodified — consumers can use it
2329
+ * directly without fetching `asset.url`. False or undefined means the content
2330
+ * exceeds the preview budget and consumers must fetch the full body from S3 to
2331
+ * read past the preview.
2332
+ */
2333
+ hasFullPreview?: boolean;
2334
+
2287
2335
  /**
2288
2336
  * Whether the mesh has normal vectors
2289
2337
  */
@@ -2306,6 +2354,15 @@ export namespace AssetUpdateResponse {
2306
2354
  */
2307
2355
  nbFrames?: number;
2308
2356
 
2357
+ /**
2358
+ * Leading slice of the content used for inline UI display and as a search
2359
+ * shortcut. Capped at TEXT_PREVIEW_MAX_BYTES (UTF-8) and always cut on a
2360
+ * code-point boundary so no character is split. Number of characters in the
2361
+ * preview varies by script (around 1024 for ASCII, ~340 for CJK, ~256 for
2362
+ * emoji-heavy text at the default 1 KB budget).
2363
+ */
2364
+ preview?: string;
2365
+
2309
2366
  /**
2310
2367
  * Sample rate of the media in Hz
2311
2368
  */
@@ -2322,6 +2379,11 @@ export namespace AssetUpdateResponse {
2322
2379
  vertexCount?: number;
2323
2380
 
2324
2381
  width?: number;
2382
+
2383
+ /**
2384
+ * Number of whitespace-separated words in the text
2385
+ */
2386
+ wordCount?: number;
2325
2387
  }
2326
2388
 
2327
2389
  export namespace Properties {
@@ -2420,7 +2482,7 @@ export interface AssetListResponse {
2420
2482
  /**
2421
2483
  * The kind of asset
2422
2484
  */
2423
- kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
2485
+ kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'text' | 'video';
2424
2486
 
2425
2487
  /**
2426
2488
  * Metadata of the asset with some additional information
@@ -2461,6 +2523,7 @@ export interface AssetListResponse {
2461
2523
  | '3d:texture:normal'
2462
2524
  | '3d:texture:roughness'
2463
2525
  | 'audio2audio'
2526
+ | 'audio2txt'
2464
2527
  | 'audio2video'
2465
2528
  | 'background-removal'
2466
2529
  | 'canvas'
@@ -2471,6 +2534,7 @@ export interface AssetListResponse {
2471
2534
  | 'image-prompt-editing'
2472
2535
  | 'img23d'
2473
2536
  | 'img2img'
2537
+ | 'img2txt'
2474
2538
  | 'img2video'
2475
2539
  | 'inference-control-net'
2476
2540
  | 'inference-control-net-img'
@@ -2510,12 +2574,14 @@ export interface AssetListResponse {
2510
2574
  | 'txt23d'
2511
2575
  | 'txt2audio'
2512
2576
  | 'txt2img'
2577
+ | 'txt2txt'
2513
2578
  | 'txt2video'
2514
2579
  | 'unknown'
2515
2580
  | 'uploaded'
2516
2581
  | 'uploaded-3d'
2517
2582
  | 'uploaded-audio'
2518
2583
  | 'uploaded-avatar'
2584
+ | 'uploaded-text'
2519
2585
  | 'uploaded-video'
2520
2586
  | 'upscale'
2521
2587
  | 'upscale-skybox'
@@ -2630,7 +2696,7 @@ export namespace AssetListResponse {
2630
2696
  * Metadata of the asset with some additional information
2631
2697
  */
2632
2698
  export interface Metadata {
2633
- kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
2699
+ kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'text' | 'video';
2634
2700
 
2635
2701
  /**
2636
2702
  * The type of the asset. Ex: 'inference-txt2img' will represent an asset generated
@@ -2646,6 +2712,7 @@ export namespace AssetListResponse {
2646
2712
  | '3d23d'
2647
2713
  | '3d23d-texture'
2648
2714
  | 'audio2audio'
2715
+ | 'audio2txt'
2649
2716
  | 'audio2video'
2650
2717
  | 'background-removal'
2651
2718
  | 'canvas'
@@ -2656,6 +2723,7 @@ export namespace AssetListResponse {
2656
2723
  | 'image-prompt-editing'
2657
2724
  | 'img23d'
2658
2725
  | 'img2img'
2726
+ | 'img2txt'
2659
2727
  | 'img2video'
2660
2728
  | 'inference-controlnet'
2661
2729
  | 'inference-controlnet-img2img'
@@ -2695,12 +2763,14 @@ export namespace AssetListResponse {
2695
2763
  | 'txt23d'
2696
2764
  | 'txt2audio'
2697
2765
  | 'txt2img'
2766
+ | 'txt2txt'
2698
2767
  | 'txt2video'
2699
2768
  | 'unknown'
2700
2769
  | 'uploaded'
2701
2770
  | 'uploaded-3d'
2702
2771
  | 'uploaded-audio'
2703
2772
  | 'uploaded-avatar'
2773
+ | 'uploaded-text'
2704
2774
  | 'uploaded-video'
2705
2775
  | 'upscale'
2706
2776
  | 'upscale-skybox'
@@ -2724,10 +2794,6 @@ export namespace AssetListResponse {
2724
2794
  */
2725
2795
  aspectRatio?: string;
2726
2796
 
2727
- /**
2728
- * Int to set between 0 and 255 for the opacity of the background in the result
2729
- * images.
2730
- */
2731
2797
  backgroundOpacity?: number;
2732
2798
 
2733
2799
  /**
@@ -2740,9 +2806,6 @@ export namespace AssetListResponse {
2740
2806
  */
2741
2807
  bbox?: Array<number>;
2742
2808
 
2743
- /**
2744
- * Remove small dark spots (i.e. “pepper”) and connect small bright cracks.
2745
- */
2746
2809
  betterQuality?: boolean;
2747
2810
 
2748
2811
  /**
@@ -2818,9 +2881,6 @@ export namespace AssetListResponse {
2818
2881
  */
2819
2882
  detailsLevel?: number;
2820
2883
 
2821
- /**
2822
- * The number of pixels to dilate the result masks.
2823
- */
2824
2884
  dilate?: number;
2825
2885
 
2826
2886
  /**
@@ -3125,12 +3185,16 @@ export namespace AssetListResponse {
3125
3185
  resultContours?: boolean;
3126
3186
 
3127
3187
  /**
3128
- * Boolean to able output the cut out object.
3188
+ * Boolean to return the source image with the mask applied as alpha channel (RGBA
3189
+ * PNG, transparent background) instead of the binary mask. Mutually exclusive with
3190
+ * `resultMask` — passing both as `true` returns a 400 error. Note:
3191
+ * `backgroundOpacity` is no longer honored — alpha is binary (0/255) only.
3129
3192
  */
3130
3193
  resultImage?: boolean;
3131
3194
 
3132
3195
  /**
3133
- * Boolean to able return the masks (binary image) in the response.
3196
+ * Boolean to return the binary masks in the response. Mutually exclusive with
3197
+ * `resultImage` — passing both as `true` returns a 400 error.
3134
3198
  */
3135
3199
  resultMask?: boolean;
3136
3200
 
@@ -3350,6 +3414,13 @@ export namespace AssetListResponse {
3350
3414
  */
3351
3415
  channels?: number;
3352
3416
 
3417
+ /**
3418
+ * Number of Unicode code points in the text. Code-point-aware (so a non-BMP emoji
3419
+ * counts as 1) but not full grapheme-cluster aware (a ZWJ sequence still counts as
3420
+ * several).
3421
+ */
3422
+ charCount?: number;
3423
+
3353
3424
  /**
3354
3425
  * Classification of the audio
3355
3426
  */
@@ -3395,6 +3466,14 @@ export namespace AssetListResponse {
3395
3466
  */
3396
3467
  hasAnimations?: boolean;
3397
3468
 
3469
+ /**
3470
+ * True when `preview` holds the entire content unmodified — consumers can use it
3471
+ * directly without fetching `asset.url`. False or undefined means the content
3472
+ * exceeds the preview budget and consumers must fetch the full body from S3 to
3473
+ * read past the preview.
3474
+ */
3475
+ hasFullPreview?: boolean;
3476
+
3398
3477
  /**
3399
3478
  * Whether the mesh has normal vectors
3400
3479
  */
@@ -3417,6 +3496,15 @@ export namespace AssetListResponse {
3417
3496
  */
3418
3497
  nbFrames?: number;
3419
3498
 
3499
+ /**
3500
+ * Leading slice of the content used for inline UI display and as a search
3501
+ * shortcut. Capped at TEXT_PREVIEW_MAX_BYTES (UTF-8) and always cut on a
3502
+ * code-point boundary so no character is split. Number of characters in the
3503
+ * preview varies by script (around 1024 for ASCII, ~340 for CJK, ~256 for
3504
+ * emoji-heavy text at the default 1 KB budget).
3505
+ */
3506
+ preview?: string;
3507
+
3420
3508
  /**
3421
3509
  * Sample rate of the media in Hz
3422
3510
  */
@@ -3433,6 +3521,11 @@ export namespace AssetListResponse {
3433
3521
  vertexCount?: number;
3434
3522
 
3435
3523
  width?: number;
3524
+
3525
+ /**
3526
+ * Number of whitespace-separated words in the text
3527
+ */
3528
+ wordCount?: number;
3436
3529
  }
3437
3530
 
3438
3531
  export namespace Properties {
@@ -3537,7 +3630,7 @@ export namespace AssetDuplicateResponse {
3537
3630
  /**
3538
3631
  * The kind of asset
3539
3632
  */
3540
- kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
3633
+ kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'text' | 'video';
3541
3634
 
3542
3635
  /**
3543
3636
  * Metadata of the asset with some additional information
@@ -3578,6 +3671,7 @@ export namespace AssetDuplicateResponse {
3578
3671
  | '3d:texture:normal'
3579
3672
  | '3d:texture:roughness'
3580
3673
  | 'audio2audio'
3674
+ | 'audio2txt'
3581
3675
  | 'audio2video'
3582
3676
  | 'background-removal'
3583
3677
  | 'canvas'
@@ -3588,6 +3682,7 @@ export namespace AssetDuplicateResponse {
3588
3682
  | 'image-prompt-editing'
3589
3683
  | 'img23d'
3590
3684
  | 'img2img'
3685
+ | 'img2txt'
3591
3686
  | 'img2video'
3592
3687
  | 'inference-control-net'
3593
3688
  | 'inference-control-net-img'
@@ -3627,12 +3722,14 @@ export namespace AssetDuplicateResponse {
3627
3722
  | 'txt23d'
3628
3723
  | 'txt2audio'
3629
3724
  | 'txt2img'
3725
+ | 'txt2txt'
3630
3726
  | 'txt2video'
3631
3727
  | 'unknown'
3632
3728
  | 'uploaded'
3633
3729
  | 'uploaded-3d'
3634
3730
  | 'uploaded-audio'
3635
3731
  | 'uploaded-avatar'
3732
+ | 'uploaded-text'
3636
3733
  | 'uploaded-video'
3637
3734
  | 'upscale'
3638
3735
  | 'upscale-skybox'
@@ -3747,7 +3844,7 @@ export namespace AssetDuplicateResponse {
3747
3844
  * Metadata of the asset with some additional information
3748
3845
  */
3749
3846
  export interface Metadata {
3750
- kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
3847
+ kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'text' | 'video';
3751
3848
 
3752
3849
  /**
3753
3850
  * The type of the asset. Ex: 'inference-txt2img' will represent an asset generated
@@ -3763,6 +3860,7 @@ export namespace AssetDuplicateResponse {
3763
3860
  | '3d23d'
3764
3861
  | '3d23d-texture'
3765
3862
  | 'audio2audio'
3863
+ | 'audio2txt'
3766
3864
  | 'audio2video'
3767
3865
  | 'background-removal'
3768
3866
  | 'canvas'
@@ -3773,6 +3871,7 @@ export namespace AssetDuplicateResponse {
3773
3871
  | 'image-prompt-editing'
3774
3872
  | 'img23d'
3775
3873
  | 'img2img'
3874
+ | 'img2txt'
3776
3875
  | 'img2video'
3777
3876
  | 'inference-controlnet'
3778
3877
  | 'inference-controlnet-img2img'
@@ -3812,12 +3911,14 @@ export namespace AssetDuplicateResponse {
3812
3911
  | 'txt23d'
3813
3912
  | 'txt2audio'
3814
3913
  | 'txt2img'
3914
+ | 'txt2txt'
3815
3915
  | 'txt2video'
3816
3916
  | 'unknown'
3817
3917
  | 'uploaded'
3818
3918
  | 'uploaded-3d'
3819
3919
  | 'uploaded-audio'
3820
3920
  | 'uploaded-avatar'
3921
+ | 'uploaded-text'
3821
3922
  | 'uploaded-video'
3822
3923
  | 'upscale'
3823
3924
  | 'upscale-skybox'
@@ -3841,10 +3942,6 @@ export namespace AssetDuplicateResponse {
3841
3942
  */
3842
3943
  aspectRatio?: string;
3843
3944
 
3844
- /**
3845
- * Int to set between 0 and 255 for the opacity of the background in the result
3846
- * images.
3847
- */
3848
3945
  backgroundOpacity?: number;
3849
3946
 
3850
3947
  /**
@@ -3857,9 +3954,6 @@ export namespace AssetDuplicateResponse {
3857
3954
  */
3858
3955
  bbox?: Array<number>;
3859
3956
 
3860
- /**
3861
- * Remove small dark spots (i.e. “pepper”) and connect small bright cracks.
3862
- */
3863
3957
  betterQuality?: boolean;
3864
3958
 
3865
3959
  /**
@@ -3935,9 +4029,6 @@ export namespace AssetDuplicateResponse {
3935
4029
  */
3936
4030
  detailsLevel?: number;
3937
4031
 
3938
- /**
3939
- * The number of pixels to dilate the result masks.
3940
- */
3941
4032
  dilate?: number;
3942
4033
 
3943
4034
  /**
@@ -4242,12 +4333,16 @@ export namespace AssetDuplicateResponse {
4242
4333
  resultContours?: boolean;
4243
4334
 
4244
4335
  /**
4245
- * Boolean to able output the cut out object.
4336
+ * Boolean to return the source image with the mask applied as alpha channel (RGBA
4337
+ * PNG, transparent background) instead of the binary mask. Mutually exclusive with
4338
+ * `resultMask` — passing both as `true` returns a 400 error. Note:
4339
+ * `backgroundOpacity` is no longer honored — alpha is binary (0/255) only.
4246
4340
  */
4247
4341
  resultImage?: boolean;
4248
4342
 
4249
4343
  /**
4250
- * Boolean to able return the masks (binary image) in the response.
4344
+ * Boolean to return the binary masks in the response. Mutually exclusive with
4345
+ * `resultImage` — passing both as `true` returns a 400 error.
4251
4346
  */
4252
4347
  resultMask?: boolean;
4253
4348
 
@@ -4467,6 +4562,13 @@ export namespace AssetDuplicateResponse {
4467
4562
  */
4468
4563
  channels?: number;
4469
4564
 
4565
+ /**
4566
+ * Number of Unicode code points in the text. Code-point-aware (so a non-BMP emoji
4567
+ * counts as 1) but not full grapheme-cluster aware (a ZWJ sequence still counts as
4568
+ * several).
4569
+ */
4570
+ charCount?: number;
4571
+
4470
4572
  /**
4471
4573
  * Classification of the audio
4472
4574
  */
@@ -4512,6 +4614,14 @@ export namespace AssetDuplicateResponse {
4512
4614
  */
4513
4615
  hasAnimations?: boolean;
4514
4616
 
4617
+ /**
4618
+ * True when `preview` holds the entire content unmodified — consumers can use it
4619
+ * directly without fetching `asset.url`. False or undefined means the content
4620
+ * exceeds the preview budget and consumers must fetch the full body from S3 to
4621
+ * read past the preview.
4622
+ */
4623
+ hasFullPreview?: boolean;
4624
+
4515
4625
  /**
4516
4626
  * Whether the mesh has normal vectors
4517
4627
  */
@@ -4534,6 +4644,15 @@ export namespace AssetDuplicateResponse {
4534
4644
  */
4535
4645
  nbFrames?: number;
4536
4646
 
4647
+ /**
4648
+ * Leading slice of the content used for inline UI display and as a search
4649
+ * shortcut. Capped at TEXT_PREVIEW_MAX_BYTES (UTF-8) and always cut on a
4650
+ * code-point boundary so no character is split. Number of characters in the
4651
+ * preview varies by script (around 1024 for ASCII, ~340 for CJK, ~256 for
4652
+ * emoji-heavy text at the default 1 KB budget).
4653
+ */
4654
+ preview?: string;
4655
+
4537
4656
  /**
4538
4657
  * Sample rate of the media in Hz
4539
4658
  */
@@ -4550,6 +4669,11 @@ export namespace AssetDuplicateResponse {
4550
4669
  vertexCount?: number;
4551
4670
 
4552
4671
  width?: number;
4672
+
4673
+ /**
4674
+ * Number of whitespace-separated words in the text
4675
+ */
4676
+ wordCount?: number;
4553
4677
  }
4554
4678
 
4555
4679
  export namespace Properties {
@@ -4653,7 +4777,7 @@ export namespace AssetGetBulkResponse {
4653
4777
  /**
4654
4778
  * The kind of asset
4655
4779
  */
4656
- kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
4780
+ kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'text' | 'video';
4657
4781
 
4658
4782
  /**
4659
4783
  * Metadata of the asset with some additional information
@@ -4694,6 +4818,7 @@ export namespace AssetGetBulkResponse {
4694
4818
  | '3d:texture:normal'
4695
4819
  | '3d:texture:roughness'
4696
4820
  | 'audio2audio'
4821
+ | 'audio2txt'
4697
4822
  | 'audio2video'
4698
4823
  | 'background-removal'
4699
4824
  | 'canvas'
@@ -4704,6 +4829,7 @@ export namespace AssetGetBulkResponse {
4704
4829
  | 'image-prompt-editing'
4705
4830
  | 'img23d'
4706
4831
  | 'img2img'
4832
+ | 'img2txt'
4707
4833
  | 'img2video'
4708
4834
  | 'inference-control-net'
4709
4835
  | 'inference-control-net-img'
@@ -4743,12 +4869,14 @@ export namespace AssetGetBulkResponse {
4743
4869
  | 'txt23d'
4744
4870
  | 'txt2audio'
4745
4871
  | 'txt2img'
4872
+ | 'txt2txt'
4746
4873
  | 'txt2video'
4747
4874
  | 'unknown'
4748
4875
  | 'uploaded'
4749
4876
  | 'uploaded-3d'
4750
4877
  | 'uploaded-audio'
4751
4878
  | 'uploaded-avatar'
4879
+ | 'uploaded-text'
4752
4880
  | 'uploaded-video'
4753
4881
  | 'upscale'
4754
4882
  | 'upscale-skybox'
@@ -4863,7 +4991,7 @@ export namespace AssetGetBulkResponse {
4863
4991
  * Metadata of the asset with some additional information
4864
4992
  */
4865
4993
  export interface Metadata {
4866
- kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
4994
+ kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'text' | 'video';
4867
4995
 
4868
4996
  /**
4869
4997
  * The type of the asset. Ex: 'inference-txt2img' will represent an asset generated
@@ -4879,6 +5007,7 @@ export namespace AssetGetBulkResponse {
4879
5007
  | '3d23d'
4880
5008
  | '3d23d-texture'
4881
5009
  | 'audio2audio'
5010
+ | 'audio2txt'
4882
5011
  | 'audio2video'
4883
5012
  | 'background-removal'
4884
5013
  | 'canvas'
@@ -4889,6 +5018,7 @@ export namespace AssetGetBulkResponse {
4889
5018
  | 'image-prompt-editing'
4890
5019
  | 'img23d'
4891
5020
  | 'img2img'
5021
+ | 'img2txt'
4892
5022
  | 'img2video'
4893
5023
  | 'inference-controlnet'
4894
5024
  | 'inference-controlnet-img2img'
@@ -4928,12 +5058,14 @@ export namespace AssetGetBulkResponse {
4928
5058
  | 'txt23d'
4929
5059
  | 'txt2audio'
4930
5060
  | 'txt2img'
5061
+ | 'txt2txt'
4931
5062
  | 'txt2video'
4932
5063
  | 'unknown'
4933
5064
  | 'uploaded'
4934
5065
  | 'uploaded-3d'
4935
5066
  | 'uploaded-audio'
4936
5067
  | 'uploaded-avatar'
5068
+ | 'uploaded-text'
4937
5069
  | 'uploaded-video'
4938
5070
  | 'upscale'
4939
5071
  | 'upscale-skybox'
@@ -4957,10 +5089,6 @@ export namespace AssetGetBulkResponse {
4957
5089
  */
4958
5090
  aspectRatio?: string;
4959
5091
 
4960
- /**
4961
- * Int to set between 0 and 255 for the opacity of the background in the result
4962
- * images.
4963
- */
4964
5092
  backgroundOpacity?: number;
4965
5093
 
4966
5094
  /**
@@ -4973,9 +5101,6 @@ export namespace AssetGetBulkResponse {
4973
5101
  */
4974
5102
  bbox?: Array<number>;
4975
5103
 
4976
- /**
4977
- * Remove small dark spots (i.e. “pepper”) and connect small bright cracks.
4978
- */
4979
5104
  betterQuality?: boolean;
4980
5105
 
4981
5106
  /**
@@ -5051,9 +5176,6 @@ export namespace AssetGetBulkResponse {
5051
5176
  */
5052
5177
  detailsLevel?: number;
5053
5178
 
5054
- /**
5055
- * The number of pixels to dilate the result masks.
5056
- */
5057
5179
  dilate?: number;
5058
5180
 
5059
5181
  /**
@@ -5358,12 +5480,16 @@ export namespace AssetGetBulkResponse {
5358
5480
  resultContours?: boolean;
5359
5481
 
5360
5482
  /**
5361
- * Boolean to able output the cut out object.
5483
+ * Boolean to return the source image with the mask applied as alpha channel (RGBA
5484
+ * PNG, transparent background) instead of the binary mask. Mutually exclusive with
5485
+ * `resultMask` — passing both as `true` returns a 400 error. Note:
5486
+ * `backgroundOpacity` is no longer honored — alpha is binary (0/255) only.
5362
5487
  */
5363
5488
  resultImage?: boolean;
5364
5489
 
5365
5490
  /**
5366
- * Boolean to able return the masks (binary image) in the response.
5491
+ * Boolean to return the binary masks in the response. Mutually exclusive with
5492
+ * `resultImage` — passing both as `true` returns a 400 error.
5367
5493
  */
5368
5494
  resultMask?: boolean;
5369
5495
 
@@ -5583,6 +5709,13 @@ export namespace AssetGetBulkResponse {
5583
5709
  */
5584
5710
  channels?: number;
5585
5711
 
5712
+ /**
5713
+ * Number of Unicode code points in the text. Code-point-aware (so a non-BMP emoji
5714
+ * counts as 1) but not full grapheme-cluster aware (a ZWJ sequence still counts as
5715
+ * several).
5716
+ */
5717
+ charCount?: number;
5718
+
5586
5719
  /**
5587
5720
  * Classification of the audio
5588
5721
  */
@@ -5628,6 +5761,14 @@ export namespace AssetGetBulkResponse {
5628
5761
  */
5629
5762
  hasAnimations?: boolean;
5630
5763
 
5764
+ /**
5765
+ * True when `preview` holds the entire content unmodified — consumers can use it
5766
+ * directly without fetching `asset.url`. False or undefined means the content
5767
+ * exceeds the preview budget and consumers must fetch the full body from S3 to
5768
+ * read past the preview.
5769
+ */
5770
+ hasFullPreview?: boolean;
5771
+
5631
5772
  /**
5632
5773
  * Whether the mesh has normal vectors
5633
5774
  */
@@ -5650,6 +5791,15 @@ export namespace AssetGetBulkResponse {
5650
5791
  */
5651
5792
  nbFrames?: number;
5652
5793
 
5794
+ /**
5795
+ * Leading slice of the content used for inline UI display and as a search
5796
+ * shortcut. Capped at TEXT_PREVIEW_MAX_BYTES (UTF-8) and always cut on a
5797
+ * code-point boundary so no character is split. Number of characters in the
5798
+ * preview varies by script (around 1024 for ASCII, ~340 for CJK, ~256 for
5799
+ * emoji-heavy text at the default 1 KB budget).
5800
+ */
5801
+ preview?: string;
5802
+
5653
5803
  /**
5654
5804
  * Sample rate of the media in Hz
5655
5805
  */
@@ -5666,6 +5816,11 @@ export namespace AssetGetBulkResponse {
5666
5816
  vertexCount?: number;
5667
5817
 
5668
5818
  width?: number;
5819
+
5820
+ /**
5821
+ * Number of whitespace-separated words in the text
5822
+ */
5823
+ wordCount?: number;
5669
5824
  }
5670
5825
 
5671
5826
  export namespace Properties {
@@ -5784,7 +5939,7 @@ export namespace AssetLockResponse {
5784
5939
  /**
5785
5940
  * The kind of asset
5786
5941
  */
5787
- kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
5942
+ kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'text' | 'video';
5788
5943
 
5789
5944
  /**
5790
5945
  * Metadata of the asset with some additional information
@@ -5825,6 +5980,7 @@ export namespace AssetLockResponse {
5825
5980
  | '3d:texture:normal'
5826
5981
  | '3d:texture:roughness'
5827
5982
  | 'audio2audio'
5983
+ | 'audio2txt'
5828
5984
  | 'audio2video'
5829
5985
  | 'background-removal'
5830
5986
  | 'canvas'
@@ -5835,6 +5991,7 @@ export namespace AssetLockResponse {
5835
5991
  | 'image-prompt-editing'
5836
5992
  | 'img23d'
5837
5993
  | 'img2img'
5994
+ | 'img2txt'
5838
5995
  | 'img2video'
5839
5996
  | 'inference-control-net'
5840
5997
  | 'inference-control-net-img'
@@ -5874,12 +6031,14 @@ export namespace AssetLockResponse {
5874
6031
  | 'txt23d'
5875
6032
  | 'txt2audio'
5876
6033
  | 'txt2img'
6034
+ | 'txt2txt'
5877
6035
  | 'txt2video'
5878
6036
  | 'unknown'
5879
6037
  | 'uploaded'
5880
6038
  | 'uploaded-3d'
5881
6039
  | 'uploaded-audio'
5882
6040
  | 'uploaded-avatar'
6041
+ | 'uploaded-text'
5883
6042
  | 'uploaded-video'
5884
6043
  | 'upscale'
5885
6044
  | 'upscale-skybox'
@@ -5994,7 +6153,7 @@ export namespace AssetLockResponse {
5994
6153
  * Metadata of the asset with some additional information
5995
6154
  */
5996
6155
  export interface Metadata {
5997
- kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
6156
+ kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'text' | 'video';
5998
6157
 
5999
6158
  /**
6000
6159
  * The type of the asset. Ex: 'inference-txt2img' will represent an asset generated
@@ -6010,6 +6169,7 @@ export namespace AssetLockResponse {
6010
6169
  | '3d23d'
6011
6170
  | '3d23d-texture'
6012
6171
  | 'audio2audio'
6172
+ | 'audio2txt'
6013
6173
  | 'audio2video'
6014
6174
  | 'background-removal'
6015
6175
  | 'canvas'
@@ -6020,6 +6180,7 @@ export namespace AssetLockResponse {
6020
6180
  | 'image-prompt-editing'
6021
6181
  | 'img23d'
6022
6182
  | 'img2img'
6183
+ | 'img2txt'
6023
6184
  | 'img2video'
6024
6185
  | 'inference-controlnet'
6025
6186
  | 'inference-controlnet-img2img'
@@ -6059,12 +6220,14 @@ export namespace AssetLockResponse {
6059
6220
  | 'txt23d'
6060
6221
  | 'txt2audio'
6061
6222
  | 'txt2img'
6223
+ | 'txt2txt'
6062
6224
  | 'txt2video'
6063
6225
  | 'unknown'
6064
6226
  | 'uploaded'
6065
6227
  | 'uploaded-3d'
6066
6228
  | 'uploaded-audio'
6067
6229
  | 'uploaded-avatar'
6230
+ | 'uploaded-text'
6068
6231
  | 'uploaded-video'
6069
6232
  | 'upscale'
6070
6233
  | 'upscale-skybox'
@@ -6088,10 +6251,6 @@ export namespace AssetLockResponse {
6088
6251
  */
6089
6252
  aspectRatio?: string;
6090
6253
 
6091
- /**
6092
- * Int to set between 0 and 255 for the opacity of the background in the result
6093
- * images.
6094
- */
6095
6254
  backgroundOpacity?: number;
6096
6255
 
6097
6256
  /**
@@ -6104,9 +6263,6 @@ export namespace AssetLockResponse {
6104
6263
  */
6105
6264
  bbox?: Array<number>;
6106
6265
 
6107
- /**
6108
- * Remove small dark spots (i.e. “pepper”) and connect small bright cracks.
6109
- */
6110
6266
  betterQuality?: boolean;
6111
6267
 
6112
6268
  /**
@@ -6182,9 +6338,6 @@ export namespace AssetLockResponse {
6182
6338
  */
6183
6339
  detailsLevel?: number;
6184
6340
 
6185
- /**
6186
- * The number of pixels to dilate the result masks.
6187
- */
6188
6341
  dilate?: number;
6189
6342
 
6190
6343
  /**
@@ -6489,12 +6642,16 @@ export namespace AssetLockResponse {
6489
6642
  resultContours?: boolean;
6490
6643
 
6491
6644
  /**
6492
- * Boolean to able output the cut out object.
6645
+ * Boolean to return the source image with the mask applied as alpha channel (RGBA
6646
+ * PNG, transparent background) instead of the binary mask. Mutually exclusive with
6647
+ * `resultMask` — passing both as `true` returns a 400 error. Note:
6648
+ * `backgroundOpacity` is no longer honored — alpha is binary (0/255) only.
6493
6649
  */
6494
6650
  resultImage?: boolean;
6495
6651
 
6496
6652
  /**
6497
- * Boolean to able return the masks (binary image) in the response.
6653
+ * Boolean to return the binary masks in the response. Mutually exclusive with
6654
+ * `resultImage` — passing both as `true` returns a 400 error.
6498
6655
  */
6499
6656
  resultMask?: boolean;
6500
6657
 
@@ -6714,6 +6871,13 @@ export namespace AssetLockResponse {
6714
6871
  */
6715
6872
  channels?: number;
6716
6873
 
6874
+ /**
6875
+ * Number of Unicode code points in the text. Code-point-aware (so a non-BMP emoji
6876
+ * counts as 1) but not full grapheme-cluster aware (a ZWJ sequence still counts as
6877
+ * several).
6878
+ */
6879
+ charCount?: number;
6880
+
6717
6881
  /**
6718
6882
  * Classification of the audio
6719
6883
  */
@@ -6759,6 +6923,14 @@ export namespace AssetLockResponse {
6759
6923
  */
6760
6924
  hasAnimations?: boolean;
6761
6925
 
6926
+ /**
6927
+ * True when `preview` holds the entire content unmodified — consumers can use it
6928
+ * directly without fetching `asset.url`. False or undefined means the content
6929
+ * exceeds the preview budget and consumers must fetch the full body from S3 to
6930
+ * read past the preview.
6931
+ */
6932
+ hasFullPreview?: boolean;
6933
+
6762
6934
  /**
6763
6935
  * Whether the mesh has normal vectors
6764
6936
  */
@@ -6781,6 +6953,15 @@ export namespace AssetLockResponse {
6781
6953
  */
6782
6954
  nbFrames?: number;
6783
6955
 
6956
+ /**
6957
+ * Leading slice of the content used for inline UI display and as a search
6958
+ * shortcut. Capped at TEXT_PREVIEW_MAX_BYTES (UTF-8) and always cut on a
6959
+ * code-point boundary so no character is split. Number of characters in the
6960
+ * preview varies by script (around 1024 for ASCII, ~340 for CJK, ~256 for
6961
+ * emoji-heavy text at the default 1 KB budget).
6962
+ */
6963
+ preview?: string;
6964
+
6784
6965
  /**
6785
6966
  * Sample rate of the media in Hz
6786
6967
  */
@@ -6797,6 +6978,11 @@ export namespace AssetLockResponse {
6797
6978
  vertexCount?: number;
6798
6979
 
6799
6980
  width?: number;
6981
+
6982
+ /**
6983
+ * Number of whitespace-separated words in the text
6984
+ */
6985
+ wordCount?: number;
6800
6986
  }
6801
6987
 
6802
6988
  export namespace Properties {
@@ -6900,7 +7086,7 @@ export namespace AssetUnlockResponse {
6900
7086
  /**
6901
7087
  * The kind of asset
6902
7088
  */
6903
- kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
7089
+ kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'text' | 'video';
6904
7090
 
6905
7091
  /**
6906
7092
  * Metadata of the asset with some additional information
@@ -6941,6 +7127,7 @@ export namespace AssetUnlockResponse {
6941
7127
  | '3d:texture:normal'
6942
7128
  | '3d:texture:roughness'
6943
7129
  | 'audio2audio'
7130
+ | 'audio2txt'
6944
7131
  | 'audio2video'
6945
7132
  | 'background-removal'
6946
7133
  | 'canvas'
@@ -6951,6 +7138,7 @@ export namespace AssetUnlockResponse {
6951
7138
  | 'image-prompt-editing'
6952
7139
  | 'img23d'
6953
7140
  | 'img2img'
7141
+ | 'img2txt'
6954
7142
  | 'img2video'
6955
7143
  | 'inference-control-net'
6956
7144
  | 'inference-control-net-img'
@@ -6990,12 +7178,14 @@ export namespace AssetUnlockResponse {
6990
7178
  | 'txt23d'
6991
7179
  | 'txt2audio'
6992
7180
  | 'txt2img'
7181
+ | 'txt2txt'
6993
7182
  | 'txt2video'
6994
7183
  | 'unknown'
6995
7184
  | 'uploaded'
6996
7185
  | 'uploaded-3d'
6997
7186
  | 'uploaded-audio'
6998
7187
  | 'uploaded-avatar'
7188
+ | 'uploaded-text'
6999
7189
  | 'uploaded-video'
7000
7190
  | 'upscale'
7001
7191
  | 'upscale-skybox'
@@ -7110,7 +7300,7 @@ export namespace AssetUnlockResponse {
7110
7300
  * Metadata of the asset with some additional information
7111
7301
  */
7112
7302
  export interface Metadata {
7113
- kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
7303
+ kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'text' | 'video';
7114
7304
 
7115
7305
  /**
7116
7306
  * The type of the asset. Ex: 'inference-txt2img' will represent an asset generated
@@ -7126,6 +7316,7 @@ export namespace AssetUnlockResponse {
7126
7316
  | '3d23d'
7127
7317
  | '3d23d-texture'
7128
7318
  | 'audio2audio'
7319
+ | 'audio2txt'
7129
7320
  | 'audio2video'
7130
7321
  | 'background-removal'
7131
7322
  | 'canvas'
@@ -7136,6 +7327,7 @@ export namespace AssetUnlockResponse {
7136
7327
  | 'image-prompt-editing'
7137
7328
  | 'img23d'
7138
7329
  | 'img2img'
7330
+ | 'img2txt'
7139
7331
  | 'img2video'
7140
7332
  | 'inference-controlnet'
7141
7333
  | 'inference-controlnet-img2img'
@@ -7175,12 +7367,14 @@ export namespace AssetUnlockResponse {
7175
7367
  | 'txt23d'
7176
7368
  | 'txt2audio'
7177
7369
  | 'txt2img'
7370
+ | 'txt2txt'
7178
7371
  | 'txt2video'
7179
7372
  | 'unknown'
7180
7373
  | 'uploaded'
7181
7374
  | 'uploaded-3d'
7182
7375
  | 'uploaded-audio'
7183
7376
  | 'uploaded-avatar'
7377
+ | 'uploaded-text'
7184
7378
  | 'uploaded-video'
7185
7379
  | 'upscale'
7186
7380
  | 'upscale-skybox'
@@ -7204,10 +7398,6 @@ export namespace AssetUnlockResponse {
7204
7398
  */
7205
7399
  aspectRatio?: string;
7206
7400
 
7207
- /**
7208
- * Int to set between 0 and 255 for the opacity of the background in the result
7209
- * images.
7210
- */
7211
7401
  backgroundOpacity?: number;
7212
7402
 
7213
7403
  /**
@@ -7220,9 +7410,6 @@ export namespace AssetUnlockResponse {
7220
7410
  */
7221
7411
  bbox?: Array<number>;
7222
7412
 
7223
- /**
7224
- * Remove small dark spots (i.e. “pepper”) and connect small bright cracks.
7225
- */
7226
7413
  betterQuality?: boolean;
7227
7414
 
7228
7415
  /**
@@ -7298,9 +7485,6 @@ export namespace AssetUnlockResponse {
7298
7485
  */
7299
7486
  detailsLevel?: number;
7300
7487
 
7301
- /**
7302
- * The number of pixels to dilate the result masks.
7303
- */
7304
7488
  dilate?: number;
7305
7489
 
7306
7490
  /**
@@ -7605,12 +7789,16 @@ export namespace AssetUnlockResponse {
7605
7789
  resultContours?: boolean;
7606
7790
 
7607
7791
  /**
7608
- * Boolean to able output the cut out object.
7792
+ * Boolean to return the source image with the mask applied as alpha channel (RGBA
7793
+ * PNG, transparent background) instead of the binary mask. Mutually exclusive with
7794
+ * `resultMask` — passing both as `true` returns a 400 error. Note:
7795
+ * `backgroundOpacity` is no longer honored — alpha is binary (0/255) only.
7609
7796
  */
7610
7797
  resultImage?: boolean;
7611
7798
 
7612
7799
  /**
7613
- * Boolean to able return the masks (binary image) in the response.
7800
+ * Boolean to return the binary masks in the response. Mutually exclusive with
7801
+ * `resultImage` — passing both as `true` returns a 400 error.
7614
7802
  */
7615
7803
  resultMask?: boolean;
7616
7804
 
@@ -7830,6 +8018,13 @@ export namespace AssetUnlockResponse {
7830
8018
  */
7831
8019
  channels?: number;
7832
8020
 
8021
+ /**
8022
+ * Number of Unicode code points in the text. Code-point-aware (so a non-BMP emoji
8023
+ * counts as 1) but not full grapheme-cluster aware (a ZWJ sequence still counts as
8024
+ * several).
8025
+ */
8026
+ charCount?: number;
8027
+
7833
8028
  /**
7834
8029
  * Classification of the audio
7835
8030
  */
@@ -7875,6 +8070,14 @@ export namespace AssetUnlockResponse {
7875
8070
  */
7876
8071
  hasAnimations?: boolean;
7877
8072
 
8073
+ /**
8074
+ * True when `preview` holds the entire content unmodified — consumers can use it
8075
+ * directly without fetching `asset.url`. False or undefined means the content
8076
+ * exceeds the preview budget and consumers must fetch the full body from S3 to
8077
+ * read past the preview.
8078
+ */
8079
+ hasFullPreview?: boolean;
8080
+
7878
8081
  /**
7879
8082
  * Whether the mesh has normal vectors
7880
8083
  */
@@ -7897,6 +8100,15 @@ export namespace AssetUnlockResponse {
7897
8100
  */
7898
8101
  nbFrames?: number;
7899
8102
 
8103
+ /**
8104
+ * Leading slice of the content used for inline UI display and as a search
8105
+ * shortcut. Capped at TEXT_PREVIEW_MAX_BYTES (UTF-8) and always cut on a
8106
+ * code-point boundary so no character is split. Number of characters in the
8107
+ * preview varies by script (around 1024 for ASCII, ~340 for CJK, ~256 for
8108
+ * emoji-heavy text at the default 1 KB budget).
8109
+ */
8110
+ preview?: string;
8111
+
7900
8112
  /**
7901
8113
  * Sample rate of the media in Hz
7902
8114
  */
@@ -7913,6 +8125,11 @@ export namespace AssetUnlockResponse {
7913
8125
  vertexCount?: number;
7914
8126
 
7915
8127
  width?: number;
8128
+
8129
+ /**
8130
+ * Number of whitespace-separated words in the text
8131
+ */
8132
+ wordCount?: number;
7916
8133
  }
7917
8134
 
7918
8135
  export namespace Properties {
@@ -8030,7 +8247,7 @@ export namespace AssetUploadResponse {
8030
8247
  /**
8031
8248
  * The kind of asset
8032
8249
  */
8033
- kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
8250
+ kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'text' | 'video';
8034
8251
 
8035
8252
  /**
8036
8253
  * Metadata of the asset with some additional information
@@ -8071,6 +8288,7 @@ export namespace AssetUploadResponse {
8071
8288
  | '3d:texture:normal'
8072
8289
  | '3d:texture:roughness'
8073
8290
  | 'audio2audio'
8291
+ | 'audio2txt'
8074
8292
  | 'audio2video'
8075
8293
  | 'background-removal'
8076
8294
  | 'canvas'
@@ -8081,6 +8299,7 @@ export namespace AssetUploadResponse {
8081
8299
  | 'image-prompt-editing'
8082
8300
  | 'img23d'
8083
8301
  | 'img2img'
8302
+ | 'img2txt'
8084
8303
  | 'img2video'
8085
8304
  | 'inference-control-net'
8086
8305
  | 'inference-control-net-img'
@@ -8120,12 +8339,14 @@ export namespace AssetUploadResponse {
8120
8339
  | 'txt23d'
8121
8340
  | 'txt2audio'
8122
8341
  | 'txt2img'
8342
+ | 'txt2txt'
8123
8343
  | 'txt2video'
8124
8344
  | 'unknown'
8125
8345
  | 'uploaded'
8126
8346
  | 'uploaded-3d'
8127
8347
  | 'uploaded-audio'
8128
8348
  | 'uploaded-avatar'
8349
+ | 'uploaded-text'
8129
8350
  | 'uploaded-video'
8130
8351
  | 'upscale'
8131
8352
  | 'upscale-skybox'
@@ -8240,7 +8461,7 @@ export namespace AssetUploadResponse {
8240
8461
  * Metadata of the asset with some additional information
8241
8462
  */
8242
8463
  export interface Metadata {
8243
- kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
8464
+ kind: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'text' | 'video';
8244
8465
 
8245
8466
  /**
8246
8467
  * The type of the asset. Ex: 'inference-txt2img' will represent an asset generated
@@ -8256,6 +8477,7 @@ export namespace AssetUploadResponse {
8256
8477
  | '3d23d'
8257
8478
  | '3d23d-texture'
8258
8479
  | 'audio2audio'
8480
+ | 'audio2txt'
8259
8481
  | 'audio2video'
8260
8482
  | 'background-removal'
8261
8483
  | 'canvas'
@@ -8266,6 +8488,7 @@ export namespace AssetUploadResponse {
8266
8488
  | 'image-prompt-editing'
8267
8489
  | 'img23d'
8268
8490
  | 'img2img'
8491
+ | 'img2txt'
8269
8492
  | 'img2video'
8270
8493
  | 'inference-controlnet'
8271
8494
  | 'inference-controlnet-img2img'
@@ -8305,12 +8528,14 @@ export namespace AssetUploadResponse {
8305
8528
  | 'txt23d'
8306
8529
  | 'txt2audio'
8307
8530
  | 'txt2img'
8531
+ | 'txt2txt'
8308
8532
  | 'txt2video'
8309
8533
  | 'unknown'
8310
8534
  | 'uploaded'
8311
8535
  | 'uploaded-3d'
8312
8536
  | 'uploaded-audio'
8313
8537
  | 'uploaded-avatar'
8538
+ | 'uploaded-text'
8314
8539
  | 'uploaded-video'
8315
8540
  | 'upscale'
8316
8541
  | 'upscale-skybox'
@@ -8334,10 +8559,6 @@ export namespace AssetUploadResponse {
8334
8559
  */
8335
8560
  aspectRatio?: string;
8336
8561
 
8337
- /**
8338
- * Int to set between 0 and 255 for the opacity of the background in the result
8339
- * images.
8340
- */
8341
8562
  backgroundOpacity?: number;
8342
8563
 
8343
8564
  /**
@@ -8350,9 +8571,6 @@ export namespace AssetUploadResponse {
8350
8571
  */
8351
8572
  bbox?: Array<number>;
8352
8573
 
8353
- /**
8354
- * Remove small dark spots (i.e. “pepper”) and connect small bright cracks.
8355
- */
8356
8574
  betterQuality?: boolean;
8357
8575
 
8358
8576
  /**
@@ -8428,9 +8646,6 @@ export namespace AssetUploadResponse {
8428
8646
  */
8429
8647
  detailsLevel?: number;
8430
8648
 
8431
- /**
8432
- * The number of pixels to dilate the result masks.
8433
- */
8434
8649
  dilate?: number;
8435
8650
 
8436
8651
  /**
@@ -8735,12 +8950,16 @@ export namespace AssetUploadResponse {
8735
8950
  resultContours?: boolean;
8736
8951
 
8737
8952
  /**
8738
- * Boolean to able output the cut out object.
8953
+ * Boolean to return the source image with the mask applied as alpha channel (RGBA
8954
+ * PNG, transparent background) instead of the binary mask. Mutually exclusive with
8955
+ * `resultMask` — passing both as `true` returns a 400 error. Note:
8956
+ * `backgroundOpacity` is no longer honored — alpha is binary (0/255) only.
8739
8957
  */
8740
8958
  resultImage?: boolean;
8741
8959
 
8742
8960
  /**
8743
- * Boolean to able return the masks (binary image) in the response.
8961
+ * Boolean to return the binary masks in the response. Mutually exclusive with
8962
+ * `resultImage` — passing both as `true` returns a 400 error.
8744
8963
  */
8745
8964
  resultMask?: boolean;
8746
8965
 
@@ -8960,6 +9179,13 @@ export namespace AssetUploadResponse {
8960
9179
  */
8961
9180
  channels?: number;
8962
9181
 
9182
+ /**
9183
+ * Number of Unicode code points in the text. Code-point-aware (so a non-BMP emoji
9184
+ * counts as 1) but not full grapheme-cluster aware (a ZWJ sequence still counts as
9185
+ * several).
9186
+ */
9187
+ charCount?: number;
9188
+
8963
9189
  /**
8964
9190
  * Classification of the audio
8965
9191
  */
@@ -9005,6 +9231,14 @@ export namespace AssetUploadResponse {
9005
9231
  */
9006
9232
  hasAnimations?: boolean;
9007
9233
 
9234
+ /**
9235
+ * True when `preview` holds the entire content unmodified — consumers can use it
9236
+ * directly without fetching `asset.url`. False or undefined means the content
9237
+ * exceeds the preview budget and consumers must fetch the full body from S3 to
9238
+ * read past the preview.
9239
+ */
9240
+ hasFullPreview?: boolean;
9241
+
9008
9242
  /**
9009
9243
  * Whether the mesh has normal vectors
9010
9244
  */
@@ -9027,6 +9261,15 @@ export namespace AssetUploadResponse {
9027
9261
  */
9028
9262
  nbFrames?: number;
9029
9263
 
9264
+ /**
9265
+ * Leading slice of the content used for inline UI display and as a search
9266
+ * shortcut. Capped at TEXT_PREVIEW_MAX_BYTES (UTF-8) and always cut on a
9267
+ * code-point boundary so no character is split. Number of characters in the
9268
+ * preview varies by script (around 1024 for ASCII, ~340 for CJK, ~256 for
9269
+ * emoji-heavy text at the default 1 KB budget).
9270
+ */
9271
+ preview?: string;
9272
+
9030
9273
  /**
9031
9274
  * Sample rate of the media in Hz
9032
9275
  */
@@ -9043,6 +9286,11 @@ export namespace AssetUploadResponse {
9043
9286
  vertexCount?: number;
9044
9287
 
9045
9288
  width?: number;
9289
+
9290
+ /**
9291
+ * Number of whitespace-separated words in the text
9292
+ */
9293
+ wordCount?: number;
9046
9294
  }
9047
9295
 
9048
9296
  export namespace Properties {
@@ -9470,7 +9718,7 @@ export namespace AssetUploadResponse {
9470
9718
  * not able to create the asset on the flight on API side with dataurl without
9471
9719
  * data:kind, prefix
9472
9720
  */
9473
- kind?: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
9721
+ kind?: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'text' | 'video';
9474
9722
 
9475
9723
  /**
9476
9724
  * The label displayed in the UI for this input
@@ -9703,7 +9951,7 @@ export namespace AssetUploadResponse {
9703
9951
  * not able to create the asset on the flight on API side with dataurl without
9704
9952
  * data:kind, prefix
9705
9953
  */
9706
- kind?: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'video';
9954
+ kind?: '3d' | 'audio' | 'document' | 'image' | 'image-hdr' | 'json' | 'text' | 'video';
9707
9955
 
9708
9956
  /**
9709
9957
  * The label displayed in the UI for this input
@@ -10206,8 +10454,9 @@ export interface AssetListParams extends AssetsCursorParams {
10206
10454
  * 3d-texture-albedo, 3d-texture-normal, 3d-texture-roughness, 3d-texture-metallic,
10207
10455
  * img2video, txt2audio, audio2audio, audio2video, video2audio, voice-clone,
10208
10456
  * video2video, video2img, txt2img, img2img, txt2video, uploaded, uploaded-video,
10209
- * uploaded-audio, uploaded-3d, uploaded-avatar, upscale-video, assets with a type
10210
- * starting with "inference-" will be returned
10457
+ * uploaded-audio, uploaded-3d, uploaded-avatar, upscale-video, uploaded-text,
10458
+ * audio2txt, txt2txt, img2txt, assets with a type starting with "inference-" will
10459
+ * be returned
10211
10460
  */
10212
10461
  type?:
10213
10462
  | 'inference-txt2img'
@@ -10284,7 +10533,11 @@ export interface AssetListParams extends AssetsCursorParams {
10284
10533
  | 'uploaded-audio'
10285
10534
  | 'uploaded-3d'
10286
10535
  | 'uploaded-avatar'
10287
- | 'upscale-video';
10536
+ | 'upscale-video'
10537
+ | 'uploaded-text'
10538
+ | 'audio2txt'
10539
+ | 'txt2txt'
10540
+ | 'img2txt';
10288
10541
 
10289
10542
  /**
10290
10543
  * List of the asset types to request. The parameter "type" and "types" cannot be
@@ -10305,7 +10558,8 @@ export interface AssetListParams extends AssetsCursorParams {
10305
10558
  * 3d-texture-albedo, 3d-texture-normal, 3d-texture-roughness, 3d-texture-metallic,
10306
10559
  * img2video, txt2audio, audio2audio, audio2video, video2audio, voice-clone,
10307
10560
  * video2video, video2img, txt2img, img2img, txt2video, uploaded, uploaded-video,
10308
- * uploaded-audio, uploaded-3d, uploaded-avatar, upscale-video
10561
+ * uploaded-audio, uploaded-3d, uploaded-avatar, upscale-video, uploaded-text,
10562
+ * audio2txt, txt2txt, img2txt
10309
10563
  */
10310
10564
  types?: Array<
10311
10565
  | 'inference-txt2img'
@@ -10383,6 +10637,10 @@ export interface AssetListParams extends AssetsCursorParams {
10383
10637
  | 'uploaded-3d'
10384
10638
  | 'uploaded-avatar'
10385
10639
  | 'upscale-video'
10640
+ | 'uploaded-text'
10641
+ | 'audio2txt'
10642
+ | 'txt2txt'
10643
+ | 'img2txt'
10386
10644
  >;
10387
10645
 
10388
10646
  /**