@nodaro/sdk 2.2.0 → 2.5.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.
package/dist/index.d.ts CHANGED
@@ -1,3 +1,4 @@
1
+ import * as _nodaro_shared from '@nodaro/shared';
1
2
  import { CollaboratorRole, GenericNode, GenericEdge, WorkflowExport, WorkflowImportReport, WorkflowVisibility, Scene3DReference, Scene3DPlan, Scene3DEditOperation, Scene3DV2EditOperation, Pro3DRenderSource, Pro3DRenderEngine, Pro3DRenderQuality, Pro3DRenderStyle, Scene3DJobOutputAny, Pro3DRenderJobOutput as Pro3DRenderJobOutput$1, Pro3DRenderCapabilities, Scene3DPlanV2, Pro3DRenderQuote as Pro3DRenderQuote$1, ModelInputAdjustment, ConnectedReference, DescribedReference, Scene3DAssetRef, TtsProvider, EntityStyle, CharacterAspectRatio, CharacterAttachColumn, LocationAssetType, LocationAttachColumn, SurroundDirection, ObjectAssetType, ObjectAttachColumn, ObjectAspectRatio, CreatureAttachColumn, PipelineInput, PipelineStatus, PipelineMode, PipelineStageName, SubGateName, ChatEnabledStage, ProposedChange, ReduceStrategyId, ReduceMeta, Voice, VoiceLibraryParams, VoiceLibraryResponse, VoiceClone, AudioFxPreset, BrowseCommunityParams, BrowseCommunityResult, CommunityCard, CommunityFullDetail, CommunityEntityType, CloneListingResult, FavoriteListingResult, CommunityReportReason, ReportListingResult, PublishListingParams, PublishListingResult, SharedListing, OrganizationView, OrgKind, OrgSettings, OrgPage, OrgMemberView, MemberStatus, WorkspaceRole, InvitationDelivery, InvitationState, InvitationView, InvitationPreview, OrgAuditEntry, UsageQuery, UsageReport, UsageLogEntry, WorkspaceSummary, WorkspaceView, WorkspaceSettings, WorkspaceMemberView, JoinCodeView, MeOrganizations } from '@nodaro/shared';
2
3
  export { AudioFxPreset, BrowseCommunityParams, BrowseCommunityResult, CHARACTER_ASPECT_DEFAULTS, CHARACTER_ASPECT_OPTIONS, CHARACTER_STYLES, OBJECT_ASPECT_DEFAULTS as CREATURE_ASPECT_DEFAULTS, OBJECT_ASPECT_OPTIONS as CREATURE_ASPECT_OPTIONS, CREATURE_ATTACH_COLUMNS, CharacterAspectRatio, CloneListingResult, CommunityCard, CommunityEntityType, CommunityReportReason, CommunitySort, ConnectedReference, ObjectAspectRatio as CreatureAspectRatio, CreatureAttachColumn, DescribedReference, EntityStyle, FavoriteListingResult, GenericEdge, GenericNode, InvitationDelivery, InvitationPreview, InvitationState, InvitationView, JoinCodeView, LOCATION_ASSET_TYPES, LOCATION_ATTACH_COLUMNS, LocationAssetType, LocationAttachColumn, MeOrganizations, MemberStatus, OBJECT_ASPECT_DEFAULTS, OBJECT_ASPECT_OPTIONS, OBJECT_ASSET_TYPES, OBJECT_ATTACH_COLUMNS, ObjectAspectRatio, ObjectAssetType, ObjectAttachColumn, OrgAuditEntry, OrgErrorCode, OrgKind, OrgMemberView, OrgPage, OrgRole, OrgSettings, OrgStatus, OrganizationSummary, OrganizationView, PROMPT_PREFIX_KEY, PROMPT_SUFFIX_KEY, PipelineStageName, PromptAffixFields, PublishListingParams, PublishListingResult, ReduceMeta, ReduceStrategyId, ReportListingResult, SURROUND_DIRECTIONS, SharedListing, SharedVoice, SurroundDirection, USAGE_GROUP_BYS, UsageGroupBy, UsageLogEntry, UsageQuery, UsageReport, UsageReportRow, UsageReportTotals, UsageVarianceRow, Voice, VoiceClone, VoiceLibraryParams, VoiceLibraryResponse, WORKSPACE_HEADER, WorkflowExport, WorkflowExportCharacter, WorkflowExportLocation, WorkflowExportObject, WorkspaceMemberView, WorkspaceRole, WorkspaceSettings, WorkspaceSummary, WorkspaceView } from '@nodaro/shared';
3
4
  import { DirectionFields, SubjectFields, PersonValue, WizardNodeContext, WizardQuestion, WizardSelection, RecommendedModel, FactoryPreset } from '@nodaro/prompts';
@@ -710,6 +711,8 @@ interface Scene3DEngineParams {
710
711
  }
711
712
  /** Structured authoring inputs; reference roles are interpreted by the platform. */
712
713
  interface GenerateScene3DParams extends Record<string, unknown>, Scene3DEngineParams {
714
+ /** Existing GLBs selected by immutable revision/artifact IDs. Requires an import-capable advanced engine. */
715
+ inputAssets?: readonly _nodaro_shared.Scene3DInputAsset[];
713
716
  prompt: string;
714
717
  durationSeconds?: number;
715
718
  fps?: number;
@@ -4676,6 +4679,65 @@ declare class MediaResource {
4676
4679
  }): Promise<{
4677
4680
  jobId: string;
4678
4681
  }>;
4682
+ /**
4683
+ * Place 1–12 layers — pictures, real text, QR codes, shapes — on a base image,
4684
+ * pixel-exactly (`POST /v1/image-overlay`) — local, deterministic, no AI.
4685
+ * Every layer position/size is a PERCENT of the base image: `anchor` (nine
4686
+ * positions, default `"center"`), `x`/`y` (offset from the anchor in % of
4687
+ * the base width/height; negative on a right/bottom anchor moves inward),
4688
+ * `width` (% of the base width, default 25 — height follows the layer's
4689
+ * aspect unless `height` is set). Plus `opacity` (0..1), `rotation`
4690
+ * (degrees), `blend` (`"over"` | `"multiply"` | `"screen"`), `fit`,
4691
+ * `shadow` and `roundedCorners`. The output keeps the base's pixel size
4692
+ * unless `canvas` is set. Flat credit cost. Poll `jobs.get(jobId)` for the
4693
+ * finished image.
4694
+ */
4695
+ imageOverlay(input: {
4696
+ imageUrl: string;
4697
+ layers: Array<{
4698
+ imageUrl: string;
4699
+ anchor?: "top-left" | "top" | "top-right" | "left" | "center" | "right" | "bottom-left" | "bottom" | "bottom-right";
4700
+ x?: number;
4701
+ y?: number;
4702
+ width?: number;
4703
+ height?: number;
4704
+ opacity?: number;
4705
+ rotation?: number;
4706
+ blend?: "over" | "multiply" | "screen";
4707
+ fit?: "contain" | "cover" | "stretch";
4708
+ shadow?: {
4709
+ blur: number;
4710
+ offsetX: number;
4711
+ offsetY: number;
4712
+ color: string;
4713
+ opacity: number;
4714
+ };
4715
+ roundedCorners?: number;
4716
+ zIndex?: number;
4717
+ /** "image" (default, needs imageUrl) | "text" | "qr" | "shape" — see @nodaro/shared image-overlay-layers. */
4718
+ kind?: "image" | "text" | "qr" | "shape";
4719
+ text?: Record<string, unknown>;
4720
+ qr?: Record<string, unknown>;
4721
+ shape?: Record<string, unknown>;
4722
+ effects?: Record<string, unknown>;
4723
+ }>;
4724
+ canvas?: {
4725
+ width: number;
4726
+ height: number;
4727
+ backgroundColor?: string;
4728
+ };
4729
+ baseFit?: "contain" | "cover";
4730
+ outputFormat?: "png" | "jpg" | "webp";
4731
+ /** Extra platform renders (see OVERLAY_PLATFORMS in @nodaro/shared); returned as output `variants[]`. */
4732
+ variants?: string[];
4733
+ /** The mask the job also emits as output `maskUrl` (white = may change). Default "around". */
4734
+ maskMode?: "none" | "layers" | "around" | "outside";
4735
+ maskSpread?: number;
4736
+ /** Fills every QR layer whose `qr.fromInput` is true — the node's QR link handle. */
4737
+ qrText?: string;
4738
+ }): Promise<{
4739
+ jobId: string;
4740
+ }>;
4679
4741
  /**
4680
4742
  * Trim a video to a range (`POST /v1/trim-video`). Give the range in whichever
4681
4743
  * unit fits: `startTime`/`endTime` seconds, `trim*Frames`, `trim*Seconds`, or
@@ -6152,10 +6214,275 @@ declare class StudioProductionsResource {
6152
6214
  */
6153
6215
  clone(productionId: string, input?: StudioCloneRequest): Promise<StudioProduction>;
6154
6216
  }
6155
- /** `client.studio` — the studio's own surface on the platform. */
6217
+
6218
+ /** Public response/transport contracts only; document validation and planning
6219
+ * remain in the private Studio codec on the server. */
6220
+ type StudioDocumentJson = Record<string, unknown>;
6221
+ interface StudioProductionCapabilities {
6222
+ planVersions: number[];
6223
+ operations: {
6224
+ readKeyframes: boolean;
6225
+ saveEditorState?: boolean;
6226
+ editableSharedCopies?: boolean;
6227
+ revisionedSharing?: boolean;
6228
+ cloneLinkedProductions?: boolean;
6229
+ importPlannedBundles?: boolean;
6230
+ importLinkedBundles?: boolean;
6231
+ appendPlannedBundles?: boolean;
6232
+ appendLinkedBundles?: boolean;
6233
+ editKeyframes: boolean;
6234
+ generateKeyframes: boolean;
6235
+ acceptKeyframes: boolean;
6236
+ rejectKeyframes?: boolean;
6237
+ editSequencePlans?: boolean;
6238
+ generateLinkedClips: boolean;
6239
+ retakeLinkedClips?: boolean;
6240
+ };
6241
+ sourceFrameReferences: boolean;
6242
+ automaticAcceptance: false;
6243
+ unattendedGeneration: false;
6244
+ }
6245
+ interface StudioKeyframeRecord {
6246
+ id: string;
6247
+ label: string;
6248
+ revision: number;
6249
+ nodeId: string;
6250
+ parentKeyframeId?: string;
6251
+ previewResultKey: string | null;
6252
+ previewUrl: string | null;
6253
+ acceptedResultKey: string | null;
6254
+ acceptedUrl: string | null;
6255
+ count: number;
6256
+ pending: Array<{
6257
+ jobId: string;
6258
+ startedAt: string;
6259
+ }>;
6260
+ /** Owner-only working state. Recorded acceptance is not an execution grant. */
6261
+ plan?: StudioDocumentJson;
6262
+ acceptance?: StudioDocumentJson;
6263
+ results?: StudioDocumentJson[];
6264
+ }
6265
+ interface StudioProductionRecord {
6266
+ id: string;
6267
+ name: string;
6268
+ version: number;
6269
+ updatedAt: string;
6270
+ thumbnailUrl: string | null;
6271
+ shared: boolean;
6272
+ archived: boolean;
6273
+ requiredCapabilities?: string[];
6274
+ keyframes?: StudioKeyframeRecord[];
6275
+ sequences?: StudioDocumentJson[];
6276
+ shots: StudioDocumentJson[];
6277
+ pending: {
6278
+ stills: number;
6279
+ clips: number;
6280
+ keyframes?: number;
6281
+ music: boolean;
6282
+ draft: StudioDocumentJson | null;
6283
+ };
6284
+ [field: string]: unknown;
6285
+ }
6286
+ interface StudioProductionReply {
6287
+ production: StudioProductionRecord;
6288
+ capabilities?: StudioProductionCapabilities;
6289
+ warnings?: unknown[];
6290
+ [field: string]: unknown;
6291
+ }
6292
+ interface StudioEditInput {
6293
+ ops: ReadonlyArray<{
6294
+ op: string;
6295
+ [field: string]: unknown;
6296
+ }>;
6297
+ baseVersion?: number;
6298
+ strict?: boolean;
6299
+ clientRequestId?: string;
6300
+ }
6301
+ interface StudioKeyframeGenerationInput {
6302
+ keyframeId: string;
6303
+ expectedRevision: number;
6304
+ clientRequestId?: string;
6305
+ overrides?: StudioDocumentJson;
6306
+ }
6307
+ interface StudioKeyframeAcceptanceInput {
6308
+ keyframeId: string;
6309
+ expectedRevision: number;
6310
+ resultKey: string;
6311
+ expectedAcceptedResultKey: string | null;
6312
+ requirementChecks: Array<{
6313
+ requirementId: string;
6314
+ outcome: "pass" | "waived";
6315
+ }>;
6316
+ waivedReason?: string;
6317
+ }
6318
+ interface StudioShotGenerationInput {
6319
+ kind: "still" | "clip";
6320
+ shotId: string;
6321
+ clientRequestId?: string;
6322
+ count?: number;
6323
+ mode?: "start" | "references";
6324
+ dryRun?: boolean;
6325
+ /** Linked clips only: require the exact inputs returned by a reviewed quote. */
6326
+ expectedInputHash?: string;
6327
+ /** Retake a native linked take using its original request and retained endpoints. */
6328
+ retakeResultKey?: string;
6329
+ overrides?: StudioDocumentJson;
6330
+ }
6331
+ type StudioGenerationReply = {
6332
+ jobIds: string[];
6333
+ production?: StudioProductionRecord;
6334
+ deduped?: true;
6335
+ lane?: string;
6336
+ [field: string]: unknown;
6337
+ } | {
6338
+ dryRun: true;
6339
+ provider: string;
6340
+ count: number;
6341
+ credits: number | null;
6342
+ lane?: string;
6343
+ /** Linked-clip quotes include normalized settings and accepted endpoint pins. */
6344
+ inputHash?: string;
6345
+ endpointPins?: StudioDocumentJson;
6346
+ creditIdentifier?: string;
6347
+ duration?: number;
6348
+ resolution?: string;
6349
+ aspectRatio?: string;
6350
+ sound?: boolean;
6351
+ };
6352
+ /** Cloud plugin routes. Check capabilities before exposing dependency controls.
6353
+ * Reads do not reconcile jobs, submit media or accept generated candidates. */
6156
6354
  declare class StudioResource {
6355
+ private readonly client;
6157
6356
  readonly productions: StudioProductionsResource;
6158
6357
  constructor(client: NodaroClient);
6358
+ capabilities(): Promise<{
6359
+ data: StudioProductionCapabilities;
6360
+ }>;
6361
+ skill(): Promise<{
6362
+ data: StudioDocumentJson;
6363
+ }>;
6364
+ list(options?: {
6365
+ limit?: number;
6366
+ cursor?: string;
6367
+ includeArchived?: boolean;
6368
+ }): Promise<{
6369
+ data: {
6370
+ data: Array<{
6371
+ id: string;
6372
+ name: string;
6373
+ version: number;
6374
+ updatedAt: string;
6375
+ thumbnailUrl: string | null;
6376
+ shared: boolean;
6377
+ archived: boolean;
6378
+ shotCount: number;
6379
+ }>;
6380
+ nextCursor?: string;
6381
+ };
6382
+ }>;
6383
+ get(id: string, options?: {
6384
+ detail?: "summary" | "full";
6385
+ shotId?: string;
6386
+ }): Promise<{
6387
+ data: StudioProductionReply;
6388
+ }>;
6389
+ validatePlan(plan: StudioDocumentJson): Promise<{
6390
+ data: {
6391
+ valid: boolean;
6392
+ errors: StudioDocumentJson[];
6393
+ warnings: StudioDocumentJson[];
6394
+ summary?: StudioDocumentJson;
6395
+ };
6396
+ }>;
6397
+ create(input: {
6398
+ name?: string;
6399
+ plan?: StudioDocumentJson;
6400
+ }): Promise<{
6401
+ data: StudioProductionReply;
6402
+ }>;
6403
+ /** Import a portable document through the compatible server writer.
6404
+ * Retained frame media requires an authorized source; acceptance never transfers. */
6405
+ importBundle(input: {
6406
+ bundle: StudioDocumentJson;
6407
+ projectId?: string;
6408
+ }): Promise<{
6409
+ data: StudioProductionReply;
6410
+ }>;
6411
+ /** Append a bundle's scenes and frame closure under an exact destination revision. */
6412
+ appendBundle(id: string, input: {
6413
+ bundle: StudioDocumentJson;
6414
+ expectedVersion: number;
6415
+ afterShotId?: string;
6416
+ applyFilm?: boolean;
6417
+ }): Promise<{
6418
+ data: {
6419
+ production: StudioProductionRecord;
6420
+ importedShotIds: string[];
6421
+ importedKeyframeIds: string[];
6422
+ };
6423
+ }>;
6424
+ /** Copy a saved production. Linked copies retain verified inputs, remap
6425
+ * dependencies and require fresh frame acceptance; they start no media jobs. */
6426
+ clone(id: string, input?: {
6427
+ name?: string;
6428
+ projectId?: string;
6429
+ expectedVersion?: number;
6430
+ }): Promise<{
6431
+ data: StudioProductionReply;
6432
+ }>;
6433
+ edit(id: string, input: StudioEditInput): Promise<{
6434
+ data: StudioProductionReply & {
6435
+ version: number;
6436
+ rebased: boolean;
6437
+ receipts: StudioDocumentJson[];
6438
+ };
6439
+ }>;
6440
+ /** Audience-authorized sharing; an expected revision prevents publication
6441
+ * of concurrent edits the caller has not reviewed. */
6442
+ setShared(id: string, input: {
6443
+ shared: boolean;
6444
+ allowEditableCopy?: boolean;
6445
+ expectedVersion?: number;
6446
+ }): Promise<{
6447
+ data: StudioProductionReply;
6448
+ }>;
6449
+ /** Save ordinary editor fields against the loaded revision. Protected frame
6450
+ * and job state can only change through their dedicated semantic actions. */
6451
+ saveEditorState(id: string, input: {
6452
+ expectedVersion: number;
6453
+ graph: object;
6454
+ clientRequestId?: string;
6455
+ }): Promise<{
6456
+ data: StudioProductionReply & {
6457
+ version: number;
6458
+ rebased: boolean;
6459
+ receipts: StudioDocumentJson[];
6460
+ };
6461
+ }>;
6462
+ generateKeyframe(id: string, input: StudioKeyframeGenerationInput): Promise<{
6463
+ data: Exclude<StudioGenerationReply, {
6464
+ dryRun: true;
6465
+ }>;
6466
+ }>;
6467
+ generateShot(id: string, input: StudioShotGenerationInput): Promise<{
6468
+ data: StudioGenerationReply;
6469
+ }>;
6470
+ /** A separate explicit review action; generation never calls this method. */
6471
+ acceptKeyframe(id: string, input: StudioKeyframeAcceptanceInput, concurrency?: Pick<StudioEditInput, "baseVersion" | "strict" | "clientRequestId">): Promise<{
6472
+ data: StudioProductionReply & {
6473
+ version: number;
6474
+ rebased: boolean;
6475
+ receipts: StudioDocumentJson[];
6476
+ };
6477
+ }>;
6478
+ reconcile(id: string): Promise<{
6479
+ data: StudioProductionReply & {
6480
+ landed: string[];
6481
+ pending: string[];
6482
+ failed: string[];
6483
+ version: number;
6484
+ };
6485
+ }>;
6159
6486
  }
6160
6487
 
6161
6488
  /**
@@ -6981,4 +7308,4 @@ interface ApiErrorBody {
6981
7308
  }
6982
7309
  declare function throwFromResponse(status: number, body: ApiErrorBody): never;
6983
7310
 
6984
- export { type AccessTokenResponse, type AnalyzeInput, type AnalyzeResult, type AppRun, type AppRunResult, type ApplyChatProposalResult, type ApproveCreatureMainImageResult, type ApproveMainImageResult, type ApproveObjectMainImageResult, type ApprovePortraitResult, AppsResource, AudioResource, type Auth, type BranchPipelineInput, type BranchPipelineResult, type BrowseTemplatesParams, type BrowseTemplatesResult, CREATURE_ASSET_TYPES, CallbackAuth, type CancelExecutionParams, type CancelJobResult, CatalogsResource, type Character, type CharacterDetail, type CharacterUsage, CharactersResource, type ChatStageResult, type ChatTurn, type ClientOptions, type CloneTemplateParams, type CloneTemplateResult, CommunityResource, type ContinueVideoProResult, type CreateCreatureInput, type CreateDeveloperAppInput, type CreateDeveloperAppResult, type CreateLocationInput, type CreateObjectInput, type CreateOrgInput, type CreateProjectInput, type CreateRecastInput, type CreateShotInput, type CreateWorkflowInput, type CreateWorkspaceInput, type Creature, type CreatureAssetType, type CreatureDetail, type CreatureReferencePhoto, type CreatureReferencePhotoKind, CreaturesResource, type CreditStatus, CreditsResource, type DeleteAppRunResult, type DeleteJobResult, type DeveloperApp, type DeveloperAppScope, type DeveloperAppStatus, DeveloperAppsResource, type DownloadVideoProgress, type DubbingInput, type DuplicateCharacterInput, type EditScene3DParams, type EnhanceInput, type EstimateRecastInput, type EstimateRecastRescoreInput, type ExchangeCodeInput, type ExecutionStatus, type ExecutionTriggerType, ExecutionsResource, type FactoryPresetsResult, ForbiddenError, type GenerateAssetInput, type GenerateCharacterInput, type GenerateCharacterResult, type GenerateCreatureAssetInput, type GenerateCreatureAssetResult, type GenerateCreatureInput, type GenerateCreatureMotionInput, type GenerateCreatureMotionResult, type GenerateCreatureResult, type GenerateImageParams, type GenerateInput, type GenerateLocationAssetInput, type GenerateLocationInput, type GenerateLocationResult, type GenerateMotionInput, type GenerateObjectAssetInput, type GenerateObjectAssetResult, type GenerateObjectInput, type GenerateObjectMotionInput, type GenerateObjectMotionResult, type GenerateObjectResult, type GenerateScene3DParams, type GenerateSurroundContinuationInput, type GenerateVideoParams, type GetPickerCatalogOptions, type GetProductionOptions, InsufficientCreditsError, type InviteInput, type Job, JobAbortedError, JobBlockedError, type JobErrorHint, JobFailedError, JobHeldError, type JobStatus, type JobStatusResult, JobTimeoutError, JobsResource, type LibraryAsset, LibraryResource, type ListAppRunsParams, type ListAppsParams, type ListAppsResult, type ListCharactersParams, type ListCharactersResult, type ListCreaturesParams, type ListExecutionsForWorkflowParams, type ListExecutionsPage, type ListInvitationsOptions, type ListJobsPage, type ListJobsParams, type ListLibraryParams, type ListLibraryResult, type ListLocationsParams, type ListModelsOptions, type ListObjectsParams, type ListStudioProductionsOptions, type ListWorkflowsParams, LlmResource, type LlmStructuredInput, type LlmStructuredJobInput, type LlmStructuredJobOutput, type LlmStructuredResult, type Location, type LocationDetail, type LocationReferencePhoto, type LocationReferencePhotoKind, LocationsResource, type MediaProcessInput, type MediaProcessResult, MediaResource, type ModelCostsResult, type ModelSummary, type ModelsListResult, ModelsResource, NodaroClient, NodaroError, type NodeCategory, type NodeDescriptor, type NodeExecutionState, type NodeInputField, type NodeInputSchema, type NodeJobOutput, type NodePreset, type NodePresetGroup, NodesResource, NotFoundError, type OAuthAppInfo, OAuthResource, type Object$1 as Object, type ObjectCategory, type ObjectDetail, type ObjectReferencePhoto, type ObjectReferencePhotoKind, ObjectsResource, OrganizationsResource, type OutputType, type PickerCatalog, type PickerCatalogSummary, PickerCatalogsResource, type PickerDimension, type PickerOption, PipelinesResource, type PolicyBlockHint, PresetsResource, type Project, type ProjectedCatalog, type ProjectedCatalogDimension, type ProjectedCatalogOption, ProjectsResource, PromptHelperResource, type PromptResult, type PublishedApp, type PublishedAppDetail, RateLimitedError, type RecaptionCreatureResult, type RecaptionLocationResult, type RecaptionObjectResult, type RecaptionResult, type RecastAudioLayerName, type RecastAudioManifestV1, type RecastAudioMix, type RecastAudioMixControl, type RecastAudioSectionReplacement, type RecastEstimate, type RecastRescoreOperation, type RecastRescoreQuote, type RecastRescoreReplacement, type RecastRescoreRequestV2, type RecastRescoreResponse, RecastResource, type RecastRunSnapshot, type RecastScriptImportResult, type RecastScriptValidation, type RecastScriptValidationError, type ReduceInput, ReduceResource, type ReduceResult, type ReferencePhoto, type ReferencePhotoKind, type RenderScene3DParams, type ResolveRecastGateInput, type RetainedScene3DEditParams, type RetainedScene3DEditResult, type RotateSecretResult, type RunAndWaitOptions, type RunAppOptions, type RunManyResult, type RunNodeAdjustment, type RunNodeResult, type RunWorkflowParams, type RunWorkflowResult, type SafetyBlockHint, type Scene3DAuthoringEngine, type Scene3DCapabilities, type Scene3DDelivery, type Scene3DDeliveryAsset, type Scene3DJobOutput, Scene3DResource, type Shot, type ShotEntityRef, type ShotMode, ShotsResource, StaticTokenAuth, type StopVideoProResult, StorageExceededError, type StructuredReferenceParams, type StudioClientRequestId, type StudioCloneRequest, type StudioCreateProductionRequest, type StudioDescribeRequest, type StudioExportPlanOptions, type StudioExportPlanResponse, type StudioExportStep, type StudioFrameRequest, type StudioGenerateEstimate, type StudioGenerateOptions, type StudioGenerateRequest, type StudioGenerateResponse, type StudioGenerateResult, type StudioImportSummary, type StudioJobStartedResponse, type StudioListProductionsResponse, type StudioMediaResponse, type StudioMusicRequest, StudioOpError, type StudioOpsReceipt, type StudioOpsRequest, type StudioOpsResponse, type StudioPlanIssue, type StudioProduction, type StudioProductionDetail, type StudioProductionResponse, StudioProductionsResource, type StudioReconcileResponse, StudioResource, type StudioRevoiceRequest, type StudioSkillResponse, type StudioValidatePlanResponse, type StudioVideoLane, type StudioVoiceRequest, type Template, type TemplateBrowseCard, type TemplateSort, TemplatesResource, type TextToVideoParams, type TutorialCategory, type TutorialFlowItem, type TutorialVideoItem, TutorialsResource, UnauthorizedError, type UpdateCreatureInput, type UpdateCreatureResult, type UpdateDeveloperAppInput, type UpdateLocationInput, type UpdateLocationResult, type UpdateObjectInput, type UpdateObjectResult, type UpdateProjectInput, type UpdateShotInput, type UpdateWorkflowInput, type UploadResult, UploadsResource, type UpsertCharacterInput, type UpsertCharacterResult, type UpsertCreatureInput, type UpsertCreatureResult, type UpsertObjectInput, type UpsertObjectResult, type UserBalance, type UserIdentity, type VcpAnalysis, type VcpAnalysisSpeaker, type VcpAnalyzeInput, type VcpExportInput, type VcpExportTrack, type VideoMetadata, VideoProResource, type VoiceChangerProInput, type VoiceChangerProVoice, type VoiceDesignInput, type VoiceRemixInput, VoicesResource, type Workflow, type WorkflowConflictCode, WorkflowConflictError, type WorkflowExecution, type WorkflowExecutionSummary, WorkflowsResource, WorkspacesResource, buildPersonSeedPrompt, createClient, isStudioGenerateEstimate, supabaseAuth, throwFromResponse };
7311
+ export { type AccessTokenResponse, type AnalyzeInput, type AnalyzeResult, type AppRun, type AppRunResult, type ApplyChatProposalResult, type ApproveCreatureMainImageResult, type ApproveMainImageResult, type ApproveObjectMainImageResult, type ApprovePortraitResult, AppsResource, AudioResource, type Auth, type BranchPipelineInput, type BranchPipelineResult, type BrowseTemplatesParams, type BrowseTemplatesResult, CREATURE_ASSET_TYPES, CallbackAuth, type CancelExecutionParams, type CancelJobResult, CatalogsResource, type Character, type CharacterDetail, type CharacterUsage, CharactersResource, type ChatStageResult, type ChatTurn, type ClientOptions, type CloneTemplateParams, type CloneTemplateResult, CommunityResource, type ContinueVideoProResult, type CreateCreatureInput, type CreateDeveloperAppInput, type CreateDeveloperAppResult, type CreateLocationInput, type CreateObjectInput, type CreateOrgInput, type CreateProjectInput, type CreateRecastInput, type CreateShotInput, type CreateWorkflowInput, type CreateWorkspaceInput, type Creature, type CreatureAssetType, type CreatureDetail, type CreatureReferencePhoto, type CreatureReferencePhotoKind, CreaturesResource, type CreditStatus, CreditsResource, type DeleteAppRunResult, type DeleteJobResult, type DeveloperApp, type DeveloperAppScope, type DeveloperAppStatus, DeveloperAppsResource, type DownloadVideoProgress, type DubbingInput, type DuplicateCharacterInput, type EditScene3DParams, type EnhanceInput, type EstimateRecastInput, type EstimateRecastRescoreInput, type ExchangeCodeInput, type ExecutionStatus, type ExecutionTriggerType, ExecutionsResource, type FactoryPresetsResult, ForbiddenError, type GenerateAssetInput, type GenerateCharacterInput, type GenerateCharacterResult, type GenerateCreatureAssetInput, type GenerateCreatureAssetResult, type GenerateCreatureInput, type GenerateCreatureMotionInput, type GenerateCreatureMotionResult, type GenerateCreatureResult, type GenerateImageParams, type GenerateInput, type GenerateLocationAssetInput, type GenerateLocationInput, type GenerateLocationResult, type GenerateMotionInput, type GenerateObjectAssetInput, type GenerateObjectAssetResult, type GenerateObjectInput, type GenerateObjectMotionInput, type GenerateObjectMotionResult, type GenerateObjectResult, type GenerateScene3DParams, type GenerateSurroundContinuationInput, type GenerateVideoParams, type GetPickerCatalogOptions, type GetProductionOptions, InsufficientCreditsError, type InviteInput, type Job, JobAbortedError, JobBlockedError, type JobErrorHint, JobFailedError, JobHeldError, type JobStatus, type JobStatusResult, JobTimeoutError, JobsResource, type LibraryAsset, LibraryResource, type ListAppRunsParams, type ListAppsParams, type ListAppsResult, type ListCharactersParams, type ListCharactersResult, type ListCreaturesParams, type ListExecutionsForWorkflowParams, type ListExecutionsPage, type ListInvitationsOptions, type ListJobsPage, type ListJobsParams, type ListLibraryParams, type ListLibraryResult, type ListLocationsParams, type ListModelsOptions, type ListObjectsParams, type ListStudioProductionsOptions, type ListWorkflowsParams, LlmResource, type LlmStructuredInput, type LlmStructuredJobInput, type LlmStructuredJobOutput, type LlmStructuredResult, type Location, type LocationDetail, type LocationReferencePhoto, type LocationReferencePhotoKind, LocationsResource, type MediaProcessInput, type MediaProcessResult, MediaResource, type ModelCostsResult, type ModelSummary, type ModelsListResult, ModelsResource, NodaroClient, NodaroError, type NodeCategory, type NodeDescriptor, type NodeExecutionState, type NodeInputField, type NodeInputSchema, type NodeJobOutput, type NodePreset, type NodePresetGroup, NodesResource, NotFoundError, type OAuthAppInfo, OAuthResource, type Object$1 as Object, type ObjectCategory, type ObjectDetail, type ObjectReferencePhoto, type ObjectReferencePhotoKind, ObjectsResource, OrganizationsResource, type OutputType, type PickerCatalog, type PickerCatalogSummary, PickerCatalogsResource, type PickerDimension, type PickerOption, PipelinesResource, type PolicyBlockHint, PresetsResource, type Project, type ProjectedCatalog, type ProjectedCatalogDimension, type ProjectedCatalogOption, ProjectsResource, PromptHelperResource, type PromptResult, type PublishedApp, type PublishedAppDetail, RateLimitedError, type RecaptionCreatureResult, type RecaptionLocationResult, type RecaptionObjectResult, type RecaptionResult, type RecastAudioLayerName, type RecastAudioManifestV1, type RecastAudioMix, type RecastAudioMixControl, type RecastAudioSectionReplacement, type RecastEstimate, type RecastRescoreOperation, type RecastRescoreQuote, type RecastRescoreReplacement, type RecastRescoreRequestV2, type RecastRescoreResponse, RecastResource, type RecastRunSnapshot, type RecastScriptImportResult, type RecastScriptValidation, type RecastScriptValidationError, type ReduceInput, ReduceResource, type ReduceResult, type ReferencePhoto, type ReferencePhotoKind, type RenderScene3DParams, type ResolveRecastGateInput, type RetainedScene3DEditParams, type RetainedScene3DEditResult, type RotateSecretResult, type RunAndWaitOptions, type RunAppOptions, type RunManyResult, type RunNodeAdjustment, type RunNodeResult, type RunWorkflowParams, type RunWorkflowResult, type SafetyBlockHint, type Scene3DAuthoringEngine, type Scene3DCapabilities, type Scene3DDelivery, type Scene3DDeliveryAsset, type Scene3DJobOutput, Scene3DResource, type Shot, type ShotEntityRef, type ShotMode, ShotsResource, StaticTokenAuth, type StopVideoProResult, StorageExceededError, type StructuredReferenceParams, type StudioClientRequestId, type StudioCloneRequest, type StudioCreateProductionRequest, type StudioDescribeRequest, type StudioDocumentJson, type StudioEditInput, type StudioExportPlanOptions, type StudioExportPlanResponse, type StudioExportStep, type StudioFrameRequest, type StudioGenerateEstimate, type StudioGenerateOptions, type StudioGenerateRequest, type StudioGenerateResponse, type StudioGenerateResult, type StudioGenerationReply, type StudioImportSummary, type StudioJobStartedResponse, type StudioKeyframeAcceptanceInput, type StudioKeyframeGenerationInput, type StudioKeyframeRecord, type StudioListProductionsResponse, type StudioMediaResponse, type StudioMusicRequest, StudioOpError, type StudioOpsReceipt, type StudioOpsRequest, type StudioOpsResponse, type StudioPlanIssue, type StudioProduction, type StudioProductionCapabilities, type StudioProductionDetail, type StudioProductionRecord, type StudioProductionReply, type StudioProductionResponse, StudioProductionsResource, type StudioReconcileResponse, StudioResource, type StudioRevoiceRequest, type StudioShotGenerationInput, type StudioSkillResponse, type StudioValidatePlanResponse, type StudioVideoLane, type StudioVoiceRequest, type Template, type TemplateBrowseCard, type TemplateSort, TemplatesResource, type TextToVideoParams, type TutorialCategory, type TutorialFlowItem, type TutorialVideoItem, TutorialsResource, UnauthorizedError, type UpdateCreatureInput, type UpdateCreatureResult, type UpdateDeveloperAppInput, type UpdateLocationInput, type UpdateLocationResult, type UpdateObjectInput, type UpdateObjectResult, type UpdateProjectInput, type UpdateShotInput, type UpdateWorkflowInput, type UploadResult, UploadsResource, type UpsertCharacterInput, type UpsertCharacterResult, type UpsertCreatureInput, type UpsertCreatureResult, type UpsertObjectInput, type UpsertObjectResult, type UserBalance, type UserIdentity, type VcpAnalysis, type VcpAnalysisSpeaker, type VcpAnalyzeInput, type VcpExportInput, type VcpExportTrack, type VideoMetadata, VideoProResource, type VoiceChangerProInput, type VoiceChangerProVoice, type VoiceDesignInput, type VoiceRemixInput, VoicesResource, type Workflow, type WorkflowConflictCode, WorkflowConflictError, type WorkflowExecution, type WorkflowExecutionSummary, WorkflowsResource, WorkspacesResource, buildPersonSeedPrompt, createClient, isStudioGenerateEstimate, supabaseAuth, throwFromResponse };
package/dist/index.js CHANGED
@@ -2138,6 +2138,22 @@ var MediaResource = class {
2138
2138
  imageCollage(input) {
2139
2139
  return this.client.request("POST", "/v1/image-collage", { body: input });
2140
2140
  }
2141
+ /**
2142
+ * Place 1–12 layers — pictures, real text, QR codes, shapes — on a base image,
2143
+ * pixel-exactly (`POST /v1/image-overlay`) — local, deterministic, no AI.
2144
+ * Every layer position/size is a PERCENT of the base image: `anchor` (nine
2145
+ * positions, default `"center"`), `x`/`y` (offset from the anchor in % of
2146
+ * the base width/height; negative on a right/bottom anchor moves inward),
2147
+ * `width` (% of the base width, default 25 — height follows the layer's
2148
+ * aspect unless `height` is set). Plus `opacity` (0..1), `rotation`
2149
+ * (degrees), `blend` (`"over"` | `"multiply"` | `"screen"`), `fit`,
2150
+ * `shadow` and `roundedCorners`. The output keeps the base's pixel size
2151
+ * unless `canvas` is set. Flat credit cost. Poll `jobs.get(jobId)` for the
2152
+ * finished image.
2153
+ */
2154
+ imageOverlay(input) {
2155
+ return this.client.request("POST", "/v1/image-overlay", { body: input });
2156
+ }
2141
2157
  /**
2142
2158
  * Trim a video to a range (`POST /v1/trim-video`). Give the range in whichever
2143
2159
  * unit fits: `startTime`/`endTime` seconds, `trim*Frames`, `trim*Seconds`, or
@@ -2543,7 +2559,7 @@ var RecastResource = class {
2543
2559
  }
2544
2560
  };
2545
2561
 
2546
- // src/resources/studio.ts
2562
+ // src/resources/studio-productions.ts
2547
2563
  function isStudioGenerateEstimate(result) {
2548
2564
  return result.dryRun === true;
2549
2565
  }
@@ -2775,11 +2791,80 @@ var StudioProductionsResource = class {
2775
2791
  return res.data.production;
2776
2792
  }
2777
2793
  };
2794
+
2795
+ // src/resources/studio.ts
2796
+ var root = "/v1/studio/productions";
2797
+ var path = (id) => `${root}/${encodeURIComponent(id)}`;
2778
2798
  var StudioResource = class {
2779
- productions;
2780
2799
  constructor(client) {
2800
+ this.client = client;
2781
2801
  this.productions = new StudioProductionsResource(client);
2782
2802
  }
2803
+ client;
2804
+ productions;
2805
+ capabilities() {
2806
+ return this.client.request("GET", `${root}/capabilities`);
2807
+ }
2808
+ skill() {
2809
+ return this.client.request("GET", `${root}/skill`);
2810
+ }
2811
+ list(options = {}) {
2812
+ return this.client.request("GET", root, { query: options });
2813
+ }
2814
+ get(id, options = {}) {
2815
+ return this.client.request("GET", path(id), { query: { detail: options.detail, shot_id: options.shotId } });
2816
+ }
2817
+ validatePlan(plan) {
2818
+ return this.client.request("POST", `${root}/validate`, { body: { plan } });
2819
+ }
2820
+ create(input) {
2821
+ return this.client.request("POST", root, { body: input });
2822
+ }
2823
+ /** Import a portable document through the compatible server writer.
2824
+ * Retained frame media requires an authorized source; acceptance never transfers. */
2825
+ importBundle(input) {
2826
+ return this.client.request("POST", `${root}/import-bundle`, { body: input });
2827
+ }
2828
+ /** Append a bundle's scenes and frame closure under an exact destination revision. */
2829
+ appendBundle(id, input) {
2830
+ return this.client.request("POST", `${path(id)}/import-bundle`, { body: input });
2831
+ }
2832
+ /** Copy a saved production. Linked copies retain verified inputs, remap
2833
+ * dependencies and require fresh frame acceptance; they start no media jobs. */
2834
+ clone(id, input = {}) {
2835
+ return this.client.request("POST", `${path(id)}/clone`, { body: input });
2836
+ }
2837
+ edit(id, input) {
2838
+ return this.client.request("POST", `${path(id)}/ops`, { body: input });
2839
+ }
2840
+ /** Audience-authorized sharing; an expected revision prevents publication
2841
+ * of concurrent edits the caller has not reviewed. */
2842
+ setShared(id, input) {
2843
+ return this.client.request("POST", `${path(id)}/share`, { body: input });
2844
+ }
2845
+ /** Save ordinary editor fields against the loaded revision. Protected frame
2846
+ * and job state can only change through their dedicated semantic actions. */
2847
+ saveEditorState(id, input) {
2848
+ return this.edit(id, {
2849
+ baseVersion: input.expectedVersion,
2850
+ strict: true,
2851
+ ...input.clientRequestId ? { clientRequestId: input.clientRequestId } : {},
2852
+ ops: [{ op: "save_editor_state", expectedVersion: input.expectedVersion, graph: input.graph }]
2853
+ });
2854
+ }
2855
+ generateKeyframe(id, input) {
2856
+ return this.client.request("POST", `${path(id)}/generate`, { body: { ...input, kind: "keyframe" } });
2857
+ }
2858
+ generateShot(id, input) {
2859
+ return this.client.request("POST", `${path(id)}/generate`, { body: input });
2860
+ }
2861
+ /** A separate explicit review action; generation never calls this method. */
2862
+ acceptKeyframe(id, input, concurrency = {}) {
2863
+ return this.edit(id, { ...concurrency, ops: [{ ...input, op: "accept_keyframe_result" }] });
2864
+ }
2865
+ reconcile(id) {
2866
+ return this.client.request("POST", `${path(id)}/reconcile`, { body: {} });
2867
+ }
2783
2868
  };
2784
2869
 
2785
2870
  // src/resources/community.ts
@@ -3163,7 +3248,7 @@ var WorkspacesResource = class {
3163
3248
  return this.client.requestText("GET", `/v1/workspaces/${encodeURIComponent(id)}/usage`, { query: { ...opts, format: "csv" } });
3164
3249
  }
3165
3250
  };
3166
- var SDK_VERSION = "2.2.0" ;
3251
+ var SDK_VERSION = "2.5.0" ;
3167
3252
  var CLIENT_HEADER = "X-Nodaro-Client";
3168
3253
  var isBrowser = () => typeof window !== "undefined" && typeof window.document !== "undefined";
3169
3254
  var NodaroClient = class _NodaroClient {
@@ -3295,8 +3380,8 @@ var NodaroClient = class _NodaroClient {
3295
3380
  * stalled CSV stream aborts, it does not hang forever). Both the JSON path
3296
3381
  * ({@link request}) and the text path ({@link requestText}) go through here.
3297
3382
  */
3298
- async send(method, path, options, read) {
3299
- const url = this.buildUrl(path, options.query);
3383
+ async send(method, path2, options, read) {
3384
+ const url = this.buildUrl(path2, options.query);
3300
3385
  const token = await this.auth.getToken();
3301
3386
  const isFormData = typeof FormData !== "undefined" && options.body instanceof FormData;
3302
3387
  const headers = {
@@ -3336,14 +3421,14 @@ var NodaroClient = class _NodaroClient {
3336
3421
  }
3337
3422
  }
3338
3423
  /** Authenticated, bounded binary reads through the normal timeout/error transport. */
3339
- async requestBytes(method, path, options) {
3424
+ async requestBytes(method, path2, options) {
3340
3425
  if (!Number.isSafeInteger(options.maxBytes) || options.maxBytes < 1) throw new Error("maxBytes must be a positive integer");
3341
- return this.send(method, path, options, (response) => readBinaryResponse(response, options.maxBytes));
3426
+ return this.send(method, path2, options, (response) => readBinaryResponse(response, options.maxBytes));
3342
3427
  }
3343
- async request(method, path, options = {}) {
3428
+ async request(method, path2, options = {}) {
3344
3429
  return this.send(
3345
3430
  method,
3346
- path,
3431
+ path2,
3347
3432
  options,
3348
3433
  async (res) => (
3349
3434
  // 204 No Content
@@ -3356,8 +3441,8 @@ var NodaroClient = class _NodaroClient {
3356
3441
  * are still the JSON envelope and throw the same typed errors, and the read is
3357
3442
  * bounded by the same timeout as the request.
3358
3443
  */
3359
- async requestText(method, path, options = {}) {
3360
- return this.send(method, path, options, (res) => res.text());
3444
+ async requestText(method, path2, options = {}) {
3445
+ return this.send(method, path2, options, (res) => res.text());
3361
3446
  }
3362
3447
  /**
3363
3448
  * `GET /v1/me` → the authenticated user's identity (see {@link UserIdentity}).
@@ -3376,9 +3461,9 @@ var NodaroClient = class _NodaroClient {
3376
3461
  const res = await this.request("GET", "/v1/me");
3377
3462
  return res.data;
3378
3463
  }
3379
- buildUrl(path, query) {
3464
+ buildUrl(path2, query) {
3380
3465
  const base = this.baseUrl || (typeof window !== "undefined" ? window.location.origin : "http://placeholder");
3381
- const url = new URL(path, base);
3466
+ const url = new URL(path2, base);
3382
3467
  const fullUrl = this.baseUrl ? url.toString() : url.pathname + url.search;
3383
3468
  if (query) {
3384
3469
  const u = new URL(this.baseUrl ? fullUrl : fullUrl, base);