@deepraxis/sdk 0.1.1-dev.5c83a98 → 0.1.1-dev.5f78678
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.
- package/METHODS.md +14 -1
- package/dist/generated/index.d.ts +2 -2
- package/dist/generated/index.js +1 -1
- package/dist/generated/sdk.gen.d.ts +80 -38
- package/dist/generated/sdk.gen.js +107 -37
- package/dist/generated/types.gen.d.ts +961 -90
- package/dist/operations.generated.d.ts +163 -52
- package/dist/operations.generated.js +193 -51
- package/dist/resources.generated.d.ts +13 -0
- package/dist/resources.generated.js +7 -0
- package/package.json +1 -1
|
@@ -1260,7 +1260,7 @@ export const fileCreateSignedUpload = (options) => (options.client ?? client).po
|
|
|
1260
1260
|
/**
|
|
1261
1261
|
* Create a download URL
|
|
1262
1262
|
*
|
|
1263
|
-
* Download a file's bytes to a local disk from a coding agent without sending them through the model. Use file_id from file creation or listing, then run curl -fsSL -o <filename> '<url>' locally with the returned URL; GET needs no Authorization header. The link is reusable until expiry and supports a single byte Range (for example Range: bytes=0-9 returns 206). Revoke it with files.contentLinks.revoke, passing the token after /c/ in the URL. Expired, revoked, invalid or cross-organization URLs return 404. Lifetime defaults to
|
|
1263
|
+
* Download a file's bytes to a local disk from a coding agent without sending them through the model. Use file_id from file creation or listing, then run curl -fsSL -o <filename> '<url>' locally with the returned URL; GET needs no Authorization header. The link is reusable until expiry and supports a single byte Range (for example Range: bytes=0-9 returns 206). Revoke it with files.contentLinks.revoke, passing the token after /c/ in the URL. Expired, revoked, invalid or cross-organization URLs return 404. Lifetime defaults to 900 seconds and is at most 604800 seconds. Issuance requires the same credential and file-read access as files.retrieveContent; a processing file returns 409 FILE_NOT_READY, so poll files.retrieve until active before retrying. A missing, expired or other-organization file returns 404. Each issuance creates a new link. OpenAI Files has no signed download URL; this follows S3 presigned GET semantics. Example body: {"ttl_seconds":3600}.
|
|
1264
1264
|
*/
|
|
1265
1265
|
export const fileCreateContentUrl = (options) => (options.client ?? client).post({
|
|
1266
1266
|
security: [{
|
|
@@ -1282,7 +1282,7 @@ export const fileCreateContentUrl = (options) => (options.client ?? client).post
|
|
|
1282
1282
|
/**
|
|
1283
1283
|
* Revoke a file content link
|
|
1284
1284
|
*
|
|
1285
|
-
* Stop a previously issued content link from reading a file. Obtain the link with files.contentUrl.create. Use file_id from file creation or listing and the token path component from a content URL (/c/<token>), not the complete URL. The caller must own the file and have write access; a read-only binding is refused. Revocation propagates through the capability deny list within
|
|
1285
|
+
* Stop a previously issued content link from reading a file. Obtain the link with files.contentUrl.create. Use file_id from file creation or listing and the token path component from a content URL (/c/<token>), not the complete URL. The caller must own the file and have write access; a read-only binding is refused. Revocation propagates through the capability deny list within 15 minutes; the file and other links remain available. Only current IAM capability tokens can be revoked; legacy content links expire at the migration deadline. Example body: {"token":"<token from /c/>"}.
|
|
1286
1286
|
*/
|
|
1287
1287
|
export const fileRevokeContentLink = (options) => (options.client ?? client).post({
|
|
1288
1288
|
security: [{
|
|
@@ -6373,7 +6373,7 @@ export const cutUndeleteProject = (options) => (options.client ?? client).post({
|
|
|
6373
6373
|
*
|
|
6374
6374
|
* ### Script function reference
|
|
6375
6375
|
*
|
|
6376
|
-
* Functions are synchronous globals; do not import them. `project` is the current project ID. TrackId and ClipId are strings returned by AddTrack and Insert or read from GetTimeline. Reads see earlier writes in the same script.
|
|
6376
|
+
* Functions are synchronous globals; do not import them. `project` is the current project ID. TrackId and ClipId are strings returned by AddTrack and Insert or read from GetTimeline. JoinId is the string returned by Join or read from GetTimeline().joins. Reads see earlier writes in the same script.
|
|
6377
6377
|
*
|
|
6378
6378
|
* ```ts
|
|
6379
6379
|
* GetTimeline(o?: { from?: number; to?: number; tracks?: TrackId[] }): TimelineView;
|
|
@@ -6382,9 +6382,14 @@ export const cutUndeleteProject = (options) => (options.client ?? client).post({
|
|
|
6382
6382
|
* GetMedia(ref: MediaRef): MediaInfo;
|
|
6383
6383
|
* GetTranscript(ref: MediaRef, o?: { from?: number; to?: number }): Word[];
|
|
6384
6384
|
* GetAnalysis(ref: MediaRef, kind: AnalysisKind): Segment[];
|
|
6385
|
+
* ListTransitions(): TransitionInfo[];
|
|
6385
6386
|
* Insert(track: TrackId, item: ItemInit, o?: { ripple?: boolean }): ClipId;
|
|
6386
6387
|
* Update(id: ClipId, patch: ItemPatchView): void;
|
|
6388
|
+
* SetSpeed(id: ClipId, rate: number, o: { keep: "source" | "duration"; ripple?: boolean }): { length: number; sourceOut: number };
|
|
6387
6389
|
* Delete(id: ClipId, o?: { ripple?: boolean }): void;
|
|
6390
|
+
* Join(left: ClipId, right: ClipId, o: { length?: number; effect: TransitionInput }): JoinId;
|
|
6391
|
+
* UpdateJoin(id: JoinId, patch: { length?: number; effect?: TransitionInput }): void;
|
|
6392
|
+
* DeleteJoin(id: JoinId): void;
|
|
6388
6393
|
* Split(id: ClipId, at: number): ClipId;
|
|
6389
6394
|
* Trim(id: ClipId, edge: "in" | "out", delta: number, o?: { ripple?: boolean }): void;
|
|
6390
6395
|
* Move(id: ClipId, start: number, track?: TrackId): void;
|
|
@@ -6401,11 +6406,14 @@ export const cutUndeleteProject = (options) => (options.client ?? client).post({
|
|
|
6401
6406
|
*
|
|
6402
6407
|
* | Functions | Behavior and arguments |
|
|
6403
6408
|
* | --- | --- |
|
|
6404
|
-
* | GetTimeline, GetItem | Read compact item views: id, track, type, start, end, length, optional media, sourceIn/sourceOut, text and offline reason. GetTimeline returns duration
|
|
6409
|
+
* | GetTimeline, GetItem | Read compact item views: id, track, type, start, end, length, optional media, playback, sourceIn/sourceOut, text and offline reason. GetTimeline returns duration, tracks (id, kind, name, index, locked, items), and joins (id, track, left, right, length in seconds, normalized effect). from/to and tracks narrow the items and joins; joins are selected by their overlap window. |
|
|
6410
|
+
* | ListTransitions | Discover the shared validation catalog: each entry contains kind (effect ID), name, description and params. Each parameter has name, type (enum/number/integer), default, description, enum values or numeric min/max. Use the returned kind and parameter names inside effect. |
|
|
6405
6411
|
* | FindItems | Visit items with their track and index; return undefined to omit an item, any other value to collect it. |
|
|
6406
6412
|
* | GetMedia | Read metadata for `{libraryId, assetId}` in a bound library: kind, dimensions, fps, hasAudio and durationUs when available. durationUs is microseconds. |
|
|
6407
6413
|
* | GetTranscript, GetAnalysis | Read available transcript words or silence/filler/scenes segments. Transcript filter from/to is seconds; returned word and segment from/to values are source microseconds (divide by 1,000,000 for editing). Words contain text and optional speaker/filler; segments may include label/confidence. Request analysis first if unavailable. |
|
|
6408
6414
|
* | Insert, Update, Delete | Insert returns the new clip ID; Update changes supplied fields; Delete removes the clip. Optional ripple on Insert/Delete closes or opens space on the track. |
|
|
6415
|
+
* | SetSpeed | Change video/audio rate in 0.25–4; keep is required. source preserves consumed source and changes length, duration preserves output length. Returns actual length and sourceOut in seconds. Optional ripple explicitly shifts same-track followers when keeping source; otherwise overlaps are rejected. |
|
|
6416
|
+
* | Join, UpdateJoin, DeleteJoin | Join creates an overlap between two butt-adjacent visual clips on the same track and returns its ID. length defaults to 0.5 seconds; effect is required. The right clip and all same-track followers move left by length, shortening that track and potentially the project. UpdateJoin moves those followers by the difference in length; omitted fields are preserved. DeleteJoin moves them right to restore the butt cut. Other tracks stay in place. |
|
|
6409
6417
|
* | Split, Trim, Move | Split at a timeline position and return the new right-hand clip ID. Trim changes the in or out edge by delta seconds. Move sets the timeline start and optionally a new track. |
|
|
6410
6418
|
* | RippleDeleteRange | Delete a timeline interval and close its gap on the specified tracks, or all unlocked tracks when omitted. |
|
|
6411
6419
|
* | AddTrack, UpdateTrack, DeleteTrack | Add video/audio/caption tracks; index selects layer order (0 is top). TrackPatch supports name, locked, hidden, muted, gainDb and style as appropriate to track kind. |
|
|
@@ -6414,18 +6422,26 @@ export const cutUndeleteProject = (options) => (options.client ?? client).post({
|
|
|
6414
6422
|
* | SetMarker | Add a label at a timeline time and return its ID. |
|
|
6415
6423
|
* | Print, Preview | Print appends text to prints. Preview requests up to eight times total per execute and puts images in the result's frames. Each url is an inline PNG data URL, not an HTTP image link. Decode the base64 payload to save an image. Codemode returns at most four images per call; request at most four times there. |
|
|
6416
6424
|
*
|
|
6425
|
+
* #### Joins between clips
|
|
6426
|
+
*
|
|
6427
|
+
* Endpoints may be video, image, text, color or shape; audio and caption are rejected. Require 0 < length < each endpoint's length. Each clip allows at most one incoming and one outgoing join; their summed lengths cannot exceed its length. Three-input overlaps, nonadjacent endpoints and cross-track joins are rejected with OPS_REJECTED. Read the rejection's code and message, shorten or remove conflicting joins, and retry the saved edit.
|
|
6428
|
+
*
|
|
6429
|
+
* TransitionInput is an object with kind plus the parameters returned by ListTransitions; omitted parameters use the catalog defaults. Unknown kinds and unknown or invalid parameters are rejected. Effects: dissolve (no parameters); dip (color black/white, default black); push and wipe (direction left/right/up/down, default left); wipe also has softness 0–1, default 0; iris has centerX/centerY 0–1, both default 0.5; blinds has integer count 2–64, default 8, and orientation vertical/horizontal, default vertical; blur has radius 0–100 pixels at 1080-pixel frame height, default 24. Join options and UpdateJoin patches accept only length and effect. Effect updates replace the effect object and apply defaults for omitted parameters.
|
|
6430
|
+
*
|
|
6431
|
+
* Minimal example on an existing visual track with adjacent clips left and right: `Print(ListTransitions()); const j = Join(left, right, {length: 0.5, effect: {kind: "dissolve"}}); Print(GetTimeline().joins); Preview([GetItem(right).start + 0.25]);` Use `UpdateJoin(j, {length: 0.8})` to adjust it in a later edit or `DeleteJoin(j)` to restore the cut. Preview uses server-rendered frames and includes joins. Per-clip transitionIn/transitionOut remain separate entrance/exit effects.
|
|
6432
|
+
*
|
|
6417
6433
|
* #### Insert fields (ItemInit)
|
|
6418
6434
|
*
|
|
6419
6435
|
* Every item requires `type` and `start`. Times used for editing are seconds and snap to the project frame rate: start, length, sourceIn, fadeIn/fadeOut, transition length, keyframe at, reveal delay/stagger/duration. Keyframe and reveal times are relative to the clip start. Video/audio may omit length to use the remaining source duration; other types require length.
|
|
6420
6436
|
*
|
|
6421
6437
|
* | type | Required fields beyond type/start | Optional fields |
|
|
6422
6438
|
* | --- | --- | --- |
|
|
6423
|
-
* | video | media | length, sourceIn, volumeDb, transform, fit, animate, transitionIn, transitionOut |
|
|
6439
|
+
* | video | media | length, sourceIn, playback, volumeDb, transform, fit, animate, transitionIn, transitionOut |
|
|
6424
6440
|
* | image | media, length | transform, fit, animate, transitionIn, transitionOut |
|
|
6425
6441
|
* | text | text, length | style, transform, reveal, animate, transitionIn, transitionOut |
|
|
6426
6442
|
* | color | color, length | transform, fill, animate, transitionIn, transitionOut |
|
|
6427
6443
|
* | shape | shape, length, width, height, fill | radius, stroke, transform, animate, transitionIn, transitionOut |
|
|
6428
|
-
* | audio | media | length, sourceIn, volumeDb, fadeIn, fadeOut
|
|
6444
|
+
* | audio | media | length, sourceIn, playback, volumeDb, fadeIn, fadeOut |
|
|
6429
6445
|
* | caption | text, length | — |
|
|
6430
6446
|
*
|
|
6431
6447
|
* Video tracks accept video/image/text/color/shape; audio and caption tracks accept their corresponding type. Media is `{libraryId: string, assetId: string}` from a bound library. sourceIn defaults to 0, volumeDb to 0 dB, audio fades to 0 seconds. fit defaults to contain: contain fits the whole image, cover fills and crops, fill stretches, none keeps native dimensions.
|
|
@@ -6433,7 +6449,7 @@ export const cutUndeleteProject = (options) => (options.client ?? client).post({
|
|
|
6433
6449
|
* | Field | Value |
|
|
6434
6450
|
* | --- | --- |
|
|
6435
6451
|
* | transform | Partial `{x, y, scale, rotation, opacity, crop, blur}`. x/y are normalized canvas center coordinates (default 0.5); scale 1 is fitted size; rotation is degrees (default 0); opacity is 0–1 (default 1). crop is `{top,right,bottom,left}`. blur is 0–100 pixels at 1080-pixel frame height. |
|
|
6436
|
-
* | style | Partial `{fontFamily, fontSize, fontWeight, color, stroke, background, align, maxWidth}`. fontFamily: Geist or Noto Sans SC (default); fontSize defaults to 48; fontWeight: 400 (default), 500 or 700; color defaults to #FFFFFF; align: left, center (default), right; maxWidth is a fraction of canvas width (default 0.9). stroke is `{color,width}`.
|
|
6452
|
+
* | style | Partial `{fontFamily, fontSize, fontWeight, color, stroke, background, align, maxWidth, position, margin}`. fontFamily: Geist or Noto Sans SC (default); fontSize defaults to 48; fontWeight: 400 (default), 500 or 700; color defaults to #FFFFFF; align: left, center (default), right; maxWidth is a fraction of canvas width (default 0.9). stroke is `{color,width}`. Text and captions support position (top/middle/bottom; box centers at 12%/50%/85% of height without margin) and optional margin (0–0.4 of canvas height, box edge distance for top/bottom; middle ignores it). Omitted position preserves the text transform (center by default); explicit position controls vertical placement, so omit it for y animation. Caption style additionally supports highlightColor and maxLines: 2. GetItem and GetTimeline return text style and current caption track style. Caption tracks only accept captions; use AddCaptionsFromTranscript, and place text on video tracks. |
|
|
6437
6453
|
* | animate | An object keyed by x, y, scale, rotation, opacity or blur. Each value is an array of `{at: number, value: number, ease?: Ease}` sorted by at with distinct frame-snapped times. Values hold before the first and after the last keyframe, overriding the static transform. |
|
|
6438
6454
|
* | Ease | linear, in, out, inOut, `{bezier: [x1,y1,x2,y2]}` or `{spring: {stiffness, damping, mass?}}`. Easing shapes the segment arriving at that keyframe; springs may overshoot. |
|
|
6439
6455
|
* | reveal | `{by, delay?: number, stagger: number, duration: number, from: {y?, opacity?, scale?, blur?}, ease?: Ease}`. by selects char, word or line. Unit k starts at delay + k * stagger and takes duration seconds to reach its resting state; from.y is a fraction of font size. |
|
|
@@ -6443,7 +6459,15 @@ export const cutUndeleteProject = (options) => (options.client ?? client).post({
|
|
|
6443
6459
|
*
|
|
6444
6460
|
* #### Update fields (ItemPatchView)
|
|
6445
6461
|
*
|
|
6446
|
-
* All fields are optional; use only fields relevant to the item's type. Supported fields: start, length, sourceIn, volumeDb, transform, fit, text, style, color, fadeIn, fadeOut, animate, reveal, fill, stroke, shape, width, height, radius, transitionIn, transitionOut. Values and units match Insert. Set animate, reveal, fill, stroke, transitionIn or transitionOut to null to remove that effect; omitting a field preserves it. For example: `Update(id, {volumeDb: -12})` or `Update(id, {transitionIn: null})`.
|
|
6462
|
+
* All fields are optional; use only fields relevant to the item's type. Supported fields: start, length, sourceIn, playback, volumeDb, transform, fit, text, style, color, fadeIn, fadeOut, animate, reveal, fill, stroke, shape, width, height, radius, transitionIn, transitionOut. Values and units match Insert. Set animate, reveal, fill, stroke, transitionIn or transitionOut to null to remove that effect; omitting a field preserves it. For example: `Update(id, {volumeDb: -12})` or `Update(id, {transitionIn: null})`.
|
|
6463
|
+
*
|
|
6464
|
+
* #### Speed, reverse and freeze
|
|
6465
|
+
*
|
|
6466
|
+
* Video/audio Insert and Update accept playback as `{kind: "rate", rate: number, direction: "forward" | "reverse", audio: "preservePitch" | "resample" | "mute"}` or `{kind: "freeze"}`. Rate is finite and inclusive 0.25–4. Omitted playback defaults to 1× forward with preservePitch; supply the complete rate object when changing playback. preservePitch keeps pitch, resample changes pitch with speed, mute removes audio. Reverse requires explicit audio: "mute"; preservePitch/resample are rejected with UNSUPPORTED_PLAYBACK rather than silently muted. Freeze holds sourceIn and is silent. GetItem/GetTimeline echo playback and the source interval in seconds; sourceOut is exclusive even for reverse and equals sourceIn for freeze.
|
|
6467
|
+
*
|
|
6468
|
+
* Update of playback keeps output length unless length is also supplied. SetSpeed preserves direction/audio, rejects frozen and non-video/audio clips, and requires keep: "source" or "duration". keep: "source" computes round(consumed source / new rate × fps) frames, falling back to floor if rounding would exceed the source end; the returned length/sourceOut are actual frame-rounded seconds. keep: "duration" keeps output length and changes source consumption. Length conflicts fail with OVERLAP; move/shorten the conflicting clip, keep duration, or explicitly use ripple: true to shift following clips on the same track. Source overflow fails with OUT_OF_SOURCE; rate limits fail with RATE_OUT_OF_RANGE. Unknown playback fields and SetSpeed options are rejected with UNKNOWN_FIELD; options only accept keep and boolean ripple.
|
|
6469
|
+
*
|
|
6470
|
+
* Example for an existing four-second video/audio clip id: `Print(SetSpeed(id, 0.5, {keep: "source"})); Print(SetSpeed(id, 2, {keep: "source"}));` returns lengths 8 then 2, keeping the same source interval. Reverse: `Update(id, {playback: {kind: "rate", rate: 1, direction: "reverse", audio: "mute"}})`. Freeze: `Update(id, {playback: {kind: "freeze"}})`. Ensure enough source remains for the chosen length/rate. Browser reverse playback currently displays a placeholder; server-rendered Preview/frames and exports support reverse normally. Speed-adjusted audio is generated asynchronously after the edit transaction commits; exports wait for that audio before rendering.
|
|
6447
6471
|
*
|
|
6448
6472
|
* #### Script names versus HTTP response names
|
|
6449
6473
|
*
|
|
@@ -6508,7 +6532,7 @@ export const cutRetrieveTimeline = (options) => (options.client ?? client).get({
|
|
|
6508
6532
|
/**
|
|
6509
6533
|
* Render preview frames
|
|
6510
6534
|
*
|
|
6511
|
-
* Review the visual result at one or more project times without creating an export. Pass comma-separated seconds in at, such as 12,15.5; scale changes preview size and revision selects a committed project revision. Request at most eight times. Each returned url is an inline PNG data URL (data:image/png;base64,...), not a hosted HTTP image link. Decode its base64 payload to save the image. Codemode returns at most four images per call, so request at most four times when reviewing there.
|
|
6535
|
+
* Review the visual result at one or more project times without creating an export. Pass comma-separated seconds in at, such as 12,15.5; scale changes preview size and revision selects a committed project revision. Request at most eight times. Each returned url is an inline PNG data URL (data:image/png;base64,...), not a hosted HTTP image link. The default scale is 0.25; use 0.5 for subtitle layout inspection (1080×1920 renders at 540×960). The maximum is 0.5; values above it return INVALID_PARAMS. Actual width and height are returned per frame. PNGs above 2 MiB or responses above 4 MiB return RESPONSE_TOO_LARGE without silently lowering resolution. FRAME_UNAVAILABLE warnings on execute mean a source preview could not be fetched and an offline tile was drawn; edits still commit, and this warning alone does not establish that the source media is broken. Decode its base64 payload to save the image. Codemode returns at most four images per call, so request at most four times when reviewing there.
|
|
6512
6536
|
*/
|
|
6513
6537
|
export const cutListFrames = (options) => (options.client ?? client).get({
|
|
6514
6538
|
security: [{
|
|
@@ -6526,7 +6550,7 @@ export const cutListFrames = (options) => (options.client ?? client).get({
|
|
|
6526
6550
|
/**
|
|
6527
6551
|
* Analyze project media
|
|
6528
6552
|
*
|
|
6529
|
-
* Request silence, filler-word or scene analysis for selected bound assets before editing. Omit media to select project sources; ranges returned in segments use source seconds. A pending result is not completion: use retry_after_sec before checking again, and inspect failed or unsupported asset results before deciding which edits are possible.
|
|
6553
|
+
* Request silence, filler-word or scene analysis for selected bound assets before editing. Omit media to select project sources; ranges returned in segments use source seconds. A pending result is not completion: use retry_after_sec before checking again, and inspect failed or unsupported asset results before deciding which edits are possible. Silence measures transcript-based speech pauses, not music or loudness. A completed transcript without words returns ready with empty segments and reason no_speech; no completed transcript returns unsupported with reason no_transcript. A failed transcription remains failed.
|
|
6530
6554
|
*/
|
|
6531
6555
|
export const cutCreateAnalysis = (options) => (options.client ?? client).post({
|
|
6532
6556
|
security: [{
|
|
@@ -7104,7 +7128,7 @@ export const knowledgeListVectorStores = (options) => (options?.client ?? client
|
|
|
7104
7128
|
/**
|
|
7105
7129
|
* Create knowledge base
|
|
7106
7130
|
*
|
|
7107
|
-
* Create a knowledge base, optionally starting ingestion of uploaded file_ids in the same call; no separate attachment or batch is needed for those files. Use the returned id with vectorStores.files.retrieve to poll each attachment until completed, failed or cancelled; store status=completed alone does not mean every file succeeded.
|
|
7131
|
+
* Create a knowledge base, optionally starting ingestion of uploaded file_ids in the same call; no separate attachment or batch is needed for those files. Use the returned id with vectorStores.files.retrieve to poll each attachment until completed, failed or cancelled; store status=completed alone does not mean every file succeeded. PDF files accept up to 536870912 bytes (512 MiB), while other formats accept up to 52428800 bytes (50 MiB), constrained by Router conversion; every file is limited to 5000000 estimated tokens; each account holds up to 100 active/nondeleted stores. Minimal body: {"name":"Refund policies"}.
|
|
7108
7132
|
*/
|
|
7109
7133
|
export const knowledgeCreateVectorStore = (options) => (options.client ?? client).post({
|
|
7110
7134
|
security: [{
|
|
@@ -7200,7 +7224,7 @@ export const knowledgeListFiles = (options) => (options.client ?? client).get({
|
|
|
7200
7224
|
/**
|
|
7201
7225
|
* Add file
|
|
7202
7226
|
*
|
|
7203
|
-
* Attach an uploaded File for asynchronous ingestion, then poll this attachment until status is completed, failed or cancelled before searching.
|
|
7227
|
+
* Attach an uploaded File for asynchronous ingestion, then poll this attachment until status is completed, failed or cancelled before searching. PDF files accept up to 536870912 bytes (512 MiB), while other formats accept up to 52428800 bytes (50 MiB), constrained by Router conversion; every file is limited to 5000000 estimated tokens; chunk sizes use estimated tokens rather than a model tokenizer. Text, Markdown, CSV, JSON, HTML, PDF, DOCX, PPTX, XLSX and PNG/JPEG/GIF/WebP images can be extracted; audio and video uploads are not knowledge documents. Images may yield generated descriptions rather than verbatim OCR. auto chunking resolves to static 800/400; explicit sizes are 100–4096 with overlap at most half the size. Each store holds at most 10000 attached files. Reattaching the same file returns its existing record without applying new attributes or chunking; inspect last_error after failure.
|
|
7204
7228
|
*/
|
|
7205
7229
|
export const knowledgeAttachFile = (options) => (options.client ?? client).post({
|
|
7206
7230
|
security: [{
|
|
@@ -7422,7 +7446,7 @@ export const knowledgeListEvents = (options) => (options.client ?? client).get({
|
|
|
7422
7446
|
/**
|
|
7423
7447
|
* List libraries
|
|
7424
7448
|
*
|
|
7425
|
-
*
|
|
7449
|
+
* Read a caller-owned library’s current settings, usage and lifecycle status. A deleting library remains readable; missing, foreign or purged libraries return LIBRARY_NOT_FOUND.
|
|
7426
7450
|
*/
|
|
7427
7451
|
export const mediaListLibraries = (options) => (options?.client ?? client).get({
|
|
7428
7452
|
security: [{
|
|
@@ -7451,10 +7475,28 @@ export const mediaCreateLibrary = (options) => (options.client ?? client).post({
|
|
|
7451
7475
|
...options.headers
|
|
7452
7476
|
}
|
|
7453
7477
|
});
|
|
7478
|
+
/**
|
|
7479
|
+
* Create frame URLs
|
|
7480
|
+
*
|
|
7481
|
+
* Media creates JPEG frame URLs for inspecting one or more moments in a video without downloading the original. Obtain library_id from libraries and asset_id plus duration from assets. Send 1–20 integer microsecond timestamps strictly below duration, for example {"at_micros":[0,1000000],"width":640}. Only video assets are supported; audio and images return INVALID_PARAMS. Width defaults to 640 and accepts 160, 320 or 640. This read operation does not store a new asset or rerun understanding. Fetch each returned URL to obtain the frame; delivery usage follows media pricing. Authenticated links expire after 300 seconds; upload links remain public and permanent. Reissue expired links. Foreign libraries and assets return 404 without revealing their existence.
|
|
7482
|
+
*/
|
|
7483
|
+
export const mediaCreateFrameUrls = (options) => (options.client ?? client).post({
|
|
7484
|
+
security: [{
|
|
7485
|
+
key: 'media-BearerAuth',
|
|
7486
|
+
scheme: 'bearer',
|
|
7487
|
+
type: 'http'
|
|
7488
|
+
}],
|
|
7489
|
+
url: '/media/v1/libraries/{library_id}/assets/{asset_id}/frames',
|
|
7490
|
+
...options,
|
|
7491
|
+
headers: {
|
|
7492
|
+
'Content-Type': 'application/json',
|
|
7493
|
+
...options.headers
|
|
7494
|
+
}
|
|
7495
|
+
});
|
|
7454
7496
|
/**
|
|
7455
7497
|
* Delete library
|
|
7456
7498
|
*
|
|
7457
|
-
*
|
|
7499
|
+
* Restore a deleting library before its purge_at deadline. The library becomes active again and deleted_at and purge_at are cleared; expired or non-deleting libraries cannot be restored.
|
|
7458
7500
|
*/
|
|
7459
7501
|
export const mediaDeleteLibrary = (options) => (options.client ?? client).delete({
|
|
7460
7502
|
security: [{
|
|
@@ -7468,7 +7510,7 @@ export const mediaDeleteLibrary = (options) => (options.client ?? client).delete
|
|
|
7468
7510
|
/**
|
|
7469
7511
|
* Get library
|
|
7470
7512
|
*
|
|
7471
|
-
*
|
|
7513
|
+
* Update an active library’s supplied settings. Labels replace the complete map; understanding settings and model roles merge with current values. Changing the embedding model is rejected while assets exist.
|
|
7472
7514
|
*/
|
|
7473
7515
|
export const mediaGetLibrary = (options) => (options.client ?? client).get({
|
|
7474
7516
|
security: [{
|
|
@@ -7482,7 +7524,7 @@ export const mediaGetLibrary = (options) => (options.client ?? client).get({
|
|
|
7482
7524
|
/**
|
|
7483
7525
|
* Update library
|
|
7484
7526
|
*
|
|
7485
|
-
* Update an active library
|
|
7527
|
+
* Update an active library. Set hotwords for spelling evidence in subsequent transcripts; [] disables inferred vocabulary. Transcript understanding calls the timestamped ASR, optional reference ASR and correction model through the existing metered model path. Reprocess assets to apply new settings to existing transcripts.
|
|
7486
7528
|
*/
|
|
7487
7529
|
export const mediaUpdateLibrary = (options) => (options.client ?? client).patch({
|
|
7488
7530
|
security: [{
|
|
@@ -7500,7 +7542,7 @@ export const mediaUpdateLibrary = (options) => (options.client ?? client).patch(
|
|
|
7500
7542
|
/**
|
|
7501
7543
|
* Restore library
|
|
7502
7544
|
*
|
|
7503
|
-
*
|
|
7545
|
+
* Permanently remove a library that is already deleting, without waiting for purge_at. Its assets and related resources are removed and cannot be restored; first soft-delete an active library.
|
|
7504
7546
|
*/
|
|
7505
7547
|
export const mediaRestoreLibrary = (options) => (options.client ?? client).post({
|
|
7506
7548
|
security: [{
|
|
@@ -7514,7 +7556,7 @@ export const mediaRestoreLibrary = (options) => (options.client ?? client).post(
|
|
|
7514
7556
|
/**
|
|
7515
7557
|
* Purge library
|
|
7516
7558
|
*
|
|
7517
|
-
*
|
|
7559
|
+
* List assets in an active library, newest first, optionally filtering by exact folder and stored resource type. Continue using next_cursor; video includes audio-only assets.
|
|
7518
7560
|
*/
|
|
7519
7561
|
export const mediaPurgeLibrary = (options) => (options.client ?? client).post({
|
|
7520
7562
|
security: [{
|
|
@@ -7528,7 +7570,7 @@ export const mediaPurgeLibrary = (options) => (options.client ?? client).post({
|
|
|
7528
7570
|
/**
|
|
7529
7571
|
* List assets
|
|
7530
7572
|
*
|
|
7531
|
-
*
|
|
7573
|
+
* Upload content into an active library and return a Cloudinary-compatible resource. Use file for a multipart file, data URI, public HTTPS URL or same-owner file identifier. Reusing public_id overwrites by default; overwrite=false returns the existing resource. Chunk uploads require both chunk headers.
|
|
7532
7574
|
*/
|
|
7533
7575
|
export const mediaListAssets = (options) => (options.client ?? client).get({
|
|
7534
7576
|
security: [{
|
|
@@ -7542,7 +7584,7 @@ export const mediaListAssets = (options) => (options.client ?? client).get({
|
|
|
7542
7584
|
/**
|
|
7543
7585
|
* Upload asset
|
|
7544
7586
|
*
|
|
7545
|
-
*
|
|
7587
|
+
* For understanding, Media generates proxies for video or audio sources of 100 MB or more; originals remain available unchanged. The duration limit is 10 minutes. A video proxy still above 95 MB after recompression, or a source exceeding the duration limit, is reported as UNSUPPORTED with the limit in the failure message. Proxy preparation uses the organization’s metered sandbox resources.
|
|
7546
7588
|
*/
|
|
7547
7589
|
export const mediaUploadAsset = (options) => (options.client ?? client).post({
|
|
7548
7590
|
security: [{
|
|
@@ -7560,7 +7602,7 @@ export const mediaUploadAsset = (options) => (options.client ?? client).post({
|
|
|
7560
7602
|
/**
|
|
7561
7603
|
* Import file
|
|
7562
7604
|
*
|
|
7563
|
-
* Copy
|
|
7605
|
+
* Copy a File into an independent Media asset. Defaults to public delivery (type=upload); use type=authenticated for private originals and derivatives. Deleting the source File does not delete this copy. For understanding, Media generates proxies for video or audio sources of 100 MB or more; originals remain available unchanged. The duration limit is 10 minutes. A video proxy still above 95 MB after recompression, or a source exceeding the duration limit, is reported as UNSUPPORTED with the limit in the failure message. Proxy preparation uses the organization’s metered sandbox resources.
|
|
7564
7606
|
*/
|
|
7565
7607
|
export const mediaImportAsset = (options) => (options.client ?? client).post({
|
|
7566
7608
|
security: [{
|
|
@@ -7578,7 +7620,7 @@ export const mediaImportAsset = (options) => (options.client ?? client).post({
|
|
|
7578
7620
|
/**
|
|
7579
7621
|
* Delete asset
|
|
7580
7622
|
*
|
|
7581
|
-
*
|
|
7623
|
+
* Queue reprocessing of the asset’s current version and return its updated state immediately. Omit kinds to retry failed tasks and legacy source-size unsupported tasks; explicit kinds rerun applicable completed tasks and recoverable source-size unsupported tasks. Other unsupported causes remain unchanged. Replaced understandings become superseded, and processing finishes asynchronously.
|
|
7582
7624
|
*/
|
|
7583
7625
|
export const mediaDeleteAsset = (options) => (options.client ?? client).delete({
|
|
7584
7626
|
security: [{
|
|
@@ -7592,7 +7634,7 @@ export const mediaDeleteAsset = (options) => (options.client ?? client).delete({
|
|
|
7592
7634
|
/**
|
|
7593
7635
|
* Get asset
|
|
7594
7636
|
*
|
|
7595
|
-
*
|
|
7637
|
+
* Update an asset’s supplied metadata fields. Tags and context replace their current collections; an empty collection clears them. Moving asset_folder or changing display_name preserves public_id and delivery URLs.
|
|
7596
7638
|
*/
|
|
7597
7639
|
export const mediaGetAsset = (options) => (options.client ?? client).get({
|
|
7598
7640
|
security: [{
|
|
@@ -7606,7 +7648,7 @@ export const mediaGetAsset = (options) => (options.client ?? client).get({
|
|
|
7606
7648
|
/**
|
|
7607
7649
|
* Update asset
|
|
7608
7650
|
*
|
|
7609
|
-
*
|
|
7651
|
+
* Delete an asset from the library so it is no longer readable, searchable or deliverable. This removes the asset rather than placing it in the library’s restoration window; a missing asset returns ASSET_NOT_FOUND.
|
|
7610
7652
|
*/
|
|
7611
7653
|
export const mediaUpdateAsset = (options) => (options.client ?? client).patch({
|
|
7612
7654
|
security: [{
|
|
@@ -7624,7 +7666,7 @@ export const mediaUpdateAsset = (options) => (options.client ?? client).patch({
|
|
|
7624
7666
|
/**
|
|
7625
7667
|
* Reprocess asset
|
|
7626
7668
|
*
|
|
7627
|
-
*
|
|
7669
|
+
* For understanding, Media generates proxies for video or audio sources of 100 MB or more; originals remain available unchanged. The duration limit is 10 minutes. A video proxy still above 95 MB after recompression, or a source exceeding the duration limit, is reported as UNSUPPORTED with the limit in the failure message. Proxy preparation uses the organization’s metered sandbox resources.
|
|
7628
7670
|
*/
|
|
7629
7671
|
export const mediaReprocessAsset = (options) => (options.client ?? client).post({
|
|
7630
7672
|
security: [{
|
|
@@ -7642,7 +7684,7 @@ export const mediaReprocessAsset = (options) => (options.client ?? client).post(
|
|
|
7642
7684
|
/**
|
|
7643
7685
|
* List understandings
|
|
7644
7686
|
*
|
|
7645
|
-
* List an asset
|
|
7687
|
+
* List understanding results for an asset, ordered by creation time. Use the cursor to continue; include_superseded also returns replaced records. The optional shots array contains current-version shot boundaries and per-shot captions, scene, location guesses, visible text and confidence flags; it is absent on legacy records. Location guesses and folder mismatch are unverified hints. Correction-enabled transcripts expose text_original, corrected text and a correction audit. Their timed data array remains suitable for subtitles. Reference failure is marked missing; correction failure returns the original verbatim. Model inference uses the existing metered model path.
|
|
7646
7688
|
*/
|
|
7647
7689
|
export const mediaListUnderstandings = (options) => (options.client ?? client).get({
|
|
7648
7690
|
security: [{
|
|
@@ -7656,7 +7698,7 @@ export const mediaListUnderstandings = (options) => (options.client ?? client).g
|
|
|
7656
7698
|
/**
|
|
7657
7699
|
* Expression search
|
|
7658
7700
|
*
|
|
7659
|
-
*
|
|
7701
|
+
* Find visually similar assets using exactly one of asset_id or an inline base64 image. The library must support image search; an asset query needs a current image embedding and excludes that source asset from results.
|
|
7660
7702
|
*/
|
|
7661
7703
|
export const mediaExpressionSearch = (options) => (options.client ?? client).post({
|
|
7662
7704
|
security: [{
|
|
@@ -7674,7 +7716,7 @@ export const mediaExpressionSearch = (options) => (options.client ?? client).pos
|
|
|
7674
7716
|
/**
|
|
7675
7717
|
* Visual search
|
|
7676
7718
|
*
|
|
7677
|
-
*
|
|
7719
|
+
* Search assets with a nonblank text query and optional expression filter. Hybrid mode combines semantic and keyword matches; semantic mode uses vector similarity only. Results are ranked and limited by top_k.
|
|
7678
7720
|
*/
|
|
7679
7721
|
export const mediaVisualSearch = (options) => (options.client ?? client).post({
|
|
7680
7722
|
security: [{
|
|
@@ -7692,7 +7734,7 @@ export const mediaVisualSearch = (options) => (options.client ?? client).post({
|
|
|
7692
7734
|
/**
|
|
7693
7735
|
* Semantic search
|
|
7694
7736
|
*
|
|
7695
|
-
* Search assets with a nonblank text query
|
|
7737
|
+
* Alias of semantic search. Search assets with a nonblank text query, optional expression filter and top_k; hybrid combines semantic and keyword matches, while semantic uses vector similarity only.
|
|
7696
7738
|
*/
|
|
7697
7739
|
export const mediaSemanticSearch = (options) => (options.client ?? client).post({
|
|
7698
7740
|
security: [{
|
|
@@ -7710,7 +7752,7 @@ export const mediaSemanticSearch = (options) => (options.client ?? client).post(
|
|
|
7710
7752
|
/**
|
|
7711
7753
|
* Semantic search alias
|
|
7712
7754
|
*
|
|
7713
|
-
*
|
|
7755
|
+
* List all immediate child folders under parent, or under the root when parent is omitted. Counts include descendant assets. The result is unpaginated; limit and cursor are rejected.
|
|
7714
7756
|
*/
|
|
7715
7757
|
export const mediaSearch = (options) => (options.client ?? client).post({
|
|
7716
7758
|
security: [{
|
|
@@ -7728,7 +7770,7 @@ export const mediaSearch = (options) => (options.client ?? client).post({
|
|
|
7728
7770
|
/**
|
|
7729
7771
|
* List folders
|
|
7730
7772
|
*
|
|
7731
|
-
*
|
|
7773
|
+
* undefined understood_count includes ready and partial assets; failed_count includes failed assets. Both accumulate descendants. counts_complete is false during historical backfill.
|
|
7732
7774
|
*/
|
|
7733
7775
|
export const mediaListFolders = (options) => (options.client ?? client).get({
|
|
7734
7776
|
security: [{
|
|
@@ -7742,7 +7784,7 @@ export const mediaListFolders = (options) => (options.client ?? client).get({
|
|
|
7742
7784
|
/**
|
|
7743
7785
|
* Create batch
|
|
7744
7786
|
*
|
|
7745
|
-
*
|
|
7787
|
+
* Queue a frozen selection for tagging, untagging, context replacement, moving, deleting or reprocessing. IDs are limited to 1000; use an expression for larger selections, subject to the search scan budget. reprocess starts at most 30 assets per rolling minute per library. Only retryable failed steps and legacy source-size unsupported steps rerun. Omit kinds to inspect all recoverable steps, or supply kinds to narrow them. Other unsupported, permanent and completed steps remain unchanged; a permanent output blocks only its own step. Assets without any selected recoverable step count as failed items without starting understanding. Poll the returned job id; done counts accepted launches, not successful model inference. Staff Admin only permits reprocess and requires a nonblank reason. Example: {"action":"reprocess","selector":{"expression":"processing_state=failed AND failure_code=UPSTREAM_FAILED"}}. For understanding, Media generates proxies for video or audio sources of 100 MB or more; originals remain available unchanged. The duration limit is 10 minutes. A video proxy still above 95 MB after recompression, or a source exceeding the duration limit, is reported as UNSUPPORTED with the limit in the failure message. Proxy preparation uses the organization’s metered sandbox resources.
|
|
7746
7788
|
*/
|
|
7747
7789
|
export const mediaCreateBatch = (options) => (options.client ?? client).post({
|
|
7748
7790
|
security: [{
|
|
@@ -7760,7 +7802,7 @@ export const mediaCreateBatch = (options) => (options.client ?? client).post({
|
|
|
7760
7802
|
/**
|
|
7761
7803
|
* Get batch
|
|
7762
7804
|
*
|
|
7763
|
-
*
|
|
7805
|
+
* Alias of batch creation. Apply one metadata or deletion action to ids or a frozen expression selection asynchronously; poll the returned job id to inspect completion and item failures.
|
|
7764
7806
|
*/
|
|
7765
7807
|
export const mediaGetBatch = (options) => (options.client ?? client).get({
|
|
7766
7808
|
security: [{
|
|
@@ -7774,7 +7816,7 @@ export const mediaGetBatch = (options) => (options.client ?? client).get({
|
|
|
7774
7816
|
/**
|
|
7775
7817
|
* Batch assets alias
|
|
7776
7818
|
*
|
|
7777
|
-
*
|
|
7819
|
+
* Queue a frozen selection for tagging, untagging, context replacement, moving, deleting or reprocessing. IDs are limited to 1000; use an expression for larger selections, subject to the search scan budget. reprocess starts at most 30 assets per rolling minute per library. Only retryable failed steps and legacy source-size unsupported steps rerun. Omit kinds to inspect all recoverable steps, or supply kinds to narrow them. Other unsupported, permanent and completed steps remain unchanged; a permanent output blocks only its own step. Assets without any selected recoverable step count as failed items without starting understanding. Poll the returned job id; done counts accepted launches, not successful model inference. Staff Admin only permits reprocess and requires a nonblank reason. Example: {"action":"reprocess","selector":{"expression":"processing_state=failed AND failure_code=UPSTREAM_FAILED"}}. For understanding, Media generates proxies for video or audio sources of 100 MB or more; originals remain available unchanged. The duration limit is 10 minutes. A video proxy still above 95 MB after recompression, or a source exceeding the duration limit, is reported as UNSUPPORTED with the limit in the failure message. Proxy preparation uses the organization’s metered sandbox resources.
|
|
7778
7820
|
*/
|
|
7779
7821
|
export const mediaBatchAssets = (options) => (options.client ?? client).post({
|
|
7780
7822
|
security: [{
|
|
@@ -7792,7 +7834,7 @@ export const mediaBatchAssets = (options) => (options.client ?? client).post({
|
|
|
7792
7834
|
/**
|
|
7793
7835
|
* Get job alias
|
|
7794
7836
|
*
|
|
7795
|
-
*
|
|
7837
|
+
* Read library events in sequence order, including while the library is deleting. Page forward with asc and after_seq, or backward with desc and before_seq; never combine the two sequence cursors.
|
|
7796
7838
|
*/
|
|
7797
7839
|
export const mediaGetJob = (options) => (options.client ?? client).get({
|
|
7798
7840
|
security: [{
|
|
@@ -7806,7 +7848,7 @@ export const mediaGetJob = (options) => (options.client ?? client).get({
|
|
|
7806
7848
|
/**
|
|
7807
7849
|
* List events
|
|
7808
7850
|
*
|
|
7809
|
-
* Read library events in sequence order
|
|
7851
|
+
* Read library events in sequence order for observing asset writes and understanding progress. Obtain library_id from creation or listing; continue with after_seq for asc or before_seq for desc, without combining both. Use next_cursor when supplied. Reads do not start or retry understanding.
|
|
7810
7852
|
*/
|
|
7811
7853
|
export const mediaListEvents = (options) => (options.client ?? client).get({
|
|
7812
7854
|
security: [{
|
|
@@ -7820,7 +7862,7 @@ export const mediaListEvents = (options) => (options.client ?? client).get({
|
|
|
7820
7862
|
/**
|
|
7821
7863
|
* Create delivery token
|
|
7822
7864
|
*
|
|
7823
|
-
* Issue a time-limited bearer token for originals and transformed authenticated assets in an active library. Use library_id from library creation or listing; read access is sufficient. Append token as the __cld_token__ query parameter on a matching delivery URL. The default ACL covers this library and the default lifetime is
|
|
7865
|
+
* Issue a time-limited bearer token for originals and transformed authenticated assets in an active library. Use library_id from library creation or listing; read access is sufficient. Append token as the __cld_token__ query parameter on a matching delivery URL. The default ACL covers this library and the default lifetime is 900 seconds; narrow acl and expires_in before sharing. Anyone holding the token can read matching paths until expires_at.
|
|
7824
7866
|
*/
|
|
7825
7867
|
export const mediaCreateDeliveryToken = (options) => (options.client ?? client).post({
|
|
7826
7868
|
security: [{
|
|
@@ -7835,6 +7877,34 @@ export const mediaCreateDeliveryToken = (options) => (options.client ?? client).
|
|
|
7835
7877
|
...options.headers
|
|
7836
7878
|
}
|
|
7837
7879
|
});
|
|
7880
|
+
/**
|
|
7881
|
+
* Summarize understanding failures
|
|
7882
|
+
*
|
|
7883
|
+
* Inspect current understanding failures before retrying. Use library_id from library creation or listing. Groups include code, output kind, actual producer model, retryability and up to five sample asset IDs. At most 1024 detailed groups plus two overflow groups are returned; overflow groups separate retryable and unrecoverable entries and mark overflow=true. Unknown failure codes remain retryable. Historical counts are provisional while counts_complete is false. Example: GET /media/v1/libraries/lib_example/understandings/failure_summary.
|
|
7884
|
+
*/
|
|
7885
|
+
export const mediaUnderstandingFailureSummary = (options) => (options.client ?? client).get({
|
|
7886
|
+
security: [{
|
|
7887
|
+
key: 'media-BearerAuth',
|
|
7888
|
+
scheme: 'bearer',
|
|
7889
|
+
type: 'http'
|
|
7890
|
+
}],
|
|
7891
|
+
url: '/media/v1/libraries/{library_id}/understandings/failure_summary',
|
|
7892
|
+
...options
|
|
7893
|
+
});
|
|
7894
|
+
/**
|
|
7895
|
+
* List understanding results across a library
|
|
7896
|
+
*
|
|
7897
|
+
* Read current understanding entries across one library without fetching every asset separately. Use library_id from creation or listing. folder includes descendants; kinds is a comma-separated list of output kinds. Entries are ordered by asset_id and then understanding id. Continue with next_cursor and the same folder and kinds; limit defaults to 100 and cannot exceed 100. Superseded, deleted and old-version entries are excluded. During historical backfill, this method returns 503 CAPACITY rather than incomplete pages; poll failureSummary until counts_complete is true, then start pagination. Example: GET /media/v1/libraries/lib_example/understandings?folder=travel&kinds=caption,transcript&limit=100.
|
|
7898
|
+
*/
|
|
7899
|
+
export const mediaListUnderstandingsByLibrary = (options) => (options.client ?? client).get({
|
|
7900
|
+
security: [{
|
|
7901
|
+
key: 'media-BearerAuth',
|
|
7902
|
+
scheme: 'bearer',
|
|
7903
|
+
type: 'http'
|
|
7904
|
+
}],
|
|
7905
|
+
url: '/media/v1/libraries/{library_id}/understandings',
|
|
7906
|
+
...options
|
|
7907
|
+
});
|
|
7838
7908
|
/**
|
|
7839
7909
|
* List sandboxes (v2)
|
|
7840
7910
|
*
|