@nodaro/sdk 2.1.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.
package/dist/index.d.cts CHANGED
@@ -1,4 +1,4 @@
1
- import { CollaboratorRole, GenericNode, GenericEdge, WorkflowExport, WorkflowImportReport, WorkflowVisibility, Scene3DReference, Scene3DPlan, Scene3DEditOperation, Scene3DV2EditOperation, Scene3DJobOutputAny, Scene3DPlanV2, 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';
1
+ 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
2
  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
3
  import { DirectionFields, SubjectFields, PersonValue, WizardNodeContext, WizardQuestion, WizardSelection, RecommendedModel, FactoryPreset } from '@nodaro/prompts';
4
4
  export { PEOPLE, PERSON_DIMENSION_LABELS, PERSON_DIMENSION_ORDER, PersonValue, RecommendedModel, WizardNodeContext, WizardOption, WizardQuestion, WizardSelection, buildPersonHints } from '@nodaro/prompts';
@@ -659,6 +659,27 @@ interface RetainedScene3DEditResult {
659
659
  scenePlan: Scene3DPlanV2;
660
660
  changeSummary: string;
661
661
  }
662
+ interface Scene3DDeliveryAsset {
663
+ assetId: string;
664
+ kind: "poster" | "validation-report";
665
+ usage: "poster" | "validation";
666
+ byteLength: number;
667
+ sha256: string;
668
+ viaRevisionId: string | null;
669
+ }
670
+ /** Export evidence is retained separately from the immutable scene it rendered. */
671
+ interface Scene3DDelivery {
672
+ deliveryId: string;
673
+ sceneRevisionId: string;
674
+ sourcePlanSha256: string;
675
+ sourceContentHash: string | null;
676
+ sourceJobId: string | null;
677
+ workflowId: string | null;
678
+ mode: "authored" | "render-only";
679
+ createdAt: string;
680
+ access: "view" | "edit" | "own";
681
+ assets: Scene3DDeliveryAsset[];
682
+ }
662
683
  type Scene3DAuthoringEngine = "basic" | "blender-cloud" | "blender-local";
663
684
  interface Scene3DCapabilities {
664
685
  basic: {
@@ -671,6 +692,13 @@ interface Scene3DCapabilities {
671
692
  sceneSchemaVersions: number[];
672
693
  maxRepairPasses: number;
673
694
  };
695
+ /**
696
+ * What this deployment can serve for `pro-3d-render`, including which
697
+ * quality profiles, engines and aspect ratios a client may OFFER. Optional so
698
+ * a client of this version reads an older backend without throwing; absent
699
+ * means the node is unavailable.
700
+ */
701
+ pro?: Pro3DRenderCapabilities;
674
702
  }
675
703
  interface Scene3DEngineParams {
676
704
  /** Basic is the default. Discover optional engines through scene3d.capabilities(). */
@@ -709,6 +737,62 @@ interface EditScene3DParams extends Record<string, unknown>, Scene3DEngineParams
709
737
  workflowId?: string;
710
738
  nodeId?: string;
711
739
  }
740
+ /**
741
+ * 3D Render Pro — ONE durable operation producing a composition and its MP4.
742
+ *
743
+ * `source` is a strict discriminated union, not a bag of optionals:
744
+ * - `{kind:'prompt', prompt, references?}` authors a new scene;
745
+ * - `{kind:'scene', revisionId, sourceJobId}` with NO `editPrompt` is the
746
+ * render-only export — it spends no authoring or build credits, and OMIT
747
+ * the field rather than sending `""`, which would buy an authoring pass;
748
+ * - `{kind:'local-export', exportId, connectionId}` uses a paired desktop.
749
+ *
750
+ * There is no model or effort field: the planner is fixed and server-owned.
751
+ *
752
+ * `durationSeconds` / `fps` / `aspectRatio` on a `scene` source are an EXPLICIT
753
+ * re-time request. Omit them to keep the source's own timing; a conflicting
754
+ * override is rejected rather than silently applied.
755
+ */
756
+ interface Pro3DRenderParams extends Record<string, unknown> {
757
+ source: Pro3DRenderSource;
758
+ /** Optional. An unknown or unavailable engine is rejected, never downgraded. */
759
+ engine?: Pro3DRenderEngine;
760
+ /** Names a paired desktop for a local run. */
761
+ localConnectionId?: string;
762
+ durationSeconds?: number;
763
+ fps?: number;
764
+ aspectRatio?: string;
765
+ quality?: Pro3DRenderQuality;
766
+ style?: Pro3DRenderStyle;
767
+ /** Correction budget, 0-2. Each pass is paid work. */
768
+ maxRepairPasses?: number;
769
+ /**
770
+ * Which scene-schema versions THIS client can render. A prompt or
771
+ * local-export source mints v2, so omitting 2 is refused for free; a scene
772
+ * source inherits its revision's version and is left to the server.
773
+ */
774
+ acceptedSceneSchemaVersions?: readonly number[];
775
+ workflowId?: string;
776
+ nodeId?: string;
777
+ /** Keep every artifact of this run out of publicly-readable storage. */
778
+ forcePrivate?: boolean;
779
+ }
780
+ /** A run additionally carries the quote it was priced under. */
781
+ interface Pro3DRenderRunParams extends Pro3DRenderParams {
782
+ quoteId: string;
783
+ }
784
+ /** The quote's answer. `maxCredits` is a ceiling; quoting spends nothing. */
785
+ type Pro3DRenderQuote = Readonly<Pro3DRenderQuote$1> & Readonly<Record<string, unknown>>;
786
+ /** Per-call transport controls for the paid run. */
787
+ interface Pro3DRenderRunOptions {
788
+ /**
789
+ * The `Idempotency-Key` the run is submitted under. Reuse the same value when
790
+ * retrying a call that timed out, so the run is not started twice; the SDK
791
+ * generates a fresh one per call when this is omitted, because two deliberate
792
+ * calls are two runs.
793
+ */
794
+ idempotencyKey?: string;
795
+ }
712
796
  /** Render the exact scene revision through the existing render-video node. */
713
797
  interface RenderScene3DParams extends Record<string, unknown> {
714
798
  planType: "3d-scene";
@@ -718,6 +802,8 @@ interface RenderScene3DParams extends Record<string, unknown> {
718
802
  }
719
803
  /** Preserve the shared wire contract while allowing additive job metadata. */
720
804
  type Scene3DJobOutput = Readonly<Scene3DJobOutputAny> & Readonly<Record<string, unknown>>;
805
+ /** The settled 3D Render Pro result, plus any additive job metadata. */
806
+ type Pro3DRenderJobOutput = Readonly<Pro3DRenderJobOutput$1> & Readonly<Record<string, unknown>>;
721
807
 
722
808
  type NodeCategory = "input" | "parameter" | "ai-image" | "ai-video" | "ai-audio" | "ai-text" | "processing" | "composition" | "trigger" | "output" | "control" | "entity" | "utility";
723
809
  type OutputType = "text" | "image" | "video" | "audio" | "data" | "none";
@@ -945,6 +1031,18 @@ interface RunAndWaitOptions {
945
1031
  readonly pollMs?: number;
946
1032
  /** Wall-clock cap before giving up, in ms. Default ~15 min (900_000). */
947
1033
  readonly maxMs?: number;
1034
+ /**
1035
+ * `Idempotency-Key` for the submit half. Reuse the same value when retrying a
1036
+ * call that timed out, so the run is not started or charged twice. Omitted →
1037
+ * no key, which is the historical behaviour for every node that does not
1038
+ * require one.
1039
+ */
1040
+ readonly idempotencyKey?: string;
1041
+ }
1042
+ /** Per-call transport controls for {@link NodesResource.run}. */
1043
+ interface RunNodeOptions {
1044
+ /** `Idempotency-Key` header. See {@link RunAndWaitOptions.idempotencyKey}. */
1045
+ readonly idempotencyKey?: string;
948
1046
  }
949
1047
  /** One settled result from {@link NodesResource.runMany}. */
950
1048
  interface RunManyResult {
@@ -984,11 +1082,12 @@ declare class NodesResource {
984
1082
  run(type: "generate-3d-scene", params: GenerateScene3DParams): Promise<RunNodeResult>;
985
1083
  run(type: "edit-3d-scene", params: EditScene3DParams): Promise<RunNodeResult>;
986
1084
  run(type: "render-video", params: RenderScene3DParams): Promise<RunNodeResult>;
1085
+ run(type: "pro-3d-render", params: Pro3DRenderRunParams, options?: RunNodeOptions): Promise<RunNodeResult>;
987
1086
  run(type: "generate-image", params?: GenerateImageParams): Promise<RunNodeResult>;
988
1087
  run(type: "generate-video", params?: GenerateVideoParams): Promise<RunNodeResult>;
989
1088
  run(type: "text-to-video", params: TextToVideoParams): Promise<RunNodeResult>;
990
1089
  run(type: "assemble-narrated-video", params?: AssembleNarratedVideoParams): Promise<RunNodeResult>;
991
- run(type: string, params?: Record<string, unknown>): Promise<RunNodeResult>;
1090
+ run(type: string, params?: Record<string, unknown>, options?: RunNodeOptions): Promise<RunNodeResult>;
992
1091
  /**
993
1092
  * Run a single async node to completion: {@link run} it, extract the
994
1093
  * `{ jobId }`, then client-poll `jobs.getStatus(jobId)` every `pollMs`
@@ -1019,11 +1118,12 @@ declare class NodesResource {
1019
1118
  runAndWait(type: "generate-3d-scene", params: GenerateScene3DParams, options?: RunAndWaitOptions): Promise<Scene3DJobOutput>;
1020
1119
  runAndWait(type: "edit-3d-scene", params: EditScene3DParams, options?: RunAndWaitOptions): Promise<Scene3DJobOutput>;
1021
1120
  runAndWait(type: "render-video", params: RenderScene3DParams, options?: RunAndWaitOptions): Promise<NodeJobOutput>;
1121
+ runAndWait(type: "pro-3d-render", params: Pro3DRenderRunParams, options?: RunAndWaitOptions): Promise<Pro3DRenderJobOutput>;
1022
1122
  runAndWait(type: "generate-image", params?: GenerateImageParams, opts?: RunAndWaitOptions): Promise<NodeJobOutput>;
1023
1123
  runAndWait(type: "generate-video", params?: GenerateVideoParams, opts?: RunAndWaitOptions): Promise<NodeJobOutput>;
1024
1124
  runAndWait(type: "text-to-video", params: TextToVideoParams, opts?: RunAndWaitOptions): Promise<NodeJobOutput>;
1025
1125
  runAndWait(type: "assemble-narrated-video", params?: AssembleNarratedVideoParams, opts?: RunAndWaitOptions): Promise<NodeJobOutput>;
1026
- runAndWait<T extends string>(type: T, params?: Record<string, unknown>, opts?: RunAndWaitOptions): Promise<T extends "generate-3d-scene" | "edit-3d-scene" ? Scene3DJobOutput : NodeJobOutput>;
1126
+ runAndWait<T extends string>(type: T, params?: Record<string, unknown>, opts?: RunAndWaitOptions): Promise<T extends "pro-3d-render" ? Pro3DRenderJobOutput : T extends "generate-3d-scene" | "edit-3d-scene" ? Scene3DJobOutput : NodeJobOutput>;
1027
1127
  /**
1028
1128
  * Fan out N async runs of the same node `type` to completion concurrently —
1029
1129
  * the candidate-grid path (generate N stills/clips in parallel). Each runs
@@ -1050,6 +1150,11 @@ declare class Scene3DResource {
1050
1150
  private client;
1051
1151
  constructor(client: NodaroClient);
1052
1152
  capabilities(): Promise<Scene3DCapabilities>;
1153
+ /** Current access to both the delivery and its source is required on every read. */
1154
+ getDelivery(jobId: string): Promise<Scene3DDelivery>;
1155
+ deliveryAssetBytes(jobId: string, asset: Scene3DDeliveryAsset, options?: {
1156
+ signal?: AbortSignal;
1157
+ }): Promise<ArrayBuffer>;
1053
1158
  /** Persist deterministic overlays without an LLM or a generation charge. */
1054
1159
  applyEdits(revisionId: string, params: RetainedScene3DEditParams): Promise<RetainedScene3DEditResult>;
1055
1160
  /** Asset access is scoped to an exact retained revision, with fresh authentication. */
@@ -1064,6 +1169,41 @@ declare class Scene3DResource {
1064
1169
  generateAndWait(params: GenerateScene3DParams, options?: RunAndWaitOptions): Promise<Scene3DJobOutput>;
1065
1170
  edit(params: EditScene3DParams): Promise<RunNodeResult>;
1066
1171
  editAndWait(params: EditScene3DParams, options?: RunAndWaitOptions): Promise<Scene3DJobOutput>;
1172
+ /**
1173
+ * Price a 3D Render Pro request WITHOUT starting it.
1174
+ *
1175
+ * Takes the same body a run takes, minus the `quoteId`, and answers a
1176
+ * ceiling (`maxCredits`), a `breakdown` to show, and the
1177
+ * `normalizedInputHash` admission re-checks. It reserves nothing and spends
1178
+ * nothing — a quote is a price, not a purchase.
1179
+ */
1180
+ quotePro(params: Pro3DRenderParams): Promise<Pro3DRenderQuote>;
1181
+ /**
1182
+ * Submit a quoted 3D Render Pro run.
1183
+ *
1184
+ * Requires the `quoteId` from {@link quotePro}: no run starts at a price
1185
+ * nobody showed. Sends an `Idempotency-Key` — a fresh one per call unless you
1186
+ * supply your own, which you should when retrying a call that timed out.
1187
+ *
1188
+ * Availability is a property of the deployment: `capabilities().pro` says
1189
+ * whether this install can serve it, and which controls you may offer.
1190
+ */
1191
+ runPro(params: Pro3DRenderRunParams, options?: Pro3DRenderRunOptions): Promise<RunNodeResult>;
1192
+ /**
1193
+ * Quote if needed, run, and wait — the whole operation in one call.
1194
+ *
1195
+ * Two HTTP requests at most, still ONE paid job: when `quoteId` is absent
1196
+ * this quotes the identical body first, so the run is admitted against a
1197
+ * hash of exactly what was priced. Pass a `quoteId` to run against a quote
1198
+ * you already showed the user.
1199
+ *
1200
+ * Resolves with the settled result — `videoUrl` (the MP4) and `scenePlan`
1201
+ * (the exact composition it was rendered from), plus the revision, poster,
1202
+ * validation and renderer metadata. Re-render that same `scenePlan` later
1203
+ * with {@link render}, or with a `{kind:'scene'}` source; that costs no
1204
+ * authoring.
1205
+ */
1206
+ renderProAndWait(params: Pro3DRenderParams | Pro3DRenderRunParams, options?: RunAndWaitOptions & Pro3DRenderRunOptions): Promise<Pro3DRenderJobOutput>;
1067
1207
  /** Uses the supplied immutable revision; never starts authoring or a rebuild. */
1068
1208
  render(params: RenderScene3DParams): Promise<RunNodeResult>;
1069
1209
  renderAndWait(params: RenderScene3DParams, options?: RunAndWaitOptions): Promise<NodeJobOutput>;
@@ -6841,4 +6981,4 @@ interface ApiErrorBody {
6841
6981
  }
6842
6982
  declare function throwFromResponse(status: number, body: ApiErrorBody): never;
6843
6983
 
6844
- 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 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 };
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 };
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { CollaboratorRole, GenericNode, GenericEdge, WorkflowExport, WorkflowImportReport, WorkflowVisibility, Scene3DReference, Scene3DPlan, Scene3DEditOperation, Scene3DV2EditOperation, Scene3DJobOutputAny, Scene3DPlanV2, 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';
1
+ 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
2
  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
3
  import { DirectionFields, SubjectFields, PersonValue, WizardNodeContext, WizardQuestion, WizardSelection, RecommendedModel, FactoryPreset } from '@nodaro/prompts';
4
4
  export { PEOPLE, PERSON_DIMENSION_LABELS, PERSON_DIMENSION_ORDER, PersonValue, RecommendedModel, WizardNodeContext, WizardOption, WizardQuestion, WizardSelection, buildPersonHints } from '@nodaro/prompts';
@@ -659,6 +659,27 @@ interface RetainedScene3DEditResult {
659
659
  scenePlan: Scene3DPlanV2;
660
660
  changeSummary: string;
661
661
  }
662
+ interface Scene3DDeliveryAsset {
663
+ assetId: string;
664
+ kind: "poster" | "validation-report";
665
+ usage: "poster" | "validation";
666
+ byteLength: number;
667
+ sha256: string;
668
+ viaRevisionId: string | null;
669
+ }
670
+ /** Export evidence is retained separately from the immutable scene it rendered. */
671
+ interface Scene3DDelivery {
672
+ deliveryId: string;
673
+ sceneRevisionId: string;
674
+ sourcePlanSha256: string;
675
+ sourceContentHash: string | null;
676
+ sourceJobId: string | null;
677
+ workflowId: string | null;
678
+ mode: "authored" | "render-only";
679
+ createdAt: string;
680
+ access: "view" | "edit" | "own";
681
+ assets: Scene3DDeliveryAsset[];
682
+ }
662
683
  type Scene3DAuthoringEngine = "basic" | "blender-cloud" | "blender-local";
663
684
  interface Scene3DCapabilities {
664
685
  basic: {
@@ -671,6 +692,13 @@ interface Scene3DCapabilities {
671
692
  sceneSchemaVersions: number[];
672
693
  maxRepairPasses: number;
673
694
  };
695
+ /**
696
+ * What this deployment can serve for `pro-3d-render`, including which
697
+ * quality profiles, engines and aspect ratios a client may OFFER. Optional so
698
+ * a client of this version reads an older backend without throwing; absent
699
+ * means the node is unavailable.
700
+ */
701
+ pro?: Pro3DRenderCapabilities;
674
702
  }
675
703
  interface Scene3DEngineParams {
676
704
  /** Basic is the default. Discover optional engines through scene3d.capabilities(). */
@@ -709,6 +737,62 @@ interface EditScene3DParams extends Record<string, unknown>, Scene3DEngineParams
709
737
  workflowId?: string;
710
738
  nodeId?: string;
711
739
  }
740
+ /**
741
+ * 3D Render Pro — ONE durable operation producing a composition and its MP4.
742
+ *
743
+ * `source` is a strict discriminated union, not a bag of optionals:
744
+ * - `{kind:'prompt', prompt, references?}` authors a new scene;
745
+ * - `{kind:'scene', revisionId, sourceJobId}` with NO `editPrompt` is the
746
+ * render-only export — it spends no authoring or build credits, and OMIT
747
+ * the field rather than sending `""`, which would buy an authoring pass;
748
+ * - `{kind:'local-export', exportId, connectionId}` uses a paired desktop.
749
+ *
750
+ * There is no model or effort field: the planner is fixed and server-owned.
751
+ *
752
+ * `durationSeconds` / `fps` / `aspectRatio` on a `scene` source are an EXPLICIT
753
+ * re-time request. Omit them to keep the source's own timing; a conflicting
754
+ * override is rejected rather than silently applied.
755
+ */
756
+ interface Pro3DRenderParams extends Record<string, unknown> {
757
+ source: Pro3DRenderSource;
758
+ /** Optional. An unknown or unavailable engine is rejected, never downgraded. */
759
+ engine?: Pro3DRenderEngine;
760
+ /** Names a paired desktop for a local run. */
761
+ localConnectionId?: string;
762
+ durationSeconds?: number;
763
+ fps?: number;
764
+ aspectRatio?: string;
765
+ quality?: Pro3DRenderQuality;
766
+ style?: Pro3DRenderStyle;
767
+ /** Correction budget, 0-2. Each pass is paid work. */
768
+ maxRepairPasses?: number;
769
+ /**
770
+ * Which scene-schema versions THIS client can render. A prompt or
771
+ * local-export source mints v2, so omitting 2 is refused for free; a scene
772
+ * source inherits its revision's version and is left to the server.
773
+ */
774
+ acceptedSceneSchemaVersions?: readonly number[];
775
+ workflowId?: string;
776
+ nodeId?: string;
777
+ /** Keep every artifact of this run out of publicly-readable storage. */
778
+ forcePrivate?: boolean;
779
+ }
780
+ /** A run additionally carries the quote it was priced under. */
781
+ interface Pro3DRenderRunParams extends Pro3DRenderParams {
782
+ quoteId: string;
783
+ }
784
+ /** The quote's answer. `maxCredits` is a ceiling; quoting spends nothing. */
785
+ type Pro3DRenderQuote = Readonly<Pro3DRenderQuote$1> & Readonly<Record<string, unknown>>;
786
+ /** Per-call transport controls for the paid run. */
787
+ interface Pro3DRenderRunOptions {
788
+ /**
789
+ * The `Idempotency-Key` the run is submitted under. Reuse the same value when
790
+ * retrying a call that timed out, so the run is not started twice; the SDK
791
+ * generates a fresh one per call when this is omitted, because two deliberate
792
+ * calls are two runs.
793
+ */
794
+ idempotencyKey?: string;
795
+ }
712
796
  /** Render the exact scene revision through the existing render-video node. */
713
797
  interface RenderScene3DParams extends Record<string, unknown> {
714
798
  planType: "3d-scene";
@@ -718,6 +802,8 @@ interface RenderScene3DParams extends Record<string, unknown> {
718
802
  }
719
803
  /** Preserve the shared wire contract while allowing additive job metadata. */
720
804
  type Scene3DJobOutput = Readonly<Scene3DJobOutputAny> & Readonly<Record<string, unknown>>;
805
+ /** The settled 3D Render Pro result, plus any additive job metadata. */
806
+ type Pro3DRenderJobOutput = Readonly<Pro3DRenderJobOutput$1> & Readonly<Record<string, unknown>>;
721
807
 
722
808
  type NodeCategory = "input" | "parameter" | "ai-image" | "ai-video" | "ai-audio" | "ai-text" | "processing" | "composition" | "trigger" | "output" | "control" | "entity" | "utility";
723
809
  type OutputType = "text" | "image" | "video" | "audio" | "data" | "none";
@@ -945,6 +1031,18 @@ interface RunAndWaitOptions {
945
1031
  readonly pollMs?: number;
946
1032
  /** Wall-clock cap before giving up, in ms. Default ~15 min (900_000). */
947
1033
  readonly maxMs?: number;
1034
+ /**
1035
+ * `Idempotency-Key` for the submit half. Reuse the same value when retrying a
1036
+ * call that timed out, so the run is not started or charged twice. Omitted →
1037
+ * no key, which is the historical behaviour for every node that does not
1038
+ * require one.
1039
+ */
1040
+ readonly idempotencyKey?: string;
1041
+ }
1042
+ /** Per-call transport controls for {@link NodesResource.run}. */
1043
+ interface RunNodeOptions {
1044
+ /** `Idempotency-Key` header. See {@link RunAndWaitOptions.idempotencyKey}. */
1045
+ readonly idempotencyKey?: string;
948
1046
  }
949
1047
  /** One settled result from {@link NodesResource.runMany}. */
950
1048
  interface RunManyResult {
@@ -984,11 +1082,12 @@ declare class NodesResource {
984
1082
  run(type: "generate-3d-scene", params: GenerateScene3DParams): Promise<RunNodeResult>;
985
1083
  run(type: "edit-3d-scene", params: EditScene3DParams): Promise<RunNodeResult>;
986
1084
  run(type: "render-video", params: RenderScene3DParams): Promise<RunNodeResult>;
1085
+ run(type: "pro-3d-render", params: Pro3DRenderRunParams, options?: RunNodeOptions): Promise<RunNodeResult>;
987
1086
  run(type: "generate-image", params?: GenerateImageParams): Promise<RunNodeResult>;
988
1087
  run(type: "generate-video", params?: GenerateVideoParams): Promise<RunNodeResult>;
989
1088
  run(type: "text-to-video", params: TextToVideoParams): Promise<RunNodeResult>;
990
1089
  run(type: "assemble-narrated-video", params?: AssembleNarratedVideoParams): Promise<RunNodeResult>;
991
- run(type: string, params?: Record<string, unknown>): Promise<RunNodeResult>;
1090
+ run(type: string, params?: Record<string, unknown>, options?: RunNodeOptions): Promise<RunNodeResult>;
992
1091
  /**
993
1092
  * Run a single async node to completion: {@link run} it, extract the
994
1093
  * `{ jobId }`, then client-poll `jobs.getStatus(jobId)` every `pollMs`
@@ -1019,11 +1118,12 @@ declare class NodesResource {
1019
1118
  runAndWait(type: "generate-3d-scene", params: GenerateScene3DParams, options?: RunAndWaitOptions): Promise<Scene3DJobOutput>;
1020
1119
  runAndWait(type: "edit-3d-scene", params: EditScene3DParams, options?: RunAndWaitOptions): Promise<Scene3DJobOutput>;
1021
1120
  runAndWait(type: "render-video", params: RenderScene3DParams, options?: RunAndWaitOptions): Promise<NodeJobOutput>;
1121
+ runAndWait(type: "pro-3d-render", params: Pro3DRenderRunParams, options?: RunAndWaitOptions): Promise<Pro3DRenderJobOutput>;
1022
1122
  runAndWait(type: "generate-image", params?: GenerateImageParams, opts?: RunAndWaitOptions): Promise<NodeJobOutput>;
1023
1123
  runAndWait(type: "generate-video", params?: GenerateVideoParams, opts?: RunAndWaitOptions): Promise<NodeJobOutput>;
1024
1124
  runAndWait(type: "text-to-video", params: TextToVideoParams, opts?: RunAndWaitOptions): Promise<NodeJobOutput>;
1025
1125
  runAndWait(type: "assemble-narrated-video", params?: AssembleNarratedVideoParams, opts?: RunAndWaitOptions): Promise<NodeJobOutput>;
1026
- runAndWait<T extends string>(type: T, params?: Record<string, unknown>, opts?: RunAndWaitOptions): Promise<T extends "generate-3d-scene" | "edit-3d-scene" ? Scene3DJobOutput : NodeJobOutput>;
1126
+ runAndWait<T extends string>(type: T, params?: Record<string, unknown>, opts?: RunAndWaitOptions): Promise<T extends "pro-3d-render" ? Pro3DRenderJobOutput : T extends "generate-3d-scene" | "edit-3d-scene" ? Scene3DJobOutput : NodeJobOutput>;
1027
1127
  /**
1028
1128
  * Fan out N async runs of the same node `type` to completion concurrently —
1029
1129
  * the candidate-grid path (generate N stills/clips in parallel). Each runs
@@ -1050,6 +1150,11 @@ declare class Scene3DResource {
1050
1150
  private client;
1051
1151
  constructor(client: NodaroClient);
1052
1152
  capabilities(): Promise<Scene3DCapabilities>;
1153
+ /** Current access to both the delivery and its source is required on every read. */
1154
+ getDelivery(jobId: string): Promise<Scene3DDelivery>;
1155
+ deliveryAssetBytes(jobId: string, asset: Scene3DDeliveryAsset, options?: {
1156
+ signal?: AbortSignal;
1157
+ }): Promise<ArrayBuffer>;
1053
1158
  /** Persist deterministic overlays without an LLM or a generation charge. */
1054
1159
  applyEdits(revisionId: string, params: RetainedScene3DEditParams): Promise<RetainedScene3DEditResult>;
1055
1160
  /** Asset access is scoped to an exact retained revision, with fresh authentication. */
@@ -1064,6 +1169,41 @@ declare class Scene3DResource {
1064
1169
  generateAndWait(params: GenerateScene3DParams, options?: RunAndWaitOptions): Promise<Scene3DJobOutput>;
1065
1170
  edit(params: EditScene3DParams): Promise<RunNodeResult>;
1066
1171
  editAndWait(params: EditScene3DParams, options?: RunAndWaitOptions): Promise<Scene3DJobOutput>;
1172
+ /**
1173
+ * Price a 3D Render Pro request WITHOUT starting it.
1174
+ *
1175
+ * Takes the same body a run takes, minus the `quoteId`, and answers a
1176
+ * ceiling (`maxCredits`), a `breakdown` to show, and the
1177
+ * `normalizedInputHash` admission re-checks. It reserves nothing and spends
1178
+ * nothing — a quote is a price, not a purchase.
1179
+ */
1180
+ quotePro(params: Pro3DRenderParams): Promise<Pro3DRenderQuote>;
1181
+ /**
1182
+ * Submit a quoted 3D Render Pro run.
1183
+ *
1184
+ * Requires the `quoteId` from {@link quotePro}: no run starts at a price
1185
+ * nobody showed. Sends an `Idempotency-Key` — a fresh one per call unless you
1186
+ * supply your own, which you should when retrying a call that timed out.
1187
+ *
1188
+ * Availability is a property of the deployment: `capabilities().pro` says
1189
+ * whether this install can serve it, and which controls you may offer.
1190
+ */
1191
+ runPro(params: Pro3DRenderRunParams, options?: Pro3DRenderRunOptions): Promise<RunNodeResult>;
1192
+ /**
1193
+ * Quote if needed, run, and wait — the whole operation in one call.
1194
+ *
1195
+ * Two HTTP requests at most, still ONE paid job: when `quoteId` is absent
1196
+ * this quotes the identical body first, so the run is admitted against a
1197
+ * hash of exactly what was priced. Pass a `quoteId` to run against a quote
1198
+ * you already showed the user.
1199
+ *
1200
+ * Resolves with the settled result — `videoUrl` (the MP4) and `scenePlan`
1201
+ * (the exact composition it was rendered from), plus the revision, poster,
1202
+ * validation and renderer metadata. Re-render that same `scenePlan` later
1203
+ * with {@link render}, or with a `{kind:'scene'}` source; that costs no
1204
+ * authoring.
1205
+ */
1206
+ renderProAndWait(params: Pro3DRenderParams | Pro3DRenderRunParams, options?: RunAndWaitOptions & Pro3DRenderRunOptions): Promise<Pro3DRenderJobOutput>;
1067
1207
  /** Uses the supplied immutable revision; never starts authoring or a rebuild. */
1068
1208
  render(params: RenderScene3DParams): Promise<RunNodeResult>;
1069
1209
  renderAndWait(params: RenderScene3DParams, options?: RunAndWaitOptions): Promise<NodeJobOutput>;
@@ -6841,4 +6981,4 @@ interface ApiErrorBody {
6841
6981
  }
6842
6982
  declare function throwFromResponse(status: number, body: ApiErrorBody): never;
6843
6983
 
6844
- 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 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 };
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 };
package/dist/index.js CHANGED
@@ -538,13 +538,19 @@ var NodesResource = class {
538
538
  get(type) {
539
539
  return this.client.request("GET", `/v1/nodes/${encodeURIComponent(type)}`);
540
540
  }
541
- run(type, params = {}) {
541
+ run(type, params = {}, options = {}) {
542
542
  const route = type === "generate-3d-scene" ? "/v1/3d-scene/generate" : type === "edit-3d-scene" ? "/v1/3d-scene/edit" : type === "render-video" && typeof params.planType === "string" ? "/v1/render-video/plan" : `/v1/${encodeURIComponent(type)}`;
543
- return this.client.request("POST", route, { body: params });
543
+ return this.client.request("POST", route, {
544
+ body: params,
545
+ // Transport-level retry safety, opt-in per call. The platform reads the
546
+ // standard header, so a caller that reuses a key on a retry gets the
547
+ // same run back instead of a second charge.
548
+ ...options.idempotencyKey ? { headers: { "Idempotency-Key": options.idempotencyKey } } : {}
549
+ });
544
550
  }
545
551
  async runAndWait(type, params = {}, opts = {}) {
546
552
  if (opts.signal?.aborted) throw new JobAbortedError();
547
- const result = await this.run(type, params);
553
+ const result = await this.run(type, params, { idempotencyKey: opts.idempotencyKey });
548
554
  const jobId = extractJobId(result, type);
549
555
  return this.pollJob(jobId, type, opts);
550
556
  }
@@ -605,6 +611,10 @@ var NodesResource = class {
605
611
  }
606
612
  }
607
613
  };
614
+ function newIdempotencyKey() {
615
+ const random = globalThis.crypto?.randomUUID?.();
616
+ return `sdk-pro3d-${random ?? `${Date.now().toString(36)}-${Math.random().toString(36).slice(2, 12)}`}`;
617
+ }
608
618
  var Scene3DResource = class {
609
619
  constructor(client) {
610
620
  this.client = client;
@@ -613,6 +623,22 @@ var Scene3DResource = class {
613
623
  capabilities() {
614
624
  return this.client.request("GET", "/v1/3d-scene/capabilities");
615
625
  }
626
+ /** Current access to both the delivery and its source is required on every read. */
627
+ getDelivery(jobId) {
628
+ return this.client.request("GET", `/v1/3d-scene/deliveries/${encodeURIComponent(jobId)}`);
629
+ }
630
+ deliveryAssetBytes(jobId, asset, options) {
631
+ if (asset.kind !== "poster" && asset.kind !== "validation-report" || asset.usage !== (asset.kind === "poster" ? "poster" : "validation")) {
632
+ throw new Error("This asset is not available through the delivery endpoint");
633
+ }
634
+ if (!Number.isSafeInteger(asset.byteLength) || asset.byteLength < 1 || asset.byteLength > SCENE3D_V2_LIMITS.maxRendererAssetBytes) {
635
+ throw new Error("Invalid scene delivery asset byte length");
636
+ }
637
+ return this.client.requestBytes("GET", `/v1/3d-scene/deliveries/${encodeURIComponent(jobId)}/assets/${encodeURIComponent(asset.assetId)}`, {
638
+ signal: options?.signal,
639
+ maxBytes: asset.byteLength
640
+ });
641
+ }
616
642
  /** Persist deterministic overlays without an LLM or a generation charge. */
617
643
  applyEdits(revisionId, params) {
618
644
  return this.client.request("POST", `/v1/3d-scene/revisions/${encodeURIComponent(revisionId)}/edits`, { body: params });
@@ -649,6 +675,53 @@ var Scene3DResource = class {
649
675
  editAndWait(params, options) {
650
676
  return this.client.nodes.runAndWait("edit-3d-scene", params, options);
651
677
  }
678
+ /**
679
+ * Price a 3D Render Pro request WITHOUT starting it.
680
+ *
681
+ * Takes the same body a run takes, minus the `quoteId`, and answers a
682
+ * ceiling (`maxCredits`), a `breakdown` to show, and the
683
+ * `normalizedInputHash` admission re-checks. It reserves nothing and spends
684
+ * nothing — a quote is a price, not a purchase.
685
+ */
686
+ quotePro(params) {
687
+ return this.client.request("POST", "/v1/pro-3d-render/quote", { body: params });
688
+ }
689
+ /**
690
+ * Submit a quoted 3D Render Pro run.
691
+ *
692
+ * Requires the `quoteId` from {@link quotePro}: no run starts at a price
693
+ * nobody showed. Sends an `Idempotency-Key` — a fresh one per call unless you
694
+ * supply your own, which you should when retrying a call that timed out.
695
+ *
696
+ * Availability is a property of the deployment: `capabilities().pro` says
697
+ * whether this install can serve it, and which controls you may offer.
698
+ */
699
+ runPro(params, options) {
700
+ return this.client.nodes.run("pro-3d-render", params, {
701
+ idempotencyKey: options?.idempotencyKey ?? newIdempotencyKey()
702
+ });
703
+ }
704
+ /**
705
+ * Quote if needed, run, and wait — the whole operation in one call.
706
+ *
707
+ * Two HTTP requests at most, still ONE paid job: when `quoteId` is absent
708
+ * this quotes the identical body first, so the run is admitted against a
709
+ * hash of exactly what was priced. Pass a `quoteId` to run against a quote
710
+ * you already showed the user.
711
+ *
712
+ * Resolves with the settled result — `videoUrl` (the MP4) and `scenePlan`
713
+ * (the exact composition it was rendered from), plus the revision, poster,
714
+ * validation and renderer metadata. Re-render that same `scenePlan` later
715
+ * with {@link render}, or with a `{kind:'scene'}` source; that costs no
716
+ * authoring.
717
+ */
718
+ async renderProAndWait(params, options) {
719
+ const quoteId = typeof params.quoteId === "string" ? params.quoteId : (await this.quotePro(params)).quoteId;
720
+ return this.client.nodes.runAndWait("pro-3d-render", { ...params, quoteId }, {
721
+ ...options,
722
+ idempotencyKey: options?.idempotencyKey ?? newIdempotencyKey()
723
+ });
724
+ }
652
725
  /** Uses the supplied immutable revision; never starts authoring or a rebuild. */
653
726
  render(params) {
654
727
  return this.client.nodes.run("render-video", params);
@@ -3090,7 +3163,7 @@ var WorkspacesResource = class {
3090
3163
  return this.client.requestText("GET", `/v1/workspaces/${encodeURIComponent(id)}/usage`, { query: { ...opts, format: "csv" } });
3091
3164
  }
3092
3165
  };
3093
- var SDK_VERSION = "2.1.0" ;
3166
+ var SDK_VERSION = "2.2.0" ;
3094
3167
  var CLIENT_HEADER = "X-Nodaro-Client";
3095
3168
  var isBrowser = () => typeof window !== "undefined" && typeof window.document !== "undefined";
3096
3169
  var NodaroClient = class _NodaroClient {