@comfyorg/ingest-types 1.7.2 → 1.7.3

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.
@@ -91,6 +91,23 @@ export type AccessEventsPagination = {
91
91
  */
92
92
  next_cursor?: string;
93
93
  };
94
+ /**
95
+ * The upload to add to the models of the deployment's Build.
96
+ */
97
+ export type AddDeploymentBuildModelRequest = {
98
+ /**
99
+ * The blobId the model upload route answered.
100
+ */
101
+ blobId: string;
102
+ /**
103
+ * The file name in that folder, a relative path with no `..`.
104
+ */
105
+ filename: string;
106
+ /**
107
+ * The model folder, for example `loras` or `checkpoints`.
108
+ */
109
+ type: string;
110
+ };
94
111
  /**
95
112
  * The upload to add to the deployment, passed to comfy-deploy as written.
96
113
  */
@@ -112,20 +129,30 @@ export type AddDeploymentModelRequest = {
112
129
  * Returned when a request to run the agent is declined before the turn starts, because of a billing or account condition on the workspace. The `error` object carries a `message` you can show the user, a `type` that matches the HTTP status, and a more specific `reason` you can branch on to offer the right next step.
113
130
  */
114
131
  export type AgentAdmissionError = {
132
+ /**
133
+ * All exhausted hard budgets, visible to workspace Owners.
134
+ */
135
+ blocking_budgets?: Array<SpendBudgetDetail>;
136
+ budget?: SpendBudgetDetail;
137
+ denied_reason?: string;
115
138
  error: {
116
139
  /**
117
140
  * A human-readable explanation of why the request was declined, suitable for display.
118
141
  */
119
142
  message: string;
120
143
  /**
121
- * The specific cause of the denial, for choosing what to show the user. `no_funds`: the workspace is out of credits — prompt them to add credits. `manual_block`: the workspace has been blocked — direct them to support. `funds_unavailable`: billing was temporarily unreachable — retry after the delay given in the `Retry-After` response header.
144
+ * The specific cause of the denial, for choosing what to show the user. `no_funds`: the workspace is out of credits — prompt them to add credits. `manual_block`: the workspace has been blocked — direct them to support. `funds_unavailable`: billing was temporarily unreachable — retry after the delay given in the `Retry-After` response header. `budget_exceeded` means a hard budget prevented the turn from starting.
122
145
  */
123
- reason: 'no_funds' | 'manual_block' | 'funds_unavailable';
146
+ reason: 'budget_exceeded' | 'no_funds' | 'manual_block' | 'funds_unavailable';
124
147
  /**
125
148
  * The general category of the denial, matching the HTTP status. `PAYMENT_REQUIRED` (402): the workspace cannot currently pay for a turn. `SERVICE_UNAVAILABLE` (503): billing status could not be checked right now and the request can be retried (see the `Retry-After` response header).
126
149
  */
127
150
  type: 'PAYMENT_REQUIRED' | 'SERVICE_UNAVAILABLE';
128
151
  };
152
+ /**
153
+ * For budget admission, `budget_exceeded` or `budget_check_unavailable`.
154
+ */
155
+ error_type?: string;
129
156
  };
130
157
  /**
131
158
  * Acknowledgement that the ask is answered and the parked turn was woken; its continuation streams over the WebSocket. `selected` and `other_text` are the answer committed to the ask row. The first answer wins: when an earlier request already committed one (a retry, or another tab), this carries THAT answer, not the request body, so compare it with what you sent before showing it as the user's choice.
@@ -313,6 +340,25 @@ export type AgentAttachmentRejected = {
313
340
  rejected_count: number;
314
341
  type: 'ATTACHMENT_TYPE_NOT_ACCEPTED';
315
342
  };
343
+ /**
344
+ * One on-demand skill the agent itself ships.
345
+ */
346
+ export type AgentBuiltinSkill = {
347
+ /**
348
+ * What the model reads to decide when to load the skill. It is written for the model and can run to several sentences.
349
+ */
350
+ description: string;
351
+ /**
352
+ * The skill's flat identifier and the load_skill argument.
353
+ */
354
+ name: string;
355
+ };
356
+ /**
357
+ * The on-demand skills the agent itself ships, ordered by name.
358
+ */
359
+ export type AgentBuiltinSkillListResponse = {
360
+ skills: Array<AgentBuiltinSkill>;
361
+ };
316
362
  /**
317
363
  * Acknowledgement that a turn cancellation was requested. Cancellation is asynchronous; the terminal message state (status=error with stop copy) arrives over the WebSocket.
318
364
  */
@@ -380,7 +426,7 @@ export type AgentDraftSnapshot = {
380
426
  */
381
427
  export type AgentError = {
382
428
  /**
383
- * Stable discriminator authored only by the local agent host when its local-page security check refuses a request. The currently defined value is agent_loopback_only. Clients must accept unknown values so the host can add refusal reasons without breaking older readers. Absent on errors from the cloud agent service.
429
+ * Stable discriminator. The local agent host sets agent_loopback_only when its local-page security check refuses a request; the model selection refusals set model_unavailable and model_selection_disabled (AgentModelUnavailable, AgentModelSelectionDisabled). Clients must accept unknown values so new refusal reasons do not break older readers. Absent on other errors.
384
430
  */
385
431
  code?: string;
386
432
  /**
@@ -422,6 +468,85 @@ export type AgentExtensionChangedFrame = {
422
468
  data: AgentExtensionChangedData;
423
469
  type: 'agent_extension_changed';
424
470
  };
471
+ /**
472
+ * One entry of the model control.
473
+ */
474
+ export type AgentFeatureSelection = {
475
+ /**
476
+ * Optional relative cost cue, 1 to 3. Not a price.
477
+ */
478
+ cost_tier?: number;
479
+ /**
480
+ * Optional secondary display text.
481
+ */
482
+ description?: string;
483
+ /**
484
+ * Optional id of an entry in `groups`.
485
+ */
486
+ group?: string;
487
+ /**
488
+ * Stable id of the entry.
489
+ */
490
+ id: string;
491
+ /**
492
+ * Optional presentation hint: `option` (a semantic label such as Fast), `family` (a model name without a version) or `model` (an exact model). Rendered the same way; accept unknown values.
493
+ */
494
+ kind?: string;
495
+ /**
496
+ * Display text. Do not rewrite.
497
+ */
498
+ label: string;
499
+ /**
500
+ * Optional display name of the model the entry is bound to.
501
+ */
502
+ model_label?: string;
503
+ send: AgentModelSelection;
504
+ /**
505
+ * Optional; when true, show `model_label` under the label.
506
+ */
507
+ show_model?: boolean;
508
+ [key: string]: unknown;
509
+ };
510
+ /**
511
+ * The model selections a caller may be shown (GET /api/agent/features). Clients ignore keys they do not know; more are added over time. It never carries an internal model configuration name or a profile revision.
512
+ */
513
+ export type AgentFeatures = {
514
+ /**
515
+ * The selection id a new chat shows when `selected` is absent. Present whenever `selections` is not empty.
516
+ */
517
+ default_selection?: string;
518
+ /**
519
+ * Whether model selection is on for this caller. False: show no control and send messages as today.
520
+ */
521
+ enabled: boolean;
522
+ /**
523
+ * Optional labelled groups that selections may name in `group`.
524
+ */
525
+ groups?: Array<{
526
+ id: string;
527
+ label: string;
528
+ [key: string]: unknown;
529
+ }>;
530
+ /**
531
+ * The entry to show as current: the thread's when `thread_id` was given, otherwise the saved preference. Absent when there is nothing valid to show; then show `default_selection`.
532
+ */
533
+ selected?: {
534
+ /**
535
+ * A selection id from `selections`.
536
+ */
537
+ selection: string;
538
+ /**
539
+ * Where it came from (`thread` or `saved_default`). Informational; accept unknown values.
540
+ */
541
+ source?: string;
542
+ [key: string]: unknown;
543
+ };
544
+ /**
545
+ * The entries to show, in order. None: no control. One: its label, no menu. Two or more: a menu.
546
+ */
547
+ selections?: Array<AgentFeatureSelection>;
548
+ [key: string]: unknown;
549
+ };
425
550
  /**
426
551
  * The (workspace, user) the agent service attributes the caller's requests to.
427
552
  */
@@ -449,6 +574,25 @@ export type AgentLlmError = {
449
574
  };
450
575
  type: 'error';
451
576
  };
577
+ /**
578
+ * OpenAI-shaped error envelope on POST /api/agent/llm/v1/chat/completions and POST /api/agent/llm/v1/responses, written by the LLM proxy or passed through from the provider.
579
+ */
580
+ export type AgentLlmOpenAiError = {
581
+ error: {
582
+ /**
583
+ * An optional machine-readable reason; often null.
584
+ */
585
+ code?: string | null;
586
+ /**
587
+ * A human-readable explanation.
588
+ */
589
+ message: string;
590
+ /**
591
+ * The error category, such as `permission_error` (not served on this target) or `rate_limit_error`. Clients must accept unknown values.
592
+ */
593
+ type: string;
594
+ };
595
+ };
452
596
  /**
453
597
  * A persisted message in an agent thread.
454
598
  */
@@ -514,17 +658,13 @@ export type AgentModelReceipt = {
514
658
  * Exact model ID to which the turn is pinned.
515
659
  */
516
660
  model_id: string;
517
- /**
518
- * Profile revision pinned for the turn (bootstrap for the configured default profile).
519
- */
520
- profile_revision: string;
521
661
  /**
522
662
  * The supplied model_selection object, or null when omitted.
523
663
  */
524
664
  requested: AgentModelSelection | null;
525
665
  source: 'request' | 'deployment_default';
526
666
  strategy: 'anthropic';
527
- wire: 'anthropic_messages' | 'openai_chat';
667
+ wire: 'anthropic_messages' | 'openai_chat' | 'openai_responses';
528
668
  };
529
669
  /**
530
670
  * An explicit exact model selection. Unknown properties are refused with 400 so a newer intent is never silently ignored by an older server.
@@ -539,6 +679,18 @@ export type AgentModelSelection = {
539
679
  */
540
680
  option_id?: string;
541
681
  };
682
+ export type AgentModelSelectionDisabled = AgentError & {
683
+ code: 'model_selection_disabled';
684
+ };
685
+ /**
686
+ * The selection a model-selection save committed.
687
+ */
688
+ export type AgentModelSelectionSaved = {
689
+ /**
690
+ * The id of the committed selection (an entry of `selections` in GET /api/agent/features).
691
+ */
692
+ selection: string;
693
+ };
542
694
  export type AgentModelUnavailable = AgentError & {
543
695
  code: 'model_unavailable';
544
696
  };
@@ -580,6 +732,10 @@ export type AgentPendingAskBase = {
580
732
  */
581
733
  allow_other: boolean;
582
734
  ask_id: string;
735
+ /**
736
+ * When the server stops waiting for the answer (RFC 3339, UTC). After it the server closes the card with an agent_ask_resolved event. Present only when the ask was opened with a wait of its own; when absent the server sets no answer deadline for this ask and the client must not assume one.
737
+ */
738
+ expires_at?: string;
583
739
  kind: AgentAskKind;
584
740
  max_selections: number;
585
741
  message_id: string;
@@ -669,7 +825,7 @@ export type AgentPostMessageRequest = {
669
825
  */
670
826
  content: string;
671
827
  /**
672
- * Cloud workflow id of the client's active editor tab; no ordering requirement. Modern clients use workflow_id for the editable target and omit this field. When present and authorized it selects the workflow the turn starts focused on — explicit workflow_id > current_tab > the thread's remembered workflow.
828
+ * Cloud workflow id of the client's active editor tab; no ordering requirement. Modern clients use workflow_id for the editable target and omit this field. When present and one the caller may change it selects the workflow the turn starts focused on — explicit workflow_id > current_tab > the thread's remembered workflow.
673
829
  */
674
830
  current_tab?: string;
675
831
  /**
@@ -689,7 +845,7 @@ export type AgentPostMessageRequest = {
689
845
  };
690
846
  model_selection?: AgentModelSelection;
691
847
  /**
692
- * Snapshot of the client's open editor tabs in editor order. Advisory context, not a grant — entries outside the caller's workspace are ignored. With workflow_references present, only the editable target and explicit references enter the model's workflow context.
848
+ * Snapshot of the client's open editor tabs in editor order. Advisory context, not a grant — entries the caller may not read are ignored. With workflow_references present, only the editable target and explicit references enter the model's workflow context.
693
849
  */
694
850
  open_tabs?: Array<{
695
851
  /**
@@ -712,13 +868,22 @@ export type AgentPostMessageRequest = {
712
868
  */
713
869
  workflow_id?: string;
714
870
  /**
715
- * Explicit read-only workflow references for this turn, independent of open_tabs. Omitted preserves legacy open-tab context; an empty array means no additional workflow context. The editable target is selected by workflow_id and excluded from references. Entries are workspace-authorized, deduplicated, capped at 50, and names truncated to 120 characters. References need not be open in the editor. Unknown or inaccessible references, including authorization lookup failures, are retained as unavailable metadata so the agent can acknowledge missing context; no workflow content or access is granted.
871
+ * Explicit read-only workflow references for this turn, independent of open_tabs. Omitted preserves legacy open-tab context; an empty array means no additional workflow context. The editable target is selected by workflow_id and excluded from references. Entries are checked against each workflow's read rule, deduplicated, capped at 50, and names truncated to 120 characters. References need not be open in the editor. Unknown or inaccessible references, including authorization lookup failures, are retained as unavailable metadata so the agent can acknowledge missing context; no workflow content or access is granted.
716
872
  */
717
873
  workflow_references?: Array<{
718
874
  name?: string;
719
875
  workflow_id: string;
720
876
  }>;
721
877
  };
878
+ /**
879
+ * User-by-workspace assignment for the proactive greeting experiment.
880
+ */
881
+ export type AgentProactiveGreetingAssignment = {
882
+ group_key: string;
883
+ user_id: string;
884
+ variant: 'control' | 'generic' | 'canvas-prefill' | 'canvas-only';
885
+ workspace_id: string;
886
+ };
722
887
  /**
723
888
  * Attachment extensions the agent can only describe from metadata. A subset of the containers
724
889
  * ingest sorts into a load node's video/audio lists: that categoriser also accepts .wmv, .flv,
@@ -1038,9 +1203,13 @@ export type AgentTurnUsage = {
1038
1203
  };
1039
1204
  export type AgentUsageStatusResponse = {
1040
1205
  /**
1041
- * Whether a persisted user-role message exists in a thread owned by this user in the current workspace. Does not imply a successful Agent reply, experiment eligibility or permanent retention of historical usage after server-side deletion.
1206
+ * Whether a retained accepted user-role message exists in the response's history scope. A later failed Agent reply still counts. Does not imply experiment assignment or permanent usage retention.
1042
1207
  */
1043
1208
  has_used_agent: boolean;
1209
+ /**
1210
+ * local_installation means this running Local Agent installation's retained message store, across its threads and local identities. It is not canonical user-by-workspace or cross-install history. Cloud omits this field and scopes history to the authenticated user and workspace. Local/Desktop clients require this marker; an absent marker means eligibility is unknown.
1211
+ */
1212
+ scope?: 'local_installation';
1044
1213
  };
1045
1214
  /**
1046
1215
  * Attachment extensions whose content the model can see: the raster formats Go's image
@@ -1054,6 +1223,10 @@ export type AgentViewableAttachmentExtension = '.png' | '.jpg' | '.jpeg' | '.gif
1054
1223
  * Represents a user-owned asset (image, video, or other generated output).
1055
1224
  */
1056
1225
  export type Asset = {
1226
+ /**
1227
+ * Set only on a `workspace_library` listing: true when the model policy of the Release that the caller's deployment runs (its own pick or the workspace default) blocks this model, so a Run that names it is refused. Absent when the policy allows it, when there is no policy, and on every other listing.
1228
+ */
1229
+ blocked_by_model_policy?: boolean;
1057
1230
  /**
1058
1231
  * Timestamp when the asset was created
1059
1232
  */
@@ -1117,7 +1290,7 @@ export type Asset = {
1117
1290
  */
1118
1291
  project_id?: string;
1119
1292
  /**
1120
- * Durable, owner-gated short link to this asset's content (relative `/api/s/{id}` path). Stable across the underlying signed URL's expiry — resolving it re-mints a fresh signed URL on every request — so it is safe to persist or share into chat, unlike `preview_url`. Only the minting user can resolve it. Omitted when the short-link surface is disabled or the asset has no resolvable content hash.
1293
+ * Durable, owner-gated short link to this asset's content (relative `/api/s/{id}` path). Stable across the underlying signed URL's expiry — resolving it re-mints a fresh signed URL on every request — so it is safe to persist or share into chat, unlike `preview_url`. Only the minting user can resolve it. Omitted when the short-link surface is disabled, the asset has no resolvable content hash, or the asset is in a project other than the default.
1121
1294
  */
1122
1295
  short_url?: string | null;
1123
1296
  /**
@@ -1697,7 +1870,7 @@ export type BillingBalanceResponse = {
1697
1870
  */
1698
1871
  low_balance?: boolean;
1699
1872
  /**
1700
- * The most one top-up from this API may charge, in cents. First-purchase responses use the same bounds as purchase validation.
1873
+ * The most one manual top-up may request for this workspace, in cents before tax or discounts: the $2,500 default, or a staff override (which may raise or lower it) up to the $10,000 hard maximum. Read it per workspace; request schemas carry no maximum. First-purchase responses use the same bounds as purchase validation.
1701
1874
  */
1702
1875
  max_topup_cents?: number;
1703
1876
  /**
@@ -1732,6 +1905,12 @@ export type BillingBalanceResponse = {
1732
1905
  * @deprecated
1733
1906
  */
1734
1907
  prepaid_balance_micros?: number;
1908
+ /**
1909
+ * Remaining balance of each product's own scoped pot, in cents of currency, keyed by product name. Today only "agent": the Agent-scoped pot (free Agent allowance and Agent promo credit together) that Agent turns draw before falling back to the shared balance. This is the amount behind billing status scoped_has_funds.agent, so a client can warn before it runs out. A fractional number. A key is absent when the workspace has never held that pot (0 means exhausted). The whole object is omitted when no pot is present, the workspace is unprovisioned, billing is disabled, or the server predates this field. Not included in amount_cents or any other total here.
1910
+ */
1911
+ scoped_balance_cents?: {
1912
+ [key: string]: number;
1913
+ };
1735
1914
  /**
1736
1915
  * Amount in cents to prefill for a top-up when the effective balance is negative: covers the shortfall plus the minimum top-up, rounded up to a whole dollar, never below the default amount and never above max_topup_cents. Null when the balance is zero or positive, or not authoritative.
1737
1916
  */
@@ -1752,7 +1931,8 @@ export type BillingBalanceResponse = {
1752
1931
  * every owner.
1753
1932
  *
1754
1933
  * When the deployment has billing disabled, this endpoint answers without
1755
- * consulting billing-api: can_top_up is true; can_manage_members,
1934
+ * consulting billing-api: can_top_up is true; can_view_workspace_usage
1935
+ * follows the same rule as with billing enabled; can_manage_members,
1756
1936
  * can_invite_members, can_manage_subscription, can_manage_auto_top_up and
1757
1937
  * can_view_auto_top_up follow the owner role, and
1758
1938
  * can_view_auto_top_up_member_notice is true for a non-owner. Other billing-action fields are false. These role
@@ -1857,21 +2037,23 @@ export type BillingCapabilities = {
1857
2037
  /**
1858
2038
  * - Answers: should the client offer sending a new workspace invitation right
1859
2039
  * now?
1860
- * - True: the user is a workspace owner and the workspace has room: members
1861
- * plus unexpired pending invitations are below the seat limit, or the limit
1862
- * is not positive (unlimited).
2040
+ * - True: the user is a workspace owner, or a Workspace admin (a member with
2041
+ * `workspace_admin`, where Projects is enabled for the workspace), and the
2042
+ * workspace has room: members plus unexpired pending invitations are below
2043
+ * the seat limit, or the limit is not positive (unlimited).
1863
2044
  * - False: never explained. There is no denied_reasons key for this field.
1864
2045
  * - Not: authorization (invitation creation enforces the same limit itself).
1865
- * Not member management (can_manage_members) and not buying seats
2046
+ * Not permission to invite an owner: an invitation sent here always makes a
2047
+ * member. Not member management (can_manage_members) and not buying seats
1866
2048
  * (can_change_seats). Pending invitations count toward capacity. The
1867
2049
  * resolver ignores tier, subscription status, cancellation and past-due
1868
2050
  * payment; only the seat limit, which can come from the active plan, reflects
1869
2051
  * the plan.
1870
- * - False when: the user is not an owner; the seat limit is 1 (the limit is the
1871
- * workspace override if set, else the active plan's default max seats, and
1872
- * defaults to one seat with no active subscription); members plus unexpired
1873
- * pending invitations have reached the limit; the capacity could not be
1874
- * read, which fails closed.
2052
+ * - False when: the user is neither an owner nor a Workspace admin; the seat
2053
+ * limit is 1 (the limit is the workspace override if set, else the active
2054
+ * plan's default max seats, and defaults to one seat with no active
2055
+ * subscription); members plus unexpired pending invitations have reached
2056
+ * the limit; the capacity could not be read, which fails closed.
1875
2057
  *
1876
2058
  */
1877
2059
  can_invite_members: boolean;
@@ -1926,15 +2108,23 @@ export type BillingCapabilities = {
1926
2108
  */
1927
2109
  can_manage_billing: boolean;
1928
2110
  /**
1929
- * - Answers: should the client offer member-management controls?
1930
- * - True: the user is a member of the workspace whose role is owner.
2111
+ * - Answers: should the client show the member-management section (the
2112
+ * member list with its per-member actions, and the invitation list)?
2113
+ * - True: the user is a member of the workspace whose role is owner, or a
2114
+ * Workspace admin (a member with `workspace_admin`, where Projects is
2115
+ * enabled for the workspace).
1931
2116
  * - False: never explained. There is no denied_reasons key for this field.
1932
- * - Not: authorization; individual target restrictions still apply. Not invite
1933
- * capacity (can_invite_members), seat quantity (can_change_seats) or billing
1934
- * management (can_manage_billing). Independent of tier, subscription status,
1935
- * cancellation, past-due payment and billing provisioning.
1936
- * - False when: the user is not a member, or is a member whose role is not
1937
- * owner. Nothing else closes it.
2117
+ * - Not: authorization, and not any one action. It does not say the user may
2118
+ * change a role, appoint or remove a Workspace admin, or act on a given
2119
+ * member: a Workspace admin may remove ordinary members only and changes no
2120
+ * role. Offer each per-member action from that member's
2121
+ * `capabilities.can_change_role` and `capabilities.can_remove`, never from
2122
+ * this field. Not invite capacity (can_invite_members), seat quantity
2123
+ * (can_change_seats) or billing management (can_manage_billing).
2124
+ * Independent of tier, subscription status, cancellation, past-due payment
2125
+ * and billing provisioning.
2126
+ * - False when: the user is not a member, or is a member who is neither an
2127
+ * owner nor a Workspace admin. Nothing else closes it.
1938
2128
  *
1939
2129
  */
1940
2130
  can_manage_members: boolean;
@@ -2129,18 +2319,49 @@ export type BillingCapabilities = {
2129
2319
  */
2130
2320
  can_view_own_usage?: boolean;
2131
2321
  /**
2132
- * Whether to offer the workspace invitation list. True for a current owner while workspace features are available. A false capability may have its matching denied_reasons key; absence means no recognized explanation. This is not capacity to send another invitation; use can_invite_members. The owner-only list route stays authoritative and can include expired invitations despite the word pending.
2322
+ * Whether to offer the workspace invitation list. True for a current owner, and for a Workspace admin where Projects is enabled for the workspace, while workspace features are available. A false capability may have its matching denied_reasons key; absence means no recognized explanation. This is not capacity to send another invitation; use can_invite_members. It does not say every listed invitation can be resent or revoked: a Workspace admin may act on member invitations only. The list route stays authoritative and can include expired invitations despite the word pending.
2133
2323
  */
2134
2324
  can_view_pending_invites: boolean;
2135
2325
  /**
2136
2326
  * Whether to offer whole-workspace usage analytics. True only for a current workspace owner with usage attribution enabled. Members use can_view_own_usage instead. False with no matching denied_reasons key means unknown or unavailable guidance. This does not authorize a read.
2137
2327
  */
2138
2328
  can_view_team_usage: boolean;
2329
+ /**
2330
+ * Whether to offer `project=unallocated` on GET /api/billing/usage/timeseries. True only where that route accepts it: a team workspace with Projects on, for an actor who may read the whole workspace's usage. This does not authorize a read.
2331
+ */
2332
+ can_view_unallocated_usage: boolean;
2333
+ /**
2334
+ * - Answers: should the client show the workspace's credit balance and its
2335
+ * workspace-wide usage totals, and request GET /api/billing/balance at
2336
+ * all?
2337
+ * - True: the user is a member of the workspace and is an owner or a
2338
+ * Workspace admin; or the workspace is personal; or Projects is not
2339
+ * enabled for the workspace, where every member keeps them.
2340
+ * - False: explained by denied_reasons.can_view_workspace_usage.
2341
+ * - Not: the user's own usage, which every member keeps: an ordinary
2342
+ * member's usage reads answer with their own rows. Not whole-workspace
2343
+ * per-person analytics (can_view_team_usage), top-up (can_top_up) or
2344
+ * billing management (can_manage_billing). Independent of tier,
2345
+ * subscription status and billing provisioning. Not authorization: the
2346
+ * balance route refuses on the same rule itself.
2347
+ * - False when: the user is not a member, or is an ordinary member (neither
2348
+ * owner nor Workspace admin) of a team workspace where Projects is
2349
+ * enabled.
2350
+ *
2351
+ */
2352
+ can_view_workspace_usage: boolean;
2139
2353
  };
2140
2354
  /**
2141
2355
  * Effective billing UI guidance for one authenticated user and workspace.
2142
2356
  */
2143
2357
  export type BillingCapabilitiesResponse = {
2358
+ /**
2359
+ * Whether billing-web may offer hosted methods for a one-off top-up.
2360
+ * Evaluated for the authenticated actor; missing or failed evaluation
2361
+ * is false. Does not grant payment permission or guarantee wallet availability.
2362
+ *
2363
+ */
2364
+ billing_web_topup_hosted_methods?: boolean;
2144
2365
  /**
2145
2366
  * Whether auto top-up is rolled out to this user: the auto_top_up_enabled
2146
2367
  * rollout flag, evaluated by ingest the same way GET /api/features
@@ -2487,7 +2708,7 @@ export type BillingCapabilityDenials = {
2487
2708
  /**
2488
2709
  * Why can_invite_members is false. Present only when that capability is false; absent means no recognized explanation, never permission. This does not authorize the action or explain a sibling capability. First reached wins in the order below; mutually exclusive lifecycle statuses do not compete.
2489
2710
  * - not_a_member: The actor is not a workspace member.
2490
- * - not_workspace_owner: The actor does not have the workspace owner role.
2711
+ * - not_workspace_owner: The actor is neither a workspace owner nor a Workspace admin.
2491
2712
  * - invite_capacity_reached: No invitation capacity is available, including a failed capacity read.
2492
2713
  *
2493
2714
  */
@@ -2534,7 +2755,7 @@ export type BillingCapabilityDenials = {
2534
2755
  /**
2535
2756
  * Why can_manage_members is false. Present only when that capability is false; absent means no recognized explanation, never permission. This does not authorize the action or explain a sibling capability. First reached wins in the order below; mutually exclusive lifecycle statuses do not compete.
2536
2757
  * - not_a_member: The actor is not a workspace member.
2537
- * - not_workspace_owner: The actor does not have the workspace owner role.
2758
+ * - not_workspace_owner: The actor is neither a workspace owner nor a Workspace admin.
2538
2759
  *
2539
2760
  */
2540
2761
  can_manage_members?: 'not_a_member' | 'not_workspace_owner';
@@ -2644,7 +2865,7 @@ export type BillingCapabilityDenials = {
2644
2865
  * - not_a_member: The actor is not a workspace member.
2645
2866
  * - not_workspace_owner: The actor is a member whose role is not owner.
2646
2867
  * - creator_only_provisioning: Only the creator can act on this personal workspace's billing until its billing identity is provisioned.
2647
- * - no_subscription: The workspace has no subscription, so it has no billing period to budget over.
2868
+ * - no_subscription: Setting a budget requires a paid subscription.
2648
2869
  * - free_plan: The plan is FREE, whose usage is not charged spend.
2649
2870
  * - subscription_ended: The subscription has stopped for good, ended or canceled with no end date ahead.
2650
2871
  * - subscription_not_started: The subscription is scheduled and has not started.
@@ -2766,13 +2987,20 @@ export type BillingCapabilityDenials = {
2766
2987
  */
2767
2988
  can_view_own_usage?: 'not_a_member' | 'usage_attribution_unavailable';
2768
2989
  /**
2769
- * Why can_view_pending_invites is false. Permission refusals precede unavailable feature or entitlement facts; first reached wins in enum order. A present key implies refusal. Missing means unknown, including a disabled team-workspaces feature or an unavailable membership read, never permission. This explains only this capability and does not authorize a mutation.
2990
+ * Why can_view_pending_invites is false. not_workspace_owner here means the actor is neither a workspace owner nor a Workspace admin. Permission refusals precede unavailable feature or entitlement facts; first reached wins in enum order. A present key implies refusal. Missing means unknown, including a disabled team-workspaces feature or an unavailable membership read, never permission. This explains only this capability and does not authorize a mutation.
2770
2991
  */
2771
2992
  can_view_pending_invites?: 'not_a_member' | 'not_workspace_owner';
2772
2993
  /**
2773
2994
  * Why can_view_team_usage is false. Disabled usage attribution emits usage_attribution_unavailable. Permission refusals precede unavailable feature or entitlement facts; first reached wins in enum order. A present key implies refusal. Missing means unknown, including a disabled team-workspaces feature or an unavailable membership read, never permission. This explains only this capability and does not authorize a mutation.
2774
2995
  */
2775
2996
  can_view_team_usage?: 'not_a_member' | 'not_workspace_owner' | 'usage_attribution_unavailable';
2997
+ /**
2998
+ * Why can_view_workspace_usage is false. Present only when that capability is false; absent means no recognized explanation, never permission. This does not authorize the action or explain a sibling capability. First reached wins in the order below; mutually exclusive lifecycle statuses do not compete.
2999
+ * - not_a_member: The actor is not a workspace member.
3000
+ * - not_workspace_owner: The actor is neither a workspace owner nor a Workspace admin, in a team workspace where Projects is enabled.
3001
+ *
3002
+ */
3003
+ can_view_workspace_usage?: 'not_a_member' | 'not_workspace_owner';
2776
3004
  };
2777
3005
  /**
2778
3006
  * Identifies capability values currently using safe rollout defaults
@@ -2920,7 +3148,7 @@ export type BillingHandoffCheckoutRequest = {
2920
3148
  */
2921
3149
  export type BillingHandoffCreateRequest = {
2922
3150
  /**
2923
- * Credit amount the top-up checkout opens with, in cents. Whole dollars within the manual top-up limits (`min_topup_cents` to `max_topup_cents` on GET /api/billing/balance). Allowed only with intent top-up, else 400 INVALID_REQUEST; omitted, billing-web uses its default. Sent in the entry URL's query after intent. Not a credential; the checkout validates the amount again.
3151
+ * Optional whole-dollar prefill between the minimum and the $10,000 hard maximum. The receiver quotes and enforces the workspace's current `max_topup_cents`; issuing a handoff does not authorize a purchase. Allowed only with intent top-up, else 400 INVALID_REQUEST; omitted, billing-web uses its default. Sent in the entry URL's query after intent. Not a credential.
2924
3152
  */
2925
3153
  amount_cents?: number;
2926
3154
  /**
@@ -3306,6 +3534,30 @@ export type BillingPlansResponse = {
3306
3534
  subscription_payment_recovery?: SubscriptionPaymentRecovery;
3307
3535
  team_credit_stops?: TeamCreditStops;
3308
3536
  };
3537
+ /**
3538
+ * Answers "should this client show and apply a promotion right now?". Non-null means yes: show the offer, put `promotion_code` on plan links and follow `auto_apply` at checkout. Null means no promotion is running, and clients show and apply nothing. It is not a statement about the caller: it does not say this visitor or workspace qualifies, and a code restricted to first-time customers is still refused at checkout for anyone else.
3539
+ */
3540
+ export type BillingPromotion = {
3541
+ /**
3542
+ * Answers "may checkout apply `promotion_code` from the link without a click?". True means apply it on load, once per checkout, and respect the customer removing it. False means fill it in and wait for the customer. It is not a promise that Stripe accepts the code for this customer.
3543
+ */
3544
+ auto_apply: boolean;
3545
+ /**
3546
+ * When Stripe stops accepting the code, for display ("ends Monday"). Null when the code has no expiry. Always present. Clients do not need to hide the offer at this time themselves: `promotion` turns null when the code expires.
3547
+ */
3548
+ ends_at: string | null;
3549
+ /**
3550
+ * The discount of the coupon behind the code, as a percentage (20 for 20% off), for display. Read from Stripe, so the number clients show is the one checkout applies. Null when the coupon takes a fixed amount off: show the offer without a number. Always present. It is not the price the customer pays, and it says nothing about which plans or billing periods the coupon covers.
3551
+ */
3552
+ percent_off: number | null;
3553
+ /**
3554
+ * The customer-facing Stripe promotion code of the running campaign. Clients put it on plan links and may show it. It is the only code checkout may apply without a click; any other code in a link waits for the customer to apply it.
3555
+ */
3556
+ promotion_code: string;
3557
+ } | null;
3558
+ export type BillingPromotionResponse = {
3559
+ promotion: BillingPromotion;
3560
+ };
3309
3561
  /**
3310
3562
  * Payment lifecycle status
3311
3563
  */
@@ -3456,7 +3708,7 @@ export type BillingStatusResponse = {
3456
3708
  */
3457
3709
  usage_period_end?: string;
3458
3710
  /**
3459
- * Start of the billing period that current-period usage views and workspace budgets are counted over. Together with usage_period_end it answers "which range is this period's usage?"; request usage for exactly this pair so the usage page and a budget's spend show the same number. On an annual plan it is the monthly anniversary, so it must not be read as the plan's renewal term (that is current_period_start and renewal_date). On a monthly plan the two pairs usually agree, but render each as received: they are resolved separately and can differ for a subscription whose stored period is missing or out of date. Present exactly when usage_period_end is: omitted when the workspace has no subscription, or its subscription is scheduled, ended, or canceled and past its end.
3711
+ * Start of the billing period that current-period usage views and workspace budgets are counted over. Together with usage_period_end it answers "which range is this period's usage?"; request usage for exactly this pair so the usage page and a budget's spend show the same number. On an annual plan it is the monthly anniversary, so it must not be read as the plan's renewal term (that is current_period_start and renewal_date). On a monthly plan the two pairs usually agree, but render each as received: they are resolved separately and can differ for a subscription whose stored period is missing or out of date. Present exactly when usage_period_end is: omitted when the workspace has no subscription, or its subscription is scheduled, ended, or canceled and past its end. Budgets then use the UTC calendar month when the absence of a cycle is known.
3460
3712
  */
3461
3713
  usage_period_start?: string;
3462
3714
  };
@@ -3477,7 +3729,7 @@ export type BillingTaxId = {
3477
3729
  value: string;
3478
3730
  };
3479
3731
  /**
3480
- * A budget with its spend in the workspace's current billing period. Amounts come in credits and in micro-USD; a client shows credits as received and never converts.
3732
+ * A budget with its spend in the workspace's current billing period. This is the subscription cycle or, when there is no cycle, the UTC calendar month. Only a workspace whose subscription is unresolved has no budget period. Amounts come in credits and in micro-USD; a client shows credits as received and never converts.
3481
3733
  *
3482
3734
  */
3483
3735
  export type Budget = {
@@ -3575,7 +3827,7 @@ export type Budget = {
3575
3827
  percent_used: number;
3576
3828
  repeat: BudgetRepeat;
3577
3829
  /**
3578
- * When spend next resets to 0: the end of the current billing period. Null when the workspace has no billing period.
3830
+ * When spend next resets to 0: the end of the current billing period. With no subscription cycle, spend resets at 00:00 UTC on the first of the next month. Null when the budget period could not be resolved.
3579
3831
  *
3580
3832
  */
3581
3833
  resets_at: string | null;
@@ -3676,6 +3928,68 @@ export type BudgetCreateRequest = {
3676
3928
  scope_id: string;
3677
3929
  scope_kind: BudgetScopeKind;
3678
3930
  };
3931
+ /**
3932
+ * A selected job that stayed where it was, and why.
3933
+ */
3934
+ export type BudgetHeldJobNotResumed = {
3935
+ /**
3936
+ * The budget that still refuses the job, present for `budget_exceeded` when billing named one. The same object a refused submit carries: an owner gets its amounts, anyone else gets only `scope_kind`, `resets_at` and `set_by`.
3937
+ */
3938
+ budget?: {
3939
+ [key: string]: unknown;
3940
+ };
3941
+ /**
3942
+ * The billing policy's reason, present for `budget_exceeded`, `budget_check_unavailable` and `spend_denied`. For a budget it is `workspace_cap_exceeded`, `user_cap_exceeded` or `api_key_cap_exceeded`.
3943
+ */
3944
+ denied_reason?: string;
3945
+ job_id: string;
3946
+ /**
3947
+ * Why the job did not move. One value per job, the first that applies:
3948
+ * - `not_found`: no such job in this workspace, it is another member's and the caller is not an owner, or it is in a project the caller may not queue work in. They look the same on purpose.
3949
+ * - `not_held`: the job is not in `held_budget`; it was already resumed, cancelled or finished.
3950
+ * - `budget_exceeded`: a hard budget that applies to the job is still used up. `denied_reason` and `budget` say which.
3951
+ * - `budget_check_unavailable`: the budget check could not be made, or billing answered without enforcing budgets. Nothing is wrong with the job; retry shortly.
3952
+ * - `spend_denied`: the workspace may not spend for another reason, named in `denied_reason` (for example `no_funds`).
3953
+ * - `no_free_slot`: the job's submitter or the workspace is at its concurrent-jobs limit, or the queue was busy. Retry when a running job ends.
3954
+ * - `failed`: the server could not move the job. Retry.
3955
+ *
3956
+ */
3957
+ reason: 'not_found' | 'not_held' | 'budget_exceeded' | 'budget_check_unavailable' | 'spend_denied' | 'no_free_slot' | 'failed';
3958
+ };
3959
+ /**
3960
+ * Which held jobs to resume. An empty body resumes every held job the caller may resume.
3961
+ */
3962
+ export type BudgetHeldJobsResumeRequest = {
3963
+ /**
3964
+ * `next_cursor` from the previous answer, to continue a resume of every held job where that call stopped. Ignored when `job_ids` is given. Opaque; send it back unchanged.
3965
+ */
3966
+ cursor?: string;
3967
+ /**
3968
+ * The jobs to resume. Absent or empty means every held job the caller may resume: the whole workspace's for an owner, their own for any other member.
3969
+ */
3970
+ job_ids?: Array<string>;
3971
+ };
3972
+ /**
3973
+ * The outcome of one resume call. Every selected job is in exactly one of the two lists.
3974
+ */
3975
+ export type BudgetHeldJobsResumeResult = {
3976
+ /**
3977
+ * Answers "are there held jobs this call did not look at?". True only for a call with no `job_ids` that stopped at its 100-job limit; call again with `cursor` set to `next_cursor` to continue. It does not say whether the jobs in `not_resumed` can be resumed later; read their `reason` for that.
3978
+ */
3979
+ more_held: boolean;
3980
+ /**
3981
+ * Present exactly when `more_held` is true. Send it as `cursor` to look at the held jobs after the ones this call looked at. It moves past jobs that stayed held, so repeating the call without it looks at the same jobs again.
3982
+ */
3983
+ next_cursor?: string;
3984
+ /**
3985
+ * Jobs that did not move, each with the reason. `[]`, never `null`.
3986
+ */
3987
+ not_resumed: Array<BudgetHeldJobNotResumed>;
3988
+ /**
3989
+ * Jobs that left `held_budget` and are queued again. `[]`, never `null`.
3990
+ */
3991
+ resumed: Array<string>;
3992
+ };
3679
3993
  export type BudgetHistory = {
3680
3994
  changes: Array<BudgetChange>;
3681
3995
  };
@@ -3701,6 +4015,24 @@ export type BudgetList = {
3701
4015
  */
3702
4016
  auto_top_up_conflict: boolean;
3703
4017
  budgets: Array<Budget>;
4018
+ /**
4019
+ * Answers one UI question: which Budgets layout does this caller get?
4020
+ * `owner`: `budgets` is every live budget of the workspace. Show the
4021
+ * full list.
4022
+ * `member`: `budgets` is only the budget set on the caller, if there
4023
+ * is one. Show the member view.
4024
+ * It names the list this response carries, so the layout and the
4025
+ * list always agree. Not permission to edit: `can_set_budgets` on
4026
+ * `GET /api/billing/capabilities` answers that, and an `owner` viewer
4027
+ * can still be refused a write, for example on a plan without
4028
+ * budgets. Render it as received; do not rebuild it from the role or
4029
+ * from the capabilities.
4030
+ * Absent while billing-api does not send it yet (a rollout with an
4031
+ * older billing-api): ingest never guesses it. A client then falls
4032
+ * back to the layout the capabilities imply.
4033
+ *
4034
+ */
4035
+ viewer?: 'owner' | 'member';
3704
4036
  };
3705
4037
  /**
3706
4038
  * `soft` alerts at its thresholds and never refuses spend. `hard` also refuses spend once the limit is reached; Enterprise plans only.
@@ -4205,6 +4537,57 @@ export type CccSiteTagUsageItem = {
4205
4537
  */
4206
4538
  tag: string;
4207
4539
  };
4540
+ /**
4541
+ * One app page at its Draft head, with only what a Desktop card shows.
4542
+ */
4543
+ export type CccStaffApp = {
4544
+ description: string;
4545
+ /**
4546
+ * The Draft head's compatibility.desktop.draft_page, returned only where catalog-api has draft links turned on (staging and production), and there present when it is an https address on a comfy-website-preview-pr-<n>.vercel.app preview deploy whose path starts with /apps/<slug>/, with no query or fragment. Absent when draft links are off, and when unset or anything else.
4547
+ */
4548
+ draft_page?: string;
4549
+ /**
4550
+ * Show on the Hub in the Draft head; false when unset.
4551
+ */
4552
+ enabled: boolean;
4553
+ /**
4554
+ * The Draft head's compatibility.website.href when it is a path under /hub/ on comfy.org, for example /hub/apps/reshoot/. Absent when unset or anything else.
4555
+ */
4556
+ hub_page?: string;
4557
+ /**
4558
+ * The Draft head lists desktop_starters in available_surfaces.
4559
+ */
4560
+ on_desktop: boolean;
4561
+ /**
4562
+ * The Draft head lists hub in available_surfaces.
4563
+ */
4564
+ on_hub: boolean;
4565
+ /**
4566
+ * Path under /api/v1/catalog of the card picture, /staff-apps/{uid}/picture/{version}. Absent when the page has no image picture.
4567
+ */
4568
+ picture?: string;
4569
+ /**
4570
+ * Empty when the page has no address yet.
4571
+ */
4572
+ slug: string;
4573
+ /**
4574
+ * As on /pages. It does not say whether the app is on the public Desktop list.
4575
+ */
4576
+ status: 'not_live' | 'unpublished' | 'hidden' | 'scheduled' | 'live';
4577
+ title: string;
4578
+ uid: string;
4579
+ };
4580
+ /**
4581
+ * One page of the comfy.org staff app list.
4582
+ */
4583
+ export type CccStaffAppsPage = {
4584
+ has_more: boolean;
4585
+ items: Array<CccStaffApp>;
4586
+ /**
4587
+ * Opaque; send it back with the same limit.
4588
+ */
4589
+ next_cursor?: string;
4590
+ };
4208
4591
  export type CccStaffPermissions = {
4209
4592
  account_id: string;
4210
4593
  /**
@@ -4669,10 +5052,12 @@ export type CreateSessionResponse = {
4669
5052
  */
4670
5053
  export type CreateTopupCheckoutRequest = {
4671
5054
  /**
4672
- * Amount to charge in cents, before any promotion code the customer
4673
- * enters. Whole dollars only, from $5.00 to `max_topup_cents` on GET /api/billing/balance. The
4674
- * credits granted are derived server-side from this amount and
4675
- * cannot be set by the caller.
5055
+ * Amount to charge in cents, before any discount: whole dollars from
5056
+ * the minimum up to this workspace's `max_topup_cents` on GET
5057
+ * /api/billing/balance. The server enforces the maximum (400
5058
+ * `INVALID_AMOUNT` with `details.reason` `above_max`); there is no
5059
+ * schema maximum. The credits granted are derived server-side from
5060
+ * this amount and cannot be set by the caller.
4676
5061
  *
4677
5062
  */
4678
5063
  amount_cents: number;
@@ -4729,7 +5114,7 @@ export type CreateTopupQuoteRequest = {
4729
5114
  */
4730
5115
  export type CreateTopupRequest = {
4731
5116
  /**
4732
- * Amount to charge and grant as credits (in cents). Minimum $5.00; maximum `max_topup_cents` on GET /api/billing/balance (400 INVALID_AMOUNT above it).
5117
+ * Amount to charge and grant as credits (in cents). Minimum $5.00; maximum this workspace's `max_topup_cents` on GET /api/billing/balance (400 INVALID_AMOUNT with `details.reason` `above_max` above it).
4733
5118
  */
4734
5119
  amount_cents: number;
4735
5120
  /**
@@ -4956,6 +5341,15 @@ export type DeployToCloudError = {
4956
5341
  */
4957
5342
  message?: string;
4958
5343
  };
5344
+ /**
5345
+ * The version cut with the model added.
5346
+ */
5347
+ export type DeploymentBuildModelRelease = {
5348
+ /**
5349
+ * comfy-builder's id of the new Release.
5350
+ */
5351
+ releaseId: string;
5352
+ };
4959
5353
  /**
4960
5354
  * Which of the posted node types each of the workspace's deployments, and Comfy Cloud, does not have.
4961
5355
  */
@@ -4975,6 +5369,45 @@ export type DeploymentCompatibilityRequest = {
4975
5369
  */
4976
5370
  node_types: Array<string>;
4977
5371
  };
5372
+ /**
5373
+ * One model file added to a deployment: comfy-deploy's DeploymentModel (an entry of its GET /v1/deployments/{id}/models, and its POST 202), passed through as written; the fields are comfy-deploy's.
5374
+ */
5375
+ export type DeploymentModel = {
5376
+ /**
5377
+ * Why the file could not be added, for the log; set once the entry has failed, and kept if it is then removed. Not for display: the editor says "<file> was not added to this deployment. Remove it and add it again."
5378
+ */
5379
+ failure?: string;
5380
+ /**
5381
+ * The file's name in that folder.
5382
+ */
5383
+ filename: string;
5384
+ /**
5385
+ * The entry's id, the model_id that DELETE .../deployments/{deployment_id}/models/{model_id} takes. Not the upload's blobId.
5386
+ */
5387
+ id: string;
5388
+ /**
5389
+ * The file's size as its upload declared it.
5390
+ */
5391
+ sizeBytes: number;
5392
+ /**
5393
+ * `adding` until the deployment's workers can use the file, `ready` once they can, `failed` where it could not be added, and `removing` once a removal was asked.
5394
+ */
5395
+ status: 'adding' | 'ready' | 'failed' | 'removing';
5396
+ /**
5397
+ * The model folder the file is in, for example `loras` or `checkpoints`.
5398
+ */
5399
+ type: string;
5400
+ };
5401
+ /**
5402
+ * comfy-deploy's DeploymentModelList (its GET /v1/deployments/{id}/models 200), passed through as written: every model file added to the deployment, oldest first.
5403
+ */
5404
+ export type DeploymentModelList = {
5405
+ /**
5406
+ * Always true: adding a model file is on for every caller, so the editor shows its Add button. Not whether this deployment can take the file now: the add still answers its own refusal.
5407
+ */
5408
+ addEnabled: boolean;
5409
+ models: Array<DeploymentModel>;
5410
+ };
4978
5411
  /**
4979
5412
  * comfy-builder's BlobUpload (its POST /v1/blobs 201), passed through as written; the fields are comfy-builder's.
4980
5413
  */
@@ -5179,6 +5612,15 @@ export type DesktopLoginCodeRedeemResponse = {
5179
5612
  */
5180
5613
  status: 'redeemed';
5181
5614
  };
5615
+ /**
5616
+ * A one-time Firebase custom token for the Desktop grant's user.
5617
+ */
5618
+ export type DesktopWebSessionResponse = {
5619
+ /**
5620
+ * Firebase custom token. Valid for one hour; sign in with it at once.
5621
+ */
5622
+ custom_token: string;
5623
+ };
5182
5624
  /**
5183
5625
  * First rejected op in an abort-remainder batch.
5184
5626
  */
@@ -5289,7 +5731,7 @@ export type ErrorResponse = {
5289
5731
  */
5290
5732
  denied_reasons?: WorkspaceCreationDenials;
5291
5733
  /**
5292
- * Optional open object carrying structured, machine-readable context about the error (e.g. offending field names, validation specifics). Absent for most errors; consumers must not assume any particular shape.
5734
+ * Optional open object carrying structured, machine-readable context about the error (e.g. offending field names, validation specifics). Absent for most errors; consumers must not assume any particular shape. One documented key: a manual top-up refused because the amount is above the workspace's `max_topup_cents` answers 400 `INVALID_AMOUNT` with `details.reason` `above_max`; below-minimum and part-dollar refusals carry no reason.
5293
5735
  */
5294
5736
  details?: {
5295
5737
  [key: string]: unknown;
@@ -5359,6 +5801,10 @@ export type ExchangeTokenResponse = {
5359
5801
  * Detailed execution error information from ComfyUI
5360
5802
  */
5361
5803
  export type ExecutionError = {
5804
+ /**
5805
+ * Stable frontend error-catalog identity supplied by the Cloud error producer. Absent while a producer has not migrated; clients must retain their message matcher for an absent or unknown id.
5806
+ */
5807
+ catalog_id?: string;
5362
5808
  /**
5363
5809
  * Input values at time of failure (empty object if not available)
5364
5810
  */
@@ -5379,6 +5825,12 @@ export type ExecutionError = {
5379
5825
  * Python exception type (e.g., "RuntimeError")
5380
5826
  */
5381
5827
  exception_type: string;
5828
+ /**
5829
+ * Present when ComfyUI rejected the whole prompt at validation (exception_type ValidationError): the rejected nodes, keyed by node id, in the shape ComfyUI's /prompt returns and cleaned and capped like a prompt_outputs_skipped event's node_errors.
5830
+ */
5831
+ node_errors?: {
5832
+ [key: string]: PromptOutputsSkippedNodeError;
5833
+ };
5382
5834
  /**
5383
5835
  * ID of the node that failed
5384
5836
  */
@@ -6140,13 +6592,49 @@ export type JobAssetsResponse = {
6140
6592
  pagination: PaginationInfo;
6141
6593
  };
6142
6594
  /**
6143
- * Response for POST /api/jobs/{job_id}/cancel. Returned on both fresh cancels and idempotent no-ops.
6595
+ * The facts the queue shows for a job held by a budget decision: why it is held, the budget that stopped it, and whether the caller may resume it. The client renders these as received and derives none of them from the caller's role.
6144
6596
  */
6145
- export type JobCancelResponse = {
6597
+ export type JobBudgetHold = {
6146
6598
  /**
6147
- * True when a cancel event was successfully dispatched by this call.
6148
- * False when the job was already in a terminal or cancelling state,
6149
- * in which case the call is a no-op (still 200 — idempotent).
6599
+ * The budget that stopped the job, as billing reported it when the job was held. Later changes to the budget or its spend are not reflected here; read `GET /api/billing/budgets` for the current figures. Absent when the hold names no budget, as with `budget_check_unavailable`.
6600
+ */
6601
+ budget?: JobHeldBudget;
6602
+ /**
6603
+ * Answers one UI question: may this caller press Resume on this job.
6604
+ *
6605
+ * - True: the job is in the caller's current workspace, and the
6606
+ * caller either submitted it or is an Owner of that workspace.
6607
+ * For a job in a project other than the default, the project
6608
+ * must also take new runs from the caller.
6609
+ * - False: anyone else who can read the job, such as a project
6610
+ * member reading another member's run, or staff reading a job in
6611
+ * a workspace they are not signed in to. Also false for everyone
6612
+ * while the job's project is read-only because the workspace's
6613
+ * plan does not include Projects, and when the project's state
6614
+ * could not be read.
6615
+ *
6616
+ * Not a promise that the resume goes through: resuming checks the
6617
+ * budget again and the job stays held while the budget still
6618
+ * refuses it. Not permission to change the budget (that is
6619
+ * `can_set_budgets` on `GET /api/billing/capabilities`), to manage
6620
+ * members, or to cancel the job. It is about this job only and says
6621
+ * nothing about other held jobs in the workspace.
6622
+ *
6623
+ */
6624
+ can_resume: boolean;
6625
+ /**
6626
+ * Billing's reason for the hold, recorded when the job was held and not updated afterwards. A used-up hard budget is `workspace_cap_exceeded`, `user_cap_exceeded` or `api_key_cap_exceeded`, which names whose budget stopped the job. `budget_check_unavailable` is a hold made because the budget could not be checked; it does not mean a budget is used up. Treat any other value as a hold with no further explanation.
6627
+ */
6628
+ reason: string;
6629
+ };
6630
+ /**
6631
+ * Response for POST /api/jobs/{job_id}/cancel. Returned on both fresh cancels and idempotent no-ops.
6632
+ */
6633
+ export type JobCancelResponse = {
6634
+ /**
6635
+ * True when a cancel event was successfully dispatched by this call.
6636
+ * False when the job was already in a terminal or cancelling state,
6637
+ * in which case the call is a no-op (still 200 — idempotent).
6150
6638
  *
6151
6639
  */
6152
6640
  cancelled: boolean;
@@ -6180,6 +6668,10 @@ export type JobDeployment = {
6180
6668
  * Full job details including workflow and outputs
6181
6669
  */
6182
6670
  export type JobDetailResponse = {
6671
+ /**
6672
+ * Why the job is held and whether the caller may resume it. Present only while `status` is `held_budget`; absent for every other status.
6673
+ */
6674
+ budget_hold?: JobBudgetHold;
6183
6675
  /**
6184
6676
  * Job creation timestamp (Unix timestamp in milliseconds)
6185
6677
  */
@@ -6290,9 +6782,9 @@ export type JobDetailResponse = {
6290
6782
  */
6291
6783
  queue_reason?: 'concurrency_limit' | 'capacity';
6292
6784
  /**
6293
- * User-friendly job status
6785
+ * Job status for display. A held_budget job is paused by a budget decision, occupies no worker slot and requires explicit resume or cancellation.
6294
6786
  */
6295
- status: 'pending' | 'in_progress' | 'completed' | 'failed' | 'cancelled';
6787
+ status: 'pending' | 'in_progress' | 'completed' | 'failed' | 'cancelled' | 'held_budget';
6296
6788
  /**
6297
6789
  * Last update timestamp (Unix timestamp in milliseconds)
6298
6790
  */
@@ -6346,6 +6838,10 @@ export type JobDetailResponse = {
6346
6838
  * Lightweight job data for list views (workflow and full outputs excluded)
6347
6839
  */
6348
6840
  export type JobEntry = {
6841
+ /**
6842
+ * Why the job is held and whether the caller may resume it. Present only while `status` is `held_budget`; absent for every other status.
6843
+ */
6844
+ budget_hold?: JobBudgetHold;
6349
6845
  /**
6350
6846
  * Job creation timestamp (Unix timestamp in milliseconds)
6351
6847
  */
@@ -6393,9 +6889,9 @@ export type JobEntry = {
6393
6889
  */
6394
6890
  project_id?: string;
6395
6891
  /**
6396
- * User-friendly job status
6892
+ * Job status for display. A held_budget job is paused by a budget decision, occupies no worker slot and requires explicit resume or cancellation.
6397
6893
  */
6398
- status: 'pending' | 'in_progress' | 'completed' | 'failed' | 'cancelled';
6894
+ status: 'pending' | 'in_progress' | 'completed' | 'failed' | 'cancelled' | 'held_budget';
6399
6895
  /**
6400
6896
  * UUID identifying the workflow graph definition
6401
6897
  */
@@ -6426,6 +6922,51 @@ export type JobExecutionMetaEntry = {
6426
6922
  real_node_id?: string;
6427
6923
  [key: string]: unknown;
6428
6924
  };
6925
+ /**
6926
+ * A budget as billing reported it when a job was held. Every caller who can read the job gets `scope_kind`, `resets_at` and `set_by`. The identifiers, the mode and the amounts are present only for an Owner of the job's workspace; their absence means the caller may not see them, never zero.
6927
+ */
6928
+ export type JobHeldBudget = {
6929
+ /**
6930
+ * Budget ID. Owner only.
6931
+ */
6932
+ id?: string;
6933
+ /**
6934
+ * The limit in credits. Owner only.
6935
+ */
6936
+ limit_credits?: number;
6937
+ /**
6938
+ * The limit in millionths of a US dollar. Owner only.
6939
+ */
6940
+ limit_micro_usd?: number;
6941
+ /**
6942
+ * The budget's mode when the job was held, `hard` for a budget that stops spend. Owner only.
6943
+ */
6944
+ mode?: string;
6945
+ /**
6946
+ * When the budget's current period ends and its spend starts again from zero.
6947
+ */
6948
+ resets_at: string;
6949
+ /**
6950
+ * The workspace ID, the member's user ID or the API key's prefix, by `scope_kind`. Owner only.
6951
+ */
6952
+ scope_id?: string;
6953
+ /**
6954
+ * What the budget limits: `workspace`, `member` or `api_key`.
6955
+ */
6956
+ scope_kind: string;
6957
+ /**
6958
+ * ID of the user who last set the budget.
6959
+ */
6960
+ set_by: string;
6961
+ /**
6962
+ * Spend counted against the limit when the job was held, in credits. Owner only.
6963
+ */
6964
+ spent_credits?: number;
6965
+ /**
6966
+ * Spend counted against the limit when the job was held, in millionths of a US dollar. Owner only.
6967
+ */
6968
+ spent_micro_usd?: number;
6969
+ };
6429
6970
  /**
6430
6971
  * An asset produced by a job, enriched with the per-output node context
6431
6972
  * (`node_id`, `output_key`, `output_index`) correlated from the job's
@@ -6500,9 +7041,9 @@ export type JobStatusResponse = {
6500
7041
  */
6501
7042
  last_state_update?: string;
6502
7043
  /**
6503
- * Current job status
7044
+ * Raw job lifecycle state. A held_budget job is paused until explicitly resumed or cancelled. Historical schema values waiting_to_dispatch, pending, in_progress and completed are retained for client compatibility.
6504
7045
  */
6505
- status: 'waiting_to_dispatch' | 'pending' | 'in_progress' | 'completed' | 'error' | 'cancelled';
7046
+ status: 'submitted' | 'preprocessing' | 'queued_limited' | 'queued_waiting' | 'held_budget' | 'allocated' | 'preparing' | 'pending_execution' | 'executing' | 'executed' | 'cancel_requested' | 'cancel_pending' | 'erroring' | 'cancelling_preparing' | 'cancelled' | 'non_retryable_error' | 'error' | 'lost' | 'success' | 'waiting_to_dispatch' | 'pending' | 'in_progress' | 'completed';
6506
7047
  /**
6507
7048
  * When the job was last updated
6508
7049
  */
@@ -8011,6 +8552,29 @@ export type PromptOutputsSkippedValidationError = {
8011
8552
  message?: string;
8012
8553
  type?: string;
8013
8554
  };
8555
+ /**
8556
+ * Payment or hard-budget refusal for ComfyUI prompt execution.
8557
+ */
8558
+ export type PromptPaymentRequired = {
8559
+ /**
8560
+ * All exhausted hard budgets, visible to workspace Owners.
8561
+ */
8562
+ blocking_budgets?: Array<SpendBudgetDetail>;
8563
+ budget?: SpendBudgetDetail;
8564
+ /**
8565
+ * The billing policy reason for a hard-budget refusal.
8566
+ */
8567
+ denied_reason?: string;
8568
+ /**
8569
+ * The existing prompt error payload for this payment refusal.
8570
+ */
8571
+ error?: unknown;
8572
+ /**
8573
+ * For a hard-budget refusal, this is `budget_exceeded`.
8574
+ */
8575
+ error_type?: string;
8576
+ [key: string]: unknown;
8577
+ };
8014
8578
  /**
8015
8579
  * Request body for submitting a ComfyUI workflow prompt for execution.
8016
8580
  */
@@ -8102,6 +8666,32 @@ export type ProviderPolicyEntry = {
8102
8666
  */
8103
8667
  provider_id: string;
8104
8668
  };
8669
+ export type PublicModel = {
8670
+ /**
8671
+ * Path under the models root, as `GET /api/assets` reports it
8672
+ * (e.g. `models/checkpoints/x.safetensors`). Absent when it cannot
8673
+ * be built safely.
8674
+ *
8675
+ */
8676
+ file_path?: string;
8677
+ id: string;
8678
+ /**
8679
+ * The model's file name, as loaders show it.
8680
+ */
8681
+ name: string;
8682
+ /**
8683
+ * Bytes on disk. Absent when never measured, not zero.
8684
+ */
8685
+ size?: number;
8686
+ /**
8687
+ * The public http(s) URL the model was downloaded from, when known.
8688
+ */
8689
+ source_url?: string;
8690
+ tags: Array<string>;
8691
+ };
8692
+ export type PublicModelsResponse = {
8693
+ models: Array<PublicModel>;
8694
+ };
8105
8695
  /**
8106
8696
  * Request body for publishing or updating a workflow on the Hub.
8107
8697
  */
@@ -8215,7 +8805,7 @@ export type QueueInfo = {
8215
8805
  */
8216
8806
  export type QueueManageRequest = {
8217
8807
  /**
8218
- * If true, clear all pending jobs from the queue
8808
+ * If true, cancel the caller’s pending and budget-held jobs in this workspace
8219
8809
  */
8220
8810
  clear?: boolean;
8221
8811
  /**
@@ -8549,6 +9139,21 @@ export type ServerDocFrame = DocSubscribedFrame | DocUpdateFrame | DocResetFrame
8549
9139
  export type SetProjectMemberRequest = {
8550
9140
  role: ProjectRole;
8551
9141
  };
9142
+ /**
9143
+ * The exhausted budget. Workspace Owners also receive its ID, scope ID, mode, and amounts.
9144
+ */
9145
+ export type SpendBudgetDetail = {
9146
+ id?: string;
9147
+ limit_credits?: number;
9148
+ limit_micro_usd?: number;
9149
+ mode?: string;
9150
+ resets_at: string;
9151
+ scope_id?: string;
9152
+ scope_kind: string;
9153
+ set_by: string;
9154
+ spent_credits?: number;
9155
+ spent_micro_usd?: number;
9156
+ };
8552
9157
  /**
8553
9158
  * The deployment a start was asked for, and its status after the ask.
8554
9159
  */
@@ -9174,6 +9779,17 @@ export type TopupQuoteResponse = {
9174
9779
  * The quoted amount, in cents.
9175
9780
  */
9176
9781
  amount_cents: number;
9782
+ /**
9783
+ * The workspace's effective balance (credits minus pending
9784
+ * draft-invoice charges) plus this top-up, in display credits,
9785
+ * rounded to the nearest whole credit. An overrun smaller than half
9786
+ * a credit rounds to 0, so use `runs_paused_after`, not this value's
9787
+ * sign, to tell whether the top-up covers the overrun. Render it as
9788
+ * is; do not recompute it from the balance. Omitted when the balance
9789
+ * cannot be read authoritatively.
9790
+ *
9791
+ */
9792
+ balance_after_credits?: number;
9177
9793
  /**
9178
9794
  * Display credits at 211 per dollar, rounded half up. The top-up
9179
9795
  * itself grants `amount_cents` of balance.
@@ -9200,6 +9816,18 @@ export type TopupQuoteResponse = {
9200
9816
  *
9201
9817
  */
9202
9818
  payment_method_configuration_id?: string;
9819
+ /**
9820
+ * Whether the credit funds gate still holds runs after this top-up
9821
+ * settles: its verdict on the unrounded balance, true when it is zero
9822
+ * or below. A `balance_after_credits` of 0 can come with either value,
9823
+ * because Metronome keeps fractional cents; read this field, not the
9824
+ * sign of `balance_after_credits`. It answers only the funds gate:
9825
+ * Cloud checks subscription eligibility separately, so false does not
9826
+ * promise a run is admitted, and it says nothing about whether the
9827
+ * payment succeeds. Omitted with `balance_after_credits`.
9828
+ *
9829
+ */
9830
+ runs_paused_after?: boolean;
9203
9831
  };
9204
9832
  /**
9205
9833
  * Request body for updating an existing Hub profile.
@@ -9339,6 +9967,10 @@ export type UsageBreakdownRow = {
9339
9967
  export type UsageBucket = {
9340
9968
  cost_micros: number;
9341
9969
  group_key: string;
9970
+ /**
9971
+ * True when the bucket ends within two hours before `as_of`, or after it: usage is still being reported for it, so its cost may grow. Set only in a team workspace where Projects is on; absent elsewhere and on a bucket that is complete.
9972
+ */
9973
+ pending?: boolean;
9342
9974
  period_end: string;
9343
9975
  period_start: string;
9344
9976
  };
@@ -9356,7 +9988,7 @@ export type UsageGroupLabel = {
9356
9988
  */
9357
9989
  deployment_name?: string;
9358
9990
  /**
9359
- * Human-readable name for the key: a person's name, a product line's label, a model's name (`Not specified` for `unspecified`: charges that name no model, such as Agent rounds, partner calls that send none, and Comfy Cloud GPU time), or the key's owner and prefix.
9991
+ * Human-readable name for the key: a person's name, a product line's label, a model's name (`<partner> · Model not reported` for `unspecified/<api_name>`: a partner's calls that send no model; `Not specified` for `unspecified` and for an `unspecified/<api_name>` whose partner is unknown: charges that name no model or partner, such as Agent rounds and Comfy Cloud GPU time), or the key's owner and prefix.
9360
9992
  */
9361
9993
  display_name?: string;
9362
9994
  /**
@@ -9400,7 +10032,7 @@ export type UsageGroupLabel = {
9400
10032
  */
9401
10033
  owner_user_id?: string;
9402
10034
  /**
9403
- * Only for `model` on a ledger-served answer: the partner the model's charges came through, as the partner catalog's provider id (the id workspace provider policy uses). Absent for a model whose charges name no known partner, a deployment and `unspecified`.
10035
+ * Only for `model` on a ledger-served answer: the partner the model's charges came through, as the partner catalog's provider id (the id workspace provider policy uses). Present on `unspecified/<api_name>` when the partner is known. Absent for a model whose charges name no known partner, a deployment and `unspecified`.
9404
10036
  */
9405
10037
  provider?: string;
9406
10038
  /**
@@ -9412,10 +10044,10 @@ export type UsageGroupLabel = {
9412
10044
  * Present, with empty groups, buckets and breakdown, when the requested grouping is not served for this workspace. Render as unavailable, not as zero spend.
9413
10045
  */
9414
10046
  export type UsageNotAvailable = {
9415
- reason: 'no_attribution_source' | 'filter_needs_ledger';
10047
+ reason: 'no_attribution_source' | 'filter_needs_ledger' | 'too_many_deployments' | 'deployments_unavailable';
9416
10048
  };
9417
10049
  /**
9418
- * Mixed units, deliberately. `spend_micros` here (and `cost_micros` on UsageBucket / UsageBreakdownRow) is genuinely MICROS -- 1/1,000,000 of the currency unit -- because it comes from Metronome's usage figures. The `balance` breakdown below is CENTS, and its `*_micros` names are a misnomer; use its `*_cents` fields.
10050
+ * Mixed units, deliberately. `spend_micros` here (and `cost_micros` on UsageBucket / UsageBreakdownRow) is genuinely MICROS -- 1/1,000,000 of the currency unit -- because it comes from Metronome's usage figures. The `balance` breakdown below is CENTS, and its `*_micros` names are a misnomer; use its `*_cents` fields. `balance` is omitted, never null, when it could not be read, the workspace has no billing account, or the caller may not see it (can_view_workspace_usage is false).
9419
10051
  */
9420
10052
  export type UsageSummary = {
9421
10053
  balance?: UsageBalance;
@@ -9622,7 +10254,7 @@ export type WorkflowResponse = {
9622
10254
  latest_version: number;
9623
10255
  name?: string;
9624
10256
  /**
9625
- * The project this workflow belongs to. Where Projects is enabled for the workspace it is always set, and work in the default project carries the default project's ID. Elsewhere it is absent. It does not say whether the workspace uses Projects; read `projects_in_use` on `GET /api/projects` for that.
10257
+ * The project this workflow belongs to, set only for a workflow in a project other than the default. Absent means the workflow is in the workspace's default project, whether or not Projects is enabled for the workspace: the default project's ID is never sent here. Absent does not mean the caller lacks access to the workflow's project. It does not say whether the workspace uses Projects; read `projects_in_use` on `GET /api/projects` for that.
9626
10258
  */
9627
10259
  project_id?: string;
9628
10260
  updated_at: string;
@@ -9869,11 +10501,11 @@ export type WorkspaceDeploymentList = {
9869
10501
  */
9870
10502
  export type WorkspaceMemberCapabilities = {
9871
10503
  /**
9872
- * Whether the actor may switch this member to the other supported role. Requires current owner authority and respects directory management, creator protection and the last-owner guard. Non-creator self-demotion is allowed when another owner remains. Not mutation authorization.
10504
+ * Whether the actor may switch this member to the other supported role. Requires current owner authority and respects directory management, creator protection and the last-owner guard. Non-creator self-demotion is allowed when another owner remains. Always false for a Workspace admin, who changes no role. It does not answer whether the actor may set or clear this member's `workspace_admin`; only an owner may. Not mutation authorization.
9873
10505
  */
9874
10506
  can_change_role: boolean;
9875
10507
  /**
9876
- * Whether the actor may remove this member. Requires current owner authority, refuses self-removal and protects the creator. Directory management alone does not refuse the existing removal route. Not permission to leave the workspace; use can_leave_workspace.
10508
+ * Whether the actor may remove this member. True for a current owner, and for a Workspace admin when this member is an ordinary member: an admin is never offered an owner or another Workspace admin. Refuses self-removal and protects the creator. Directory management alone does not refuse the existing removal route. Not permission to change this member's role (can_change_role) and not permission to leave the workspace; use can_leave_workspace.
9877
10509
  */
9878
10510
  can_remove: boolean;
9879
10511
  /**
@@ -9926,6 +10558,10 @@ export type WorkspaceWithRole = {
9926
10558
  * Represents a user-owned asset (image, video, or other generated output).
9927
10559
  */
9928
10560
  export type AssetWritable = {
10561
+ /**
10562
+ * Set only on a `workspace_library` listing: true when the model policy of the Release that the caller's deployment runs (its own pick or the workspace default) blocks this model, so a Run that names it is refused. Absent when the policy allows it, when there is no policy, and on every other listing.
10563
+ */
10564
+ blocked_by_model_policy?: boolean;
9929
10565
  /**
9930
10566
  * Timestamp when the asset was created
9931
10567
  */
@@ -9983,7 +10619,7 @@ export type AssetWritable = {
9983
10619
  */
9984
10620
  project_id?: string;
9985
10621
  /**
9986
- * Durable, owner-gated short link to this asset's content (relative `/api/s/{id}` path). Stable across the underlying signed URL's expiry — resolving it re-mints a fresh signed URL on every request — so it is safe to persist or share into chat, unlike `preview_url`. Only the minting user can resolve it. Omitted when the short-link surface is disabled or the asset has no resolvable content hash.
10622
+ * Durable, owner-gated short link to this asset's content (relative `/api/s/{id}` path). Stable across the underlying signed URL's expiry — resolving it re-mints a fresh signed URL on every request — so it is safe to persist or share into chat, unlike `preview_url`. Only the minting user can resolve it. Omitted when the short-link surface is disabled, the asset has no resolvable content hash, or the asset is in a project other than the default.
9987
10623
  */
9988
10624
  short_url?: string | null;
9989
10625
  /**
@@ -10099,9 +10735,12 @@ export type DeploymentModelsWorkspaceId = string;
10099
10735
  export type MediaWorkspaceId = string;
10100
10736
  /**
10101
10737
  * The project a request acts in. The operations that list it are the
10102
- * ones that read it: they list workflows, runs or assets, or create
10103
- * one. Absent means the workspace's default project, which is how
10104
- * existing clients keep working.
10738
+ * ones that read it: they list workflows, runs or assets, create one,
10739
+ * export assets, clear the caller's queue or History, pick the
10740
+ * deployment a browser runs on, or serve the editor that deployment
10741
+ * (the node, extension and model lists). Absent means
10742
+ * the workspace's default project, which is how existing clients keep
10743
+ * working.
10105
10744
  *
10106
10745
  * An operation on one existing workflow, run or asset does not take
10107
10746
  * it: the row's own project decides. Any other operation that creates
@@ -10113,6 +10752,13 @@ export type MediaWorkspaceId = string;
10113
10752
  * `not_found`; the two look the same. Where Projects is not enabled for
10114
10753
  * the workspace the header is ignored.
10115
10754
  *
10755
+ * A Cloud JWT that carries a `project_id` claim acts only in that
10756
+ * project. Without the header such a request acts in the claimed
10757
+ * project; a header naming any other project, the default project
10758
+ * included, is 403 `permission_denied`, and so is any such request
10759
+ * where Projects is not enabled for the workspace. The refusal says the
10760
+ * token is bound to another project, not what the caller's role allows.
10761
+ *
10116
10762
  */
10117
10763
  export type ProjectId = string;
10118
10764
  export type GetJwksData = {
@@ -10278,7 +10924,7 @@ export type AgentGetDraftErrors = {
10278
10924
  */
10279
10925
  401: ErrorResponse | AgentError;
10280
10926
  /**
10281
- * Forbidden (workflow not found or cross-workspace). An ingest refusal, such as the web session's, is ErrorResponse; the agent service's is AgentError.
10927
+ * Forbidden (workflow not found, or not the caller's to read: one answer, AgentError). An ingest refusal, such as the web session's, is ErrorResponse.
10282
10928
  */
10283
10929
  403: ErrorResponse | AgentError;
10284
10930
  /**
@@ -10343,6 +10989,36 @@ export type GetAgentEventsErrors = {
10343
10989
  export type GetAgentEventsError = GetAgentEventsErrors[keyof GetAgentEventsErrors];
10344
10990
  export type AgentGetExecutionsData = {
10345
10991
  body?: never;
10992
+ headers?: {
10993
+ /**
10994
+ * The project a request acts in. The operations that list it are the
10995
+ * ones that read it: they list workflows, runs or assets, create one,
10996
+ * export assets, clear the caller's queue or History, pick the
10997
+ * deployment a browser runs on, or serve the editor that deployment
10998
+ * (the node, extension and model lists). Absent means
10999
+ * the workspace's default project, which is how existing clients keep
11000
+ * working.
11001
+ *
11002
+ * An operation on one existing workflow, run or asset does not take
11003
+ * it: the row's own project decides. Any other operation that creates
11004
+ * a workflow, run or asset acts in the default project until it lists
11005
+ * this parameter.
11006
+ *
11007
+ * The project must be in the workspace the request resolves to. A
11008
+ * project that does not exist, or that the caller may not view, is 404
11009
+ * `not_found`; the two look the same. Where Projects is not enabled for
11010
+ * the workspace the header is ignored.
11011
+ *
11012
+ * A Cloud JWT that carries a `project_id` claim acts only in that
11013
+ * project. Without the header such a request acts in the claimed
11014
+ * project; a header naming any other project, the default project
11015
+ * included, is 403 `permission_denied`, and so is any such request
11016
+ * where Projects is not enabled for the workspace. The refusal says the
11017
+ * token is bound to another project, not what the caller's role allows.
11018
+ *
11019
+ */
11020
+ 'X-Comfy-Project-ID'?: string;
11021
+ };
10346
11022
  path?: never;
10347
11023
  query?: {
10348
11024
  /**
@@ -10410,6 +11086,85 @@ export type AgentGetExecutionsResponses = {
10410
11086
  };
10411
11087
  };
10412
11088
  export type AgentGetExecutionsResponse = AgentGetExecutionsResponses[keyof AgentGetExecutionsResponses];
11089
+ export type AgentGetFeaturesData = {
11090
+ body?: never;
11091
+ headers?: {
11092
+ /**
11093
+ * The project a request acts in. The operations that list it are the
11094
+ * ones that read it: they list workflows, runs or assets, create one,
11095
+ * export assets, clear the caller's queue or History, pick the
11096
+ * deployment a browser runs on, or serve the editor that deployment
11097
+ * (the node, extension and model lists). Absent means
11098
+ * the workspace's default project, which is how existing clients keep
11099
+ * working.
11100
+ *
11101
+ * An operation on one existing workflow, run or asset does not take
11102
+ * it: the row's own project decides. Any other operation that creates
11103
+ * a workflow, run or asset acts in the default project until it lists
11104
+ * this parameter.
11105
+ *
11106
+ * The project must be in the workspace the request resolves to. A
11107
+ * project that does not exist, or that the caller may not view, is 404
11108
+ * `not_found`; the two look the same. Where Projects is not enabled for
11109
+ * the workspace the header is ignored.
11110
+ *
11111
+ * A Cloud JWT that carries a `project_id` claim acts only in that
11112
+ * project. Without the header such a request acts in the claimed
11113
+ * project; a header naming any other project, the default project
11114
+ * included, is 403 `permission_denied`, and so is any such request
11115
+ * where Projects is not enabled for the workspace. The refusal says the
11116
+ * token is bound to another project, not what the caller's role allows.
11117
+ *
11118
+ */
11119
+ 'X-Comfy-Project-ID'?: string;
11120
+ };
11121
+ path?: never;
11122
+ query?: {
11123
+ /**
11124
+ * The thread whose current selection is asked for. A canonical UUID.
11125
+ */
11126
+ thread_id?: string;
11127
+ };
11128
+ url: '/api/agent/features';
11129
+ };
11130
+ export type AgentGetFeaturesErrors = {
11131
+ /**
11132
+ * `thread_id` is not a canonical UUID, or the session's workspace id is invalid.
11133
+ */
11134
+ 400: ErrorResponse;
11135
+ /**
11136
+ * Unauthorized. An ingest refusal, such as the web session's, is ErrorResponse; the agent service's identity-header rejection is AgentError and carries `kind`.
11137
+ */
11138
+ 401: ErrorResponse | AgentError;
11139
+ /**
11140
+ * A refused request. For a web session, `code` is `workspace_access_denied` (the selected workspace is unknown, deleted, or the user is not a member; the three look the same), `no_workspace_access` (the account has no personal workspace and is a member of no live workspace), `origin_not_allowed` or `cross_site_request`; see the `WebSessionAuth` scheme. For any credential, `sso_required` means an SSO organization holds the account (its email is on the organization's verified domains) and the credential is not an SSO sign-in, or the workspace is an SSO organization's and the account is not on its domains or the credential is not an SSO sign-in; `organization_id`, when present, names the organization to sign in with. `account_outside_organization` means the workspace is an SSO organization's and the account is on none of its domains, so no sign-in admits it; `organization_id` names the workspace's organization. `personal_workspace_disabled` means the workspace is the account's personal one and an SSO organization holds the account, so it cannot use it; `organization_id` names that organization. `FORBIDDEN` is the route's own authorization check failing, such as an unverified email. On `GET /api/billing/churnkey/auth`, `NOT_ORIGINAL_OWNER` means the caller is not the workspace's creator; it is returned only when the rollout mode is `creator`. A credential this route does not take gets AuthTypeNotAllowedError instead, and so does the session while `web_session_enabled` is off for the user, unless the operation says it takes the session whatever `web_session_enabled` says.
11141
+ */
11142
+ 403: ForbiddenError;
11143
+ /**
11144
+ * No model control. Ingest-raised (ErrorResponse): the caller is not enrolled in the agent-in-app-experience flag gating the whole /api/agent surface. Agent-raised: the agent service does not serve this route, or `thread_id` names no thread of the caller's in this project. Show no control and send messages as today.
11145
+ */
11146
+ 404: ErrorResponse | AgentError;
11147
+ /**
11148
+ * Internal server error (ingest-raised failures use the standard ErrorResponse shape instead)
11149
+ */
11150
+ 500: AgentError;
11151
+ /**
11152
+ * Agent service unavailable
11153
+ */
11154
+ 502: ErrorResponse;
11155
+ /**
11156
+ * The selections could not be read (retryable; keep the last list for this view, or show no control). Ingest also answers 503 when the agent proxy is not configured to forward safely (a non-local agent service URL with no shared machine-to-machine secret).
11157
+ */
11158
+ 503: ErrorResponse | AgentError;
11159
+ };
11160
+ export type AgentGetFeaturesError = AgentGetFeaturesErrors[keyof AgentGetFeaturesErrors];
11161
+ export type AgentGetFeaturesResponses = {
11162
+ /**
11163
+ * The caller's selections.
11164
+ */
11165
+ 200: AgentFeatures;
11166
+ };
11167
+ export type AgentGetFeaturesResponse = AgentGetFeaturesResponses[keyof AgentGetFeaturesResponses];
10413
11168
  export type AgentGetIdentityData = {
10414
11169
  body?: never;
10415
11170
  path?: never;
@@ -10521,6 +11276,101 @@ export type AgentLlmAdmitResponses = {
10521
11276
  };
10522
11277
  };
10523
11278
  export type AgentLlmAdmitResponse = AgentLlmAdmitResponses[keyof AgentLlmAdmitResponses];
11279
+ export type AgentLlmChatCompletionsData = {
11280
+ /**
11281
+ * Opaque OpenAI Chat Completions request body, passed through to the upstream. Not modeled here — the LLM proxy owns the contract.
11282
+ */
11283
+ body: {
11284
+ [key: string]: unknown;
11285
+ };
11286
+ path?: never;
11287
+ query?: never;
11288
+ url: '/api/agent/llm/v1/chat/completions';
11289
+ };
11290
+ export type AgentLlmChatCompletionsErrors = {
11291
+ /**
11292
+ * `code` is `workspace_id_invalid`: the `X-Comfy-Workspace-ID` header or `workspace_id` query value is malformed, or conflicts with another value or with the workspace the credential resolves to. Answered only while `web_session_enabled` is on for the user. See the `WebSessionAuth` scheme.
11293
+ */
11294
+ 400: ErrorResponse;
11295
+ /**
11296
+ * Unauthorized
11297
+ */
11298
+ 401: ErrorResponse;
11299
+ /**
11300
+ * The pre-turn admission gate declined the turn for a payment reason: the workspace is out of credits or has been blocked. Not retryable as-is — resolve the account condition first.
11301
+ */
11302
+ 402: AgentAdmissionError;
11303
+ /**
11304
+ * Refused, with one of two bodies. ErrorResponse: an ingest refusal of a request that changes data (see SessionWriteForbidden). AgentLLMOpenAIError: the LLM proxy does not serve this caller in this request format; today it refuses every local caller with `error.type` `permission_error`, so nothing ran and nothing was spent. Read it as "not served on this target", not as a credential problem.
11305
+ */
11306
+ 403: ErrorResponse | AgentLlmOpenAiError;
11307
+ /**
11308
+ * The agent in-app experience is disabled for this caller (FlagAgentInAppExperience off; kept invisible, so 404 rather than 403), or the upstream LLM proxy does not mount this route (the proxy embedded in comfy-agent, or llm-proxy where Responses is switched off).
11309
+ */
11310
+ 404: ErrorResponse;
11311
+ /**
11312
+ * Too many requests, with one of two bodies. RateLimitExceededError (`error` is a string): ingest refused the request before it reached the agent, so nothing ran, and no Retry-After is sent. AgentLLMOpenAIError (`error` is an object): the agent's LLM proxy held the round for capacity past its wait (`error.type` `rate_limit_error`), an operator paused the Agent or the workspace (`error.type` `paused`), or the provider throttled the call.
11313
+ */
11314
+ 429: RateLimitExceededError | AgentLlmOpenAiError;
11315
+ /**
11316
+ * Agent service unavailable
11317
+ */
11318
+ 502: ErrorResponse;
11319
+ /**
11320
+ * The agent proxy is not configured to forward safely (a non-local agent service URL with no shared machine-to-machine secret), so ingest refuses rather than sending unverifiable identity headers. If a hard budget cannot be checked, the response carries `error_type: budget_check_unavailable`, `denied_reason`, and `Retry-After`.
11321
+ */
11322
+ 503: ErrorResponse;
11323
+ };
11324
+ export type AgentLlmChatCompletionsError = AgentLlmChatCompletionsErrors[keyof AgentLlmChatCompletionsErrors];
11325
+ export type AgentLlmChatCompletionsResponses = {
11326
+ /**
11327
+ * The upstream response, streamed back chunk-by-chunk (Server-Sent Events for a streamed request).
11328
+ */
11329
+ 200: string;
11330
+ };
11331
+ export type AgentLlmChatCompletionsResponse = AgentLlmChatCompletionsResponses[keyof AgentLlmChatCompletionsResponses];
11332
+ export type AgentLlmFeaturesData = {
11333
+ body?: never;
11334
+ path?: never;
11335
+ query?: never;
11336
+ url: '/api/agent/llm/v1/features';
11337
+ };
11338
+ export type AgentLlmFeaturesErrors = {
11339
+ /**
11340
+ * `code` is `workspace_id_invalid`: the `X-Comfy-Workspace-ID` header or `workspace_id` query value is malformed, or conflicts with another value or with the workspace the credential resolves to. Answered only while `web_session_enabled` is on for the user. See the `WebSessionAuth` scheme.
11341
+ */
11342
+ 400: ErrorResponse;
11343
+ /**
11344
+ * Unauthorized
11345
+ */
11346
+ 401: ErrorResponse;
11347
+ /**
11348
+ * A refused request. For a web session, `code` is `workspace_access_denied` (the selected workspace is unknown, deleted, or the user is not a member; the three look the same), `no_workspace_access` (the account has no personal workspace and is a member of no live workspace), `origin_not_allowed` or `cross_site_request`; see the `WebSessionAuth` scheme. For any credential, `sso_required` means an SSO organization holds the account (its email is on the organization's verified domains) and the credential is not an SSO sign-in, or the workspace is an SSO organization's and the account is not on its domains or the credential is not an SSO sign-in; `organization_id`, when present, names the organization to sign in with. `account_outside_organization` means the workspace is an SSO organization's and the account is on none of its domains, so no sign-in admits it; `organization_id` names the workspace's organization. `personal_workspace_disabled` means the workspace is the account's personal one and an SSO organization holds the account, so it cannot use it; `organization_id` names that organization. `FORBIDDEN` is the route's own authorization check failing, such as an unverified email. On `GET /api/billing/churnkey/auth`, `NOT_ORIGINAL_OWNER` means the caller is not the workspace's creator; it is returned only when the rollout mode is `creator`. A credential this route does not take gets AuthTypeNotAllowedError instead, and so does the session while `web_session_enabled` is off for the user, unless the operation says it takes the session whatever `web_session_enabled` says.
11349
+ */
11350
+ 403: ForbiddenError;
11351
+ /**
11352
+ * The agent in-app experience is disabled for this caller (FlagAgentInAppExperience off; kept invisible, so 404 rather than 403), or the LLM proxy does not serve this route. Either means "not enabled".
11353
+ */
11354
+ 404: ErrorResponse;
11355
+ /**
11356
+ * The LLM proxy is unavailable, or its answer exceeded 1 MiB. The binary keeps its cached answer.
11357
+ */
11358
+ 502: ErrorResponse;
11359
+ /**
11360
+ * The agent proxy is not configured to forward safely (a non-local agent service URL with no shared machine-to-machine secret), or the proxy could not read the selections (retryable).
11361
+ */
11362
+ 503: ErrorResponse;
11363
+ };
11364
+ export type AgentLlmFeaturesError = AgentLlmFeaturesErrors[keyof AgentLlmFeaturesErrors];
11365
+ export type AgentLlmFeaturesResponses = {
11366
+ /**
11367
+ * Opaque features document, passed through from the LLM proxy. Not modeled here — the proxy owns the contract.
11368
+ */
11369
+ 200: {
11370
+ [key: string]: unknown;
11371
+ };
11372
+ };
11373
+ export type AgentLlmFeaturesResponse = AgentLlmFeaturesResponses[keyof AgentLlmFeaturesResponses];
10524
11374
  export type AgentLlmMessagesData = {
10525
11375
  /**
10526
11376
  * Opaque Anthropic Messages request body, passed through to the upstream. Not modeled here — the agent's LLM proxy owns the contract.
@@ -10562,7 +11412,7 @@ export type AgentLlmMessagesErrors = {
10562
11412
  */
10563
11413
  502: ErrorResponse;
10564
11414
  /**
10565
- * The agent proxy is not configured to forward safely (a non-local agent service URL with no shared machine-to-machine secret), so ingest refuses rather than sending unverifiable identity headers.
11415
+ * The agent proxy is not configured to forward safely (a non-local agent service URL with no shared machine-to-machine secret), so ingest refuses rather than sending unverifiable identity headers. If a hard budget cannot be checked, the response carries `error_type: budget_check_unavailable`, `denied_reason`, and `Retry-After`.
10566
11416
  */
10567
11417
  503: ErrorResponse;
10568
11418
  };
@@ -10574,6 +11424,59 @@ export type AgentLlmMessagesResponses = {
10574
11424
  200: string;
10575
11425
  };
10576
11426
  export type AgentLlmMessagesResponse = AgentLlmMessagesResponses[keyof AgentLlmMessagesResponses];
11427
+ export type AgentLlmResponsesData = {
11428
+ /**
11429
+ * Opaque OpenAI Responses request body, passed through to the upstream. Not modeled here — the LLM proxy owns the contract.
11430
+ */
11431
+ body: {
11432
+ [key: string]: unknown;
11433
+ };
11434
+ path?: never;
11435
+ query?: never;
11436
+ url: '/api/agent/llm/v1/responses';
11437
+ };
11438
+ export type AgentLlmResponsesErrors = {
11439
+ /**
11440
+ * `code` is `workspace_id_invalid`: the `X-Comfy-Workspace-ID` header or `workspace_id` query value is malformed, or conflicts with another value or with the workspace the credential resolves to. Answered only while `web_session_enabled` is on for the user. See the `WebSessionAuth` scheme.
11441
+ */
11442
+ 400: ErrorResponse;
11443
+ /**
11444
+ * Unauthorized
11445
+ */
11446
+ 401: ErrorResponse;
11447
+ /**
11448
+ * The pre-turn admission gate declined the turn for a payment reason: the workspace is out of credits or has been blocked. Not retryable as-is — resolve the account condition first.
11449
+ */
11450
+ 402: AgentAdmissionError;
11451
+ /**
11452
+ * Refused, with one of two bodies. ErrorResponse: an ingest refusal of a request that changes data (see SessionWriteForbidden). AgentLLMOpenAIError: the LLM proxy does not serve this caller in this request format; today it refuses every local caller with `error.type` `permission_error`, so nothing ran and nothing was spent. Read it as "not served on this target", not as a credential problem.
11453
+ */
11454
+ 403: ErrorResponse | AgentLlmOpenAiError;
11455
+ /**
11456
+ * The agent in-app experience is disabled for this caller (FlagAgentInAppExperience off; kept invisible, so 404 rather than 403), or the upstream LLM proxy does not mount this route (the proxy embedded in comfy-agent, or llm-proxy where Responses is switched off).
11457
+ */
11458
+ 404: ErrorResponse;
11459
+ /**
11460
+ * Too many requests, with one of two bodies. RateLimitExceededError (`error` is a string): ingest refused the request before it reached the agent, so nothing ran, and no Retry-After is sent. AgentLLMOpenAIError (`error` is an object): the agent's LLM proxy held the round for capacity past its wait (`error.type` `rate_limit_error`), an operator paused the Agent or the workspace (`error.type` `paused`), or the provider throttled the call.
11461
+ */
11462
+ 429: RateLimitExceededError | AgentLlmOpenAiError;
11463
+ /**
11464
+ * Agent service unavailable
11465
+ */
11466
+ 502: ErrorResponse;
11467
+ /**
11468
+ * The agent proxy is not configured to forward safely (a non-local agent service URL with no shared machine-to-machine secret), so ingest refuses rather than sending unverifiable identity headers. If a hard budget cannot be checked, the response carries `error_type: budget_check_unavailable`, `denied_reason`, and `Retry-After`.
11469
+ */
11470
+ 503: ErrorResponse;
11471
+ };
11472
+ export type AgentLlmResponsesError = AgentLlmResponsesErrors[keyof AgentLlmResponsesErrors];
11473
+ export type AgentLlmResponsesResponses = {
11474
+ /**
11475
+ * The upstream response, streamed back chunk-by-chunk (Server-Sent Events for a streamed request).
11476
+ */
11477
+ 200: string;
11478
+ };
11479
+ export type AgentLlmResponsesResponse = AgentLlmResponsesResponses[keyof AgentLlmResponsesResponses];
10577
11480
  export type AgentLlmTracesData = {
10578
11481
  /**
10579
11482
  * An OTLP ExportTraceServiceRequest, optionally gzip-encoded (Content-Encoding gzip); at most 4 MiB encoded and decoded, and 4096 spans.
@@ -10629,6 +11532,58 @@ export type AgentLlmTracesResponses = {
10629
11532
  200: Blob | File;
10630
11533
  };
10631
11534
  export type AgentLlmTracesResponse = AgentLlmTracesResponses[keyof AgentLlmTracesResponses];
11535
+ export type AgentPutModelPreferenceData = {
11536
+ body: AgentModelSelection;
11537
+ path?: never;
11538
+ query?: never;
11539
+ url: '/api/agent/model-preference';
11540
+ };
11541
+ export type AgentPutModelPreferenceErrors = {
11542
+ /**
11543
+ * The body is not a selection's send object (not JSON, a missing or malformed model_id, or an unknown key). An ingest refusal is ErrorResponse; the agent service's is AgentError.
11544
+ */
11545
+ 400: ErrorResponse | AgentError;
11546
+ /**
11547
+ * Unauthorized. An ingest refusal, such as the web session's, is ErrorResponse; the agent service's identity-header rejection is AgentError and carries `kind`.
11548
+ */
11549
+ 401: ErrorResponse | AgentError;
11550
+ /**
11551
+ * A refused request that changes data. For a web session, `code` is `csrf_invalid` (no `X-CSRF-Token`, or not the session's), `workspace_access_denied` (the selected workspace is unknown, deleted, or the user is not a member; the three look the same), `no_workspace_access` (the account has no personal workspace and is a member of no live workspace), `origin_not_allowed` or `cross_site_request`; see the `WebSessionAuth` scheme. For any credential, `sso_required` means an SSO organization holds the account (its email is on the organization's verified domains) and the credential is not an SSO sign-in, or the workspace is an SSO organization's and the account is not on its domains or the credential is not an SSO sign-in; `organization_id`, when present, names the organization to sign in with. `account_outside_organization` means the workspace is an SSO organization's and the account is on none of its domains, so no sign-in admits it; `organization_id` names the workspace's organization. `personal_workspace_disabled` means the workspace is the account's personal one and an SSO organization holds the account, so it cannot use it; `organization_id` names that organization. `FORBIDDEN` is the route's own authorization check failing, such as an unverified email, or, on `POST /api/workspaces`, an account an SSO organization holds (its organization manages its workspaces; signing in again does not change it). On the plan-lifecycle writes (`POST /api/billing/subscribe`, `POST /api/billing/subscription/cancel`, `POST /api/billing/subscription/resubscribe`, `POST /api/billing/subscription/revert-scheduled-change`, `POST /api/billing/ops/{id}/cancel` and the `/api/billing/retention*` routes), `NOT_ORIGINAL_OWNER` means the caller is an owner but not the workspace's creator, and only the creator may change the plan; it is returned only when the rollout mode is `creator`. A credential this route does not take gets AuthTypeNotAllowedError instead, and so does the session while `web_session_enabled` is off for the user, unless the operation says it takes the session whatever the flag.
11552
+ */
11553
+ 403: ForbiddenError;
11554
+ /**
11555
+ * No model control: the caller is not enrolled in the agent-in-app-experience flag (ErrorResponse), or the agent service does not serve this route. Keep the previous selection.
11556
+ */
11557
+ 404: ErrorResponse | AgentError;
11558
+ /**
11559
+ * Request body over the route's 4 KiB cap.
11560
+ */
11561
+ 413: ErrorResponse;
11562
+ /**
11563
+ * Nothing was saved. `model_unavailable`: the selection is not one the caller may choose now (re-read the features and ask again). `model_selection_disabled`: selection is not enabled for the caller (re-read the features; the control disappears).
11564
+ */
11565
+ 422: AgentModelUnavailable | AgentModelSelectionDisabled;
11566
+ /**
11567
+ * Internal server error (ingest-raised failures use the standard ErrorResponse shape instead)
11568
+ */
11569
+ 500: AgentError;
11570
+ /**
11571
+ * Agent service unavailable
11572
+ */
11573
+ 502: ErrorResponse;
11574
+ /**
11575
+ * The agent proxy is not configured to forward safely (a non-local agent service URL with no shared machine-to-machine secret), or the selections could not be read (retryable).
11576
+ */
11577
+ 503: ErrorResponse | AgentError;
11578
+ };
11579
+ export type AgentPutModelPreferenceError = AgentPutModelPreferenceErrors[keyof AgentPutModelPreferenceErrors];
11580
+ export type AgentPutModelPreferenceResponses = {
11581
+ /**
11582
+ * The committed selection.
11583
+ */
11584
+ 200: AgentModelSelectionSaved;
11585
+ };
11586
+ export type AgentPutModelPreferenceResponse = AgentPutModelPreferenceResponses[keyof AgentPutModelPreferenceResponses];
10632
11587
  export type AgentGetRunModeData = {
10633
11588
  body?: never;
10634
11589
  path?: never;
@@ -10870,8 +11825,82 @@ export type AgentDeleteSkillResponses = {
10870
11825
  204: void;
10871
11826
  };
10872
11827
  export type AgentDeleteSkillResponse = AgentDeleteSkillResponses[keyof AgentDeleteSkillResponses];
11828
+ export type AgentListBuiltinSkillsData = {
11829
+ body?: never;
11830
+ path?: never;
11831
+ query?: never;
11832
+ url: '/api/agent/skills/builtin';
11833
+ };
11834
+ export type AgentListBuiltinSkillsErrors = {
11835
+ /**
11836
+ * `code` is `workspace_id_invalid`: the `X-Comfy-Workspace-ID` header or `workspace_id` query value is malformed, or conflicts with another value or with the workspace the credential resolves to. Answered only while `web_session_enabled` is on for the user. See the `WebSessionAuth` scheme.
11837
+ */
11838
+ 400: ErrorResponse;
11839
+ /**
11840
+ * Unauthorized. An ingest refusal, such as the web session's, is ErrorResponse; the agent service's identity-header rejection is AgentError and carries `kind`.
11841
+ */
11842
+ 401: ErrorResponse | AgentError;
11843
+ /**
11844
+ * A refused request. For a web session, `code` is `workspace_access_denied` (the selected workspace is unknown, deleted, or the user is not a member; the three look the same), `no_workspace_access` (the account has no personal workspace and is a member of no live workspace), `origin_not_allowed` or `cross_site_request`; see the `WebSessionAuth` scheme. For any credential, `sso_required` means an SSO organization holds the account (its email is on the organization's verified domains) and the credential is not an SSO sign-in, or the workspace is an SSO organization's and the account is not on its domains or the credential is not an SSO sign-in; `organization_id`, when present, names the organization to sign in with. `account_outside_organization` means the workspace is an SSO organization's and the account is on none of its domains, so no sign-in admits it; `organization_id` names the workspace's organization. `personal_workspace_disabled` means the workspace is the account's personal one and an SSO organization holds the account, so it cannot use it; `organization_id` names that organization. `FORBIDDEN` is the route's own authorization check failing, such as an unverified email. On `GET /api/billing/churnkey/auth`, `NOT_ORIGINAL_OWNER` means the caller is not the workspace's creator; it is returned only when the rollout mode is `creator`. A credential this route does not take gets AuthTypeNotAllowedError instead, and so does the session while `web_session_enabled` is off for the user, unless the operation says it takes the session whatever `web_session_enabled` says.
11845
+ */
11846
+ 403: ForbiddenError;
11847
+ /**
11848
+ * The caller is not enrolled in the cohort gate fronting the skill routes: the agent-skill-packs flag, or the agent-in-app-experience flag gating the whole /api/agent surface. Both default off and fail closed (a missing evaluation context resolves to false), and both answer 404 rather than 403 so the surface is invisible when off. Ingest-raised, so the body is the standard ErrorResponse shape.
11849
+ */
11850
+ 404: ErrorResponse;
11851
+ /**
11852
+ * Internal server error (ingest-raised failures use the standard ErrorResponse shape instead)
11853
+ */
11854
+ 500: AgentError;
11855
+ /**
11856
+ * Agent service unavailable
11857
+ */
11858
+ 502: ErrorResponse;
11859
+ /**
11860
+ * The agent proxy is not configured to forward safely (a non-local agent service URL with no shared machine-to-machine secret), so ingest refuses rather than sending unverifiable identity headers.
11861
+ */
11862
+ 503: ErrorResponse;
11863
+ };
11864
+ export type AgentListBuiltinSkillsError = AgentListBuiltinSkillsErrors[keyof AgentListBuiltinSkillsErrors];
11865
+ export type AgentListBuiltinSkillsResponses = {
11866
+ /**
11867
+ * The skills the agent itself ships.
11868
+ */
11869
+ 200: AgentBuiltinSkillListResponse;
11870
+ };
11871
+ export type AgentListBuiltinSkillsResponse = AgentListBuiltinSkillsResponses[keyof AgentListBuiltinSkillsResponses];
10873
11872
  export type AgentListThreadsData = {
10874
11873
  body?: never;
11874
+ headers?: {
11875
+ /**
11876
+ * The project a request acts in. The operations that list it are the
11877
+ * ones that read it: they list workflows, runs or assets, create one,
11878
+ * export assets, clear the caller's queue or History, pick the
11879
+ * deployment a browser runs on, or serve the editor that deployment
11880
+ * (the node, extension and model lists). Absent means
11881
+ * the workspace's default project, which is how existing clients keep
11882
+ * working.
11883
+ *
11884
+ * An operation on one existing workflow, run or asset does not take
11885
+ * it: the row's own project decides. Any other operation that creates
11886
+ * a workflow, run or asset acts in the default project until it lists
11887
+ * this parameter.
11888
+ *
11889
+ * The project must be in the workspace the request resolves to. A
11890
+ * project that does not exist, or that the caller may not view, is 404
11891
+ * `not_found`; the two look the same. Where Projects is not enabled for
11892
+ * the workspace the header is ignored.
11893
+ *
11894
+ * A Cloud JWT that carries a `project_id` claim acts only in that
11895
+ * project. Without the header such a request acts in the claimed
11896
+ * project; a header naming any other project, the default project
11897
+ * included, is 403 `permission_denied`, and so is any such request
11898
+ * where Projects is not enabled for the workspace. The refusal says the
11899
+ * token is bound to another project, not what the caller's role allows.
11900
+ *
11901
+ */
11902
+ 'X-Comfy-Project-ID'?: string;
11903
+ };
10875
11904
  path?: never;
10876
11905
  query?: {
10877
11906
  /**
@@ -10938,6 +11967,36 @@ export type AgentListThreadsResponses = {
10938
11967
  export type AgentListThreadsResponse = AgentListThreadsResponses[keyof AgentListThreadsResponses];
10939
11968
  export type AgentCreateThreadData = {
10940
11969
  body?: AgentThreadCreateRequest;
11970
+ headers?: {
11971
+ /**
11972
+ * The project a request acts in. The operations that list it are the
11973
+ * ones that read it: they list workflows, runs or assets, create one,
11974
+ * export assets, clear the caller's queue or History, pick the
11975
+ * deployment a browser runs on, or serve the editor that deployment
11976
+ * (the node, extension and model lists). Absent means
11977
+ * the workspace's default project, which is how existing clients keep
11978
+ * working.
11979
+ *
11980
+ * An operation on one existing workflow, run or asset does not take
11981
+ * it: the row's own project decides. Any other operation that creates
11982
+ * a workflow, run or asset acts in the default project until it lists
11983
+ * this parameter.
11984
+ *
11985
+ * The project must be in the workspace the request resolves to. A
11986
+ * project that does not exist, or that the caller may not view, is 404
11987
+ * `not_found`; the two look the same. Where Projects is not enabled for
11988
+ * the workspace the header is ignored.
11989
+ *
11990
+ * A Cloud JWT that carries a `project_id` claim acts only in that
11991
+ * project. Without the header such a request acts in the claimed
11992
+ * project; a header naming any other project, the default project
11993
+ * included, is 403 `permission_denied`, and so is any such request
11994
+ * where Projects is not enabled for the workspace. The refusal says the
11995
+ * token is bound to another project, not what the caller's role allows.
11996
+ *
11997
+ */
11998
+ 'X-Comfy-Project-ID'?: string;
11999
+ };
10941
12000
  path?: never;
10942
12001
  query?: never;
10943
12002
  url: '/api/agent/threads';
@@ -10972,8 +12031,117 @@ export type AgentCreateThreadResponses = {
10972
12031
  201: AgentThreadCreated;
10973
12032
  };
10974
12033
  export type AgentCreateThreadResponse = AgentCreateThreadResponses[keyof AgentCreateThreadResponses];
12034
+ export type AgentDeleteThreadData = {
12035
+ body?: never;
12036
+ headers?: {
12037
+ /**
12038
+ * The project a request acts in. The operations that list it are the
12039
+ * ones that read it: they list workflows, runs or assets, create one,
12040
+ * export assets, clear the caller's queue or History, pick the
12041
+ * deployment a browser runs on, or serve the editor that deployment
12042
+ * (the node, extension and model lists). Absent means
12043
+ * the workspace's default project, which is how existing clients keep
12044
+ * working.
12045
+ *
12046
+ * An operation on one existing workflow, run or asset does not take
12047
+ * it: the row's own project decides. Any other operation that creates
12048
+ * a workflow, run or asset acts in the default project until it lists
12049
+ * this parameter.
12050
+ *
12051
+ * The project must be in the workspace the request resolves to. A
12052
+ * project that does not exist, or that the caller may not view, is 404
12053
+ * `not_found`; the two look the same. Where Projects is not enabled for
12054
+ * the workspace the header is ignored.
12055
+ *
12056
+ * A Cloud JWT that carries a `project_id` claim acts only in that
12057
+ * project. Without the header such a request acts in the claimed
12058
+ * project; a header naming any other project, the default project
12059
+ * included, is 403 `permission_denied`, and so is any such request
12060
+ * where Projects is not enabled for the workspace. The refusal says the
12061
+ * token is bound to another project, not what the caller's role allows.
12062
+ *
12063
+ */
12064
+ 'X-Comfy-Project-ID'?: string;
12065
+ };
12066
+ path: {
12067
+ /**
12068
+ * Thread ID (canonical UUID).
12069
+ */
12070
+ id: string;
12071
+ };
12072
+ query?: never;
12073
+ url: '/api/agent/threads/{id}';
12074
+ };
12075
+ export type AgentDeleteThreadErrors = {
12076
+ /**
12077
+ * The thread ID is not a canonical UUID.
12078
+ */
12079
+ 400: ErrorResponse;
12080
+ /**
12081
+ * Unauthorized. An ingest refusal, such as the web session's, is ErrorResponse; the agent service's identity-header rejection is AgentError and carries `kind`.
12082
+ */
12083
+ 401: ErrorResponse | AgentError;
12084
+ /**
12085
+ * A refused request that changes data. For a web session, `code` is `csrf_invalid` (no `X-CSRF-Token`, or not the session's), `workspace_access_denied` (the selected workspace is unknown, deleted, or the user is not a member; the three look the same), `no_workspace_access` (the account has no personal workspace and is a member of no live workspace), `origin_not_allowed` or `cross_site_request`; see the `WebSessionAuth` scheme. For any credential, `sso_required` means an SSO organization holds the account (its email is on the organization's verified domains) and the credential is not an SSO sign-in, or the workspace is an SSO organization's and the account is not on its domains or the credential is not an SSO sign-in; `organization_id`, when present, names the organization to sign in with. `account_outside_organization` means the workspace is an SSO organization's and the account is on none of its domains, so no sign-in admits it; `organization_id` names the workspace's organization. `personal_workspace_disabled` means the workspace is the account's personal one and an SSO organization holds the account, so it cannot use it; `organization_id` names that organization. `FORBIDDEN` is the route's own authorization check failing, such as an unverified email, or, on `POST /api/workspaces`, an account an SSO organization holds (its organization manages its workspaces; signing in again does not change it). On the plan-lifecycle writes (`POST /api/billing/subscribe`, `POST /api/billing/subscription/cancel`, `POST /api/billing/subscription/resubscribe`, `POST /api/billing/subscription/revert-scheduled-change`, `POST /api/billing/ops/{id}/cancel` and the `/api/billing/retention*` routes), `NOT_ORIGINAL_OWNER` means the caller is an owner but not the workspace's creator, and only the creator may change the plan; it is returned only when the rollout mode is `creator`. A credential this route does not take gets AuthTypeNotAllowedError instead, and so does the session while `web_session_enabled` is off for the user, unless the operation says it takes the session whatever the flag.
12086
+ */
12087
+ 403: ForbiddenError;
12088
+ /**
12089
+ * The caller holds no thread with that ID in this workspace and project (including repeat deletes), or the caller is not enrolled in the agent-in-app-experience feature flag (ingest-raised 404 uses ErrorResponse; agent-raised 404 uses AgentError).
12090
+ */
12091
+ 404: ErrorResponse | AgentError;
12092
+ /**
12093
+ * Internal server error (ingest-raised failures use the standard ErrorResponse shape instead)
12094
+ */
12095
+ 500: AgentError;
12096
+ /**
12097
+ * Agent service unavailable
12098
+ */
12099
+ 502: ErrorResponse;
12100
+ /**
12101
+ * Either the active turn's cancellation request did not land or could not be confirmed (`AgentCancelUnconfirmed` with `Retry-After` — the thread was not deleted and retrying is safe), or the agent proxy is not configured to forward safely (`ErrorResponse`).
12102
+ */
12103
+ 503: ErrorResponse | AgentCancelUnconfirmed;
12104
+ };
12105
+ export type AgentDeleteThreadError = AgentDeleteThreadErrors[keyof AgentDeleteThreadErrors];
12106
+ export type AgentDeleteThreadResponses = {
12107
+ /**
12108
+ * The thread was deleted.
12109
+ */
12110
+ 204: void;
12111
+ };
12112
+ export type AgentDeleteThreadResponse = AgentDeleteThreadResponses[keyof AgentDeleteThreadResponses];
10975
12113
  export type AgentAnswerAskData = {
10976
12114
  body: AgentAnswerRequest;
12115
+ headers?: {
12116
+ /**
12117
+ * The project a request acts in. The operations that list it are the
12118
+ * ones that read it: they list workflows, runs or assets, create one,
12119
+ * export assets, clear the caller's queue or History, pick the
12120
+ * deployment a browser runs on, or serve the editor that deployment
12121
+ * (the node, extension and model lists). Absent means
12122
+ * the workspace's default project, which is how existing clients keep
12123
+ * working.
12124
+ *
12125
+ * An operation on one existing workflow, run or asset does not take
12126
+ * it: the row's own project decides. Any other operation that creates
12127
+ * a workflow, run or asset acts in the default project until it lists
12128
+ * this parameter.
12129
+ *
12130
+ * The project must be in the workspace the request resolves to. A
12131
+ * project that does not exist, or that the caller may not view, is 404
12132
+ * `not_found`; the two look the same. Where Projects is not enabled for
12133
+ * the workspace the header is ignored.
12134
+ *
12135
+ * A Cloud JWT that carries a `project_id` claim acts only in that
12136
+ * project. Without the header such a request acts in the claimed
12137
+ * project; a header naming any other project, the default project
12138
+ * included, is 403 `permission_denied`, and so is any such request
12139
+ * where Projects is not enabled for the workspace. The refusal says the
12140
+ * token is bound to another project, not what the caller's role allows.
12141
+ *
12142
+ */
12143
+ 'X-Comfy-Project-ID'?: string;
12144
+ };
10977
12145
  path: {
10978
12146
  /**
10979
12147
  * Thread ID
@@ -11042,6 +12210,36 @@ export type AgentAnswerAskResponses = {
11042
12210
  export type AgentAnswerAskResponse = AgentAnswerAskResponses[keyof AgentAnswerAskResponses];
11043
12211
  export type AgentGetMessagesData = {
11044
12212
  body?: never;
12213
+ headers?: {
12214
+ /**
12215
+ * The project a request acts in. The operations that list it are the
12216
+ * ones that read it: they list workflows, runs or assets, create one,
12217
+ * export assets, clear the caller's queue or History, pick the
12218
+ * deployment a browser runs on, or serve the editor that deployment
12219
+ * (the node, extension and model lists). Absent means
12220
+ * the workspace's default project, which is how existing clients keep
12221
+ * working.
12222
+ *
12223
+ * An operation on one existing workflow, run or asset does not take
12224
+ * it: the row's own project decides. Any other operation that creates
12225
+ * a workflow, run or asset acts in the default project until it lists
12226
+ * this parameter.
12227
+ *
12228
+ * The project must be in the workspace the request resolves to. A
12229
+ * project that does not exist, or that the caller may not view, is 404
12230
+ * `not_found`; the two look the same. Where Projects is not enabled for
12231
+ * the workspace the header is ignored.
12232
+ *
12233
+ * A Cloud JWT that carries a `project_id` claim acts only in that
12234
+ * project. Without the header such a request acts in the claimed
12235
+ * project; a header naming any other project, the default project
12236
+ * included, is 403 `permission_denied`, and so is any such request
12237
+ * where Projects is not enabled for the workspace. The refusal says the
12238
+ * token is bound to another project, not what the caller's role allows.
12239
+ *
12240
+ */
12241
+ 'X-Comfy-Project-ID'?: string;
12242
+ };
11045
12243
  path: {
11046
12244
  /**
11047
12245
  * Thread ID
@@ -11087,6 +12285,36 @@ export type AgentGetMessagesResponses = {
11087
12285
  export type AgentGetMessagesResponse = AgentGetMessagesResponses[keyof AgentGetMessagesResponses];
11088
12286
  export type AgentPostMessageData = {
11089
12287
  body: AgentPostMessageRequest;
12288
+ headers?: {
12289
+ /**
12290
+ * The project a request acts in. The operations that list it are the
12291
+ * ones that read it: they list workflows, runs or assets, create one,
12292
+ * export assets, clear the caller's queue or History, pick the
12293
+ * deployment a browser runs on, or serve the editor that deployment
12294
+ * (the node, extension and model lists). Absent means
12295
+ * the workspace's default project, which is how existing clients keep
12296
+ * working.
12297
+ *
12298
+ * An operation on one existing workflow, run or asset does not take
12299
+ * it: the row's own project decides. Any other operation that creates
12300
+ * a workflow, run or asset acts in the default project until it lists
12301
+ * this parameter.
12302
+ *
12303
+ * The project must be in the workspace the request resolves to. A
12304
+ * project that does not exist, or that the caller may not view, is 404
12305
+ * `not_found`; the two look the same. Where Projects is not enabled for
12306
+ * the workspace the header is ignored.
12307
+ *
12308
+ * A Cloud JWT that carries a `project_id` claim acts only in that
12309
+ * project. Without the header such a request acts in the claimed
12310
+ * project; a header naming any other project, the default project
12311
+ * included, is 403 `permission_denied`, and so is any such request
12312
+ * where Projects is not enabled for the workspace. The refusal says the
12313
+ * token is bound to another project, not what the caller's role allows.
12314
+ *
12315
+ */
12316
+ 'X-Comfy-Project-ID'?: string;
12317
+ };
11090
12318
  path: {
11091
12319
  /**
11092
12320
  * Thread ID. Use the literal "new" to open a fresh thread in the same call.
@@ -11130,9 +12358,9 @@ export type AgentPostMessageErrors = {
11130
12358
  */
11131
12359
  502: ErrorResponse;
11132
12360
  /**
11133
- * The workspace's billing status could not be checked right now (a temporary outage, not a payment problem). Retry the request after the delay given in the Retry-After header.
12361
+ * Temporarily unable to start the turn. A billing-status outage returns AgentAdmissionError with Retry-After. The agent returns AgentError when it is shutting down or cannot read a recorded thread's model configuration, including a missing features route. These agent refusals write no message and start no turn; retry without changing the recorded model.
11134
12362
  */
11135
- 503: AgentAdmissionError;
12363
+ 503: AgentAdmissionError | AgentError;
11136
12364
  };
11137
12365
  export type AgentPostMessageError = AgentPostMessageErrors[keyof AgentPostMessageErrors];
11138
12366
  export type AgentPostMessageResponses = {
@@ -11144,6 +12372,36 @@ export type AgentPostMessageResponses = {
11144
12372
  export type AgentPostMessageResponse = AgentPostMessageResponses[keyof AgentPostMessageResponses];
11145
12373
  export type AgentCancelMessageData = {
11146
12374
  body?: never;
12375
+ headers?: {
12376
+ /**
12377
+ * The project a request acts in. The operations that list it are the
12378
+ * ones that read it: they list workflows, runs or assets, create one,
12379
+ * export assets, clear the caller's queue or History, pick the
12380
+ * deployment a browser runs on, or serve the editor that deployment
12381
+ * (the node, extension and model lists). Absent means
12382
+ * the workspace's default project, which is how existing clients keep
12383
+ * working.
12384
+ *
12385
+ * An operation on one existing workflow, run or asset does not take
12386
+ * it: the row's own project decides. Any other operation that creates
12387
+ * a workflow, run or asset acts in the default project until it lists
12388
+ * this parameter.
12389
+ *
12390
+ * The project must be in the workspace the request resolves to. A
12391
+ * project that does not exist, or that the caller may not view, is 404
12392
+ * `not_found`; the two look the same. Where Projects is not enabled for
12393
+ * the workspace the header is ignored.
12394
+ *
12395
+ * A Cloud JWT that carries a `project_id` claim acts only in that
12396
+ * project. Without the header such a request acts in the claimed
12397
+ * project; a header naming any other project, the default project
12398
+ * included, is 403 `permission_denied`, and so is any such request
12399
+ * where Projects is not enabled for the workspace. The refusal says the
12400
+ * token is bound to another project, not what the caller's role allows.
12401
+ *
12402
+ */
12403
+ 'X-Comfy-Project-ID'?: string;
12404
+ };
11147
12405
  path: {
11148
12406
  /**
11149
12407
  * Thread ID
@@ -11203,6 +12461,93 @@ export type AgentCancelMessageResponses = {
11203
12461
  202: AgentCancelAccepted;
11204
12462
  };
11205
12463
  export type AgentCancelMessageResponse = AgentCancelMessageResponses[keyof AgentCancelMessageResponses];
12464
+ export type AgentPutThreadModelSelectionData = {
12465
+ body: AgentModelSelection;
12466
+ headers?: {
12467
+ /**
12468
+ * The project a request acts in. The operations that list it are the
12469
+ * ones that read it: they list workflows, runs or assets, create one,
12470
+ * export assets, clear the caller's queue or History, pick the
12471
+ * deployment a browser runs on, or serve the editor that deployment
12472
+ * (the node, extension and model lists). Absent means
12473
+ * the workspace's default project, which is how existing clients keep
12474
+ * working.
12475
+ *
12476
+ * An operation on one existing workflow, run or asset does not take
12477
+ * it: the row's own project decides. Any other operation that creates
12478
+ * a workflow, run or asset acts in the default project until it lists
12479
+ * this parameter.
12480
+ *
12481
+ * The project must be in the workspace the request resolves to. A
12482
+ * project that does not exist, or that the caller may not view, is 404
12483
+ * `not_found`; the two look the same. Where Projects is not enabled for
12484
+ * the workspace the header is ignored.
12485
+ *
12486
+ * A Cloud JWT that carries a `project_id` claim acts only in that
12487
+ * project. Without the header such a request acts in the claimed
12488
+ * project; a header naming any other project, the default project
12489
+ * included, is 403 `permission_denied`, and so is any such request
12490
+ * where Projects is not enabled for the workspace. The refusal says the
12491
+ * token is bound to another project, not what the caller's role allows.
12492
+ *
12493
+ */
12494
+ 'X-Comfy-Project-ID'?: string;
12495
+ };
12496
+ path: {
12497
+ /**
12498
+ * Thread ID, a canonical UUID.
12499
+ */
12500
+ id: string;
12501
+ };
12502
+ query?: never;
12503
+ url: '/api/agent/threads/{id}/model-selection';
12504
+ };
12505
+ export type AgentPutThreadModelSelectionErrors = {
12506
+ /**
12507
+ * The thread id is not a canonical UUID, or the body is not a selection's send object. An ingest refusal is ErrorResponse; the agent service's is AgentError.
12508
+ */
12509
+ 400: ErrorResponse | AgentError;
12510
+ /**
12511
+ * Unauthorized. An ingest refusal, such as the web session's, is ErrorResponse; the agent service's identity-header rejection is AgentError and carries `kind`.
12512
+ */
12513
+ 401: ErrorResponse | AgentError;
12514
+ /**
12515
+ * A refused request that changes data. For a web session, `code` is `csrf_invalid` (no `X-CSRF-Token`, or not the session's), `workspace_access_denied` (the selected workspace is unknown, deleted, or the user is not a member; the three look the same), `no_workspace_access` (the account has no personal workspace and is a member of no live workspace), `origin_not_allowed` or `cross_site_request`; see the `WebSessionAuth` scheme. For any credential, `sso_required` means an SSO organization holds the account (its email is on the organization's verified domains) and the credential is not an SSO sign-in, or the workspace is an SSO organization's and the account is not on its domains or the credential is not an SSO sign-in; `organization_id`, when present, names the organization to sign in with. `account_outside_organization` means the workspace is an SSO organization's and the account is on none of its domains, so no sign-in admits it; `organization_id` names the workspace's organization. `personal_workspace_disabled` means the workspace is the account's personal one and an SSO organization holds the account, so it cannot use it; `organization_id` names that organization. `FORBIDDEN` is the route's own authorization check failing, such as an unverified email, or, on `POST /api/workspaces`, an account an SSO organization holds (its organization manages its workspaces; signing in again does not change it). On the plan-lifecycle writes (`POST /api/billing/subscribe`, `POST /api/billing/subscription/cancel`, `POST /api/billing/subscription/resubscribe`, `POST /api/billing/subscription/revert-scheduled-change`, `POST /api/billing/ops/{id}/cancel` and the `/api/billing/retention*` routes), `NOT_ORIGINAL_OWNER` means the caller is an owner but not the workspace's creator, and only the creator may change the plan; it is returned only when the rollout mode is `creator`. A credential this route does not take gets AuthTypeNotAllowedError instead, and so does the session while `web_session_enabled` is off for the user, unless the operation says it takes the session whatever the flag.
12516
+ */
12517
+ 403: ForbiddenError;
12518
+ /**
12519
+ * No model control: the caller is not enrolled in the agent-in-app-experience flag (ErrorResponse), or the agent service does not serve this route; or no such thread of the caller's in this project.
12520
+ */
12521
+ 404: ErrorResponse | AgentError;
12522
+ /**
12523
+ * Request body over the route's 4 KiB cap.
12524
+ */
12525
+ 413: ErrorResponse;
12526
+ /**
12527
+ * Nothing was saved. `model_unavailable`: the selection is not one the caller may choose now (re-read the features and ask again). `model_selection_disabled`: selection is not enabled for the caller (re-read the features; the control disappears).
12528
+ */
12529
+ 422: AgentModelUnavailable | AgentModelSelectionDisabled;
12530
+ /**
12531
+ * Internal server error (ingest-raised failures use the standard ErrorResponse shape instead)
12532
+ */
12533
+ 500: AgentError;
12534
+ /**
12535
+ * Agent service unavailable
12536
+ */
12537
+ 502: ErrorResponse;
12538
+ /**
12539
+ * The agent proxy is not configured to forward safely (a non-local agent service URL with no shared machine-to-machine secret), or the selections could not be read (retryable).
12540
+ */
12541
+ 503: ErrorResponse | AgentError;
12542
+ };
12543
+ export type AgentPutThreadModelSelectionError = AgentPutThreadModelSelectionErrors[keyof AgentPutThreadModelSelectionErrors];
12544
+ export type AgentPutThreadModelSelectionResponses = {
12545
+ /**
12546
+ * The committed selection.
12547
+ */
12548
+ 200: AgentModelSelectionSaved;
12549
+ };
12550
+ export type AgentPutThreadModelSelectionResponse = AgentPutThreadModelSelectionResponses[keyof AgentPutThreadModelSelectionResponses];
11206
12551
  export type AgentGetUsageStatusData = {
11207
12552
  body?: never;
11208
12553
  path?: never;
@@ -11252,9 +12597,12 @@ export type ListAssetsData = {
11252
12597
  headers?: {
11253
12598
  /**
11254
12599
  * The project a request acts in. The operations that list it are the
11255
- * ones that read it: they list workflows, runs or assets, or create
11256
- * one. Absent means the workspace's default project, which is how
11257
- * existing clients keep working.
12600
+ * ones that read it: they list workflows, runs or assets, create one,
12601
+ * export assets, clear the caller's queue or History, pick the
12602
+ * deployment a browser runs on, or serve the editor that deployment
12603
+ * (the node, extension and model lists). Absent means
12604
+ * the workspace's default project, which is how existing clients keep
12605
+ * working.
11258
12606
  *
11259
12607
  * An operation on one existing workflow, run or asset does not take
11260
12608
  * it: the row's own project decides. Any other operation that creates
@@ -11266,6 +12614,13 @@ export type ListAssetsData = {
11266
12614
  * `not_found`; the two look the same. Where Projects is not enabled for
11267
12615
  * the workspace the header is ignored.
11268
12616
  *
12617
+ * A Cloud JWT that carries a `project_id` claim acts only in that
12618
+ * project. Without the header such a request acts in the claimed
12619
+ * project; a header naming any other project, the default project
12620
+ * included, is 403 `permission_denied`, and so is any such request
12621
+ * where Projects is not enabled for the workspace. The refusal says the
12622
+ * token is bound to another project, not what the caller's role allows.
12623
+ *
11269
12624
  */
11270
12625
  'X-Comfy-Project-ID'?: string;
11271
12626
  };
@@ -11355,8 +12710,14 @@ export type ListAssetsData = {
11355
12710
  * List the workspace's model library: every member's private model
11356
12711
  * rows in this workspace, not only the caller's, and none of the
11357
12712
  * public catalog. A browser that runs on a picked deployment gets the
11358
- * whole library, not only the Release's models, so its loader
11359
- * dropdowns can offer a model the deployment downloads for the job.
12713
+ * library, not only the Release's models, so its loader dropdowns can
12714
+ * offer a model the deployment downloads for the job. Every library
12715
+ * row is listed, whatever the Release's model policy says. For a
12716
+ * browser bound to a deployment (its own pick or the workspace
12717
+ * default), each row that policy blocks carries
12718
+ * `blocked_by_model_policy: true`, so a client can show it as blocked
12719
+ * rather than leave it out; a Run that names it is refused. A policy
12720
+ * that cannot be read marks no row.
11360
12721
  * Needs `models` among the tags (`tags_all` or `include_tags`), else
11361
12722
  * 400 `INVALID_TAG_FILTER`. Honoured only while the
11362
12723
  * `runtime_library_models_enabled` flag is on for the caller;
@@ -11474,9 +12835,12 @@ export type CreateAssetData = {
11474
12835
  headers?: {
11475
12836
  /**
11476
12837
  * The project a request acts in. The operations that list it are the
11477
- * ones that read it: they list workflows, runs or assets, or create
11478
- * one. Absent means the workspace's default project, which is how
11479
- * existing clients keep working.
12838
+ * ones that read it: they list workflows, runs or assets, create one,
12839
+ * export assets, clear the caller's queue or History, pick the
12840
+ * deployment a browser runs on, or serve the editor that deployment
12841
+ * (the node, extension and model lists). Absent means
12842
+ * the workspace's default project, which is how existing clients keep
12843
+ * working.
11480
12844
  *
11481
12845
  * An operation on one existing workflow, run or asset does not take
11482
12846
  * it: the row's own project decides. Any other operation that creates
@@ -11488,6 +12852,13 @@ export type CreateAssetData = {
11488
12852
  * `not_found`; the two look the same. Where Projects is not enabled for
11489
12853
  * the workspace the header is ignored.
11490
12854
  *
12855
+ * A Cloud JWT that carries a `project_id` claim acts only in that
12856
+ * project. Without the header such a request acts in the claimed
12857
+ * project; a header naming any other project, the default project
12858
+ * included, is 403 `permission_denied`, and so is any such request
12859
+ * where Projects is not enabled for the workspace. The refusal says the
12860
+ * token is bound to another project, not what the caller's role allows.
12861
+ *
11491
12862
  */
11492
12863
  'X-Comfy-Project-ID'?: string;
11493
12864
  };
@@ -11943,6 +13314,36 @@ export type CreateAssetExportData = {
11943
13314
  */
11944
13315
  naming_strategy?: 'group_by_job_id' | 'preserve' | 'asset_id' | 'group_by_job_time';
11945
13316
  };
13317
+ headers?: {
13318
+ /**
13319
+ * The project a request acts in. The operations that list it are the
13320
+ * ones that read it: they list workflows, runs or assets, create one,
13321
+ * export assets, clear the caller's queue or History, pick the
13322
+ * deployment a browser runs on, or serve the editor that deployment
13323
+ * (the node, extension and model lists). Absent means
13324
+ * the workspace's default project, which is how existing clients keep
13325
+ * working.
13326
+ *
13327
+ * An operation on one existing workflow, run or asset does not take
13328
+ * it: the row's own project decides. Any other operation that creates
13329
+ * a workflow, run or asset acts in the default project until it lists
13330
+ * this parameter.
13331
+ *
13332
+ * The project must be in the workspace the request resolves to. A
13333
+ * project that does not exist, or that the caller may not view, is 404
13334
+ * `not_found`; the two look the same. Where Projects is not enabled for
13335
+ * the workspace the header is ignored.
13336
+ *
13337
+ * A Cloud JWT that carries a `project_id` claim acts only in that
13338
+ * project. Without the header such a request acts in the claimed
13339
+ * project; a header naming any other project, the default project
13340
+ * included, is 403 `permission_denied`, and so is any such request
13341
+ * where Projects is not enabled for the workspace. The refusal says the
13342
+ * token is bound to another project, not what the caller's role allows.
13343
+ *
13344
+ */
13345
+ 'X-Comfy-Project-ID'?: string;
13346
+ };
11946
13347
  path?: never;
11947
13348
  query?: never;
11948
13349
  url: '/api/assets/export';
@@ -12042,9 +13443,12 @@ export type CreateAssetFromHashData = {
12042
13443
  headers?: {
12043
13444
  /**
12044
13445
  * The project a request acts in. The operations that list it are the
12045
- * ones that read it: they list workflows, runs or assets, or create
12046
- * one. Absent means the workspace's default project, which is how
12047
- * existing clients keep working.
13446
+ * ones that read it: they list workflows, runs or assets, create one,
13447
+ * export assets, clear the caller's queue or History, pick the
13448
+ * deployment a browser runs on, or serve the editor that deployment
13449
+ * (the node, extension and model lists). Absent means
13450
+ * the workspace's default project, which is how existing clients keep
13451
+ * working.
12048
13452
  *
12049
13453
  * An operation on one existing workflow, run or asset does not take
12050
13454
  * it: the row's own project decides. Any other operation that creates
@@ -12056,6 +13460,13 @@ export type CreateAssetFromHashData = {
12056
13460
  * `not_found`; the two look the same. Where Projects is not enabled for
12057
13461
  * the workspace the header is ignored.
12058
13462
  *
13463
+ * A Cloud JWT that carries a `project_id` claim acts only in that
13464
+ * project. Without the header such a request acts in the claimed
13465
+ * project; a header naming any other project, the default project
13466
+ * included, is 403 `permission_denied`, and so is any such request
13467
+ * where Projects is not enabled for the workspace. The refusal says the
13468
+ * token is bound to another project, not what the caller's role allows.
13469
+ *
12059
13470
  */
12060
13471
  'X-Comfy-Project-ID'?: string;
12061
13472
  };
@@ -12713,6 +14124,38 @@ export type RedeemDesktopLoginCodeResponses = {
12713
14124
  200: DesktopLoginCodeRedeemResponse;
12714
14125
  };
12715
14126
  export type RedeemDesktopLoginCodeResponse = RedeemDesktopLoginCodeResponses[keyof RedeemDesktopLoginCodeResponses];
14127
+ export type CreateDesktopWebSessionData = {
14128
+ body?: never;
14129
+ path?: never;
14130
+ query?: never;
14131
+ url: '/api/auth/desktop-web-session';
14132
+ };
14133
+ export type CreateDesktopWebSessionErrors = {
14134
+ /**
14135
+ * `INVALID_CREDENTIAL`, or `oauth_grant_ended`: the grant was signed out
14136
+ */
14137
+ 401: ErrorResponse;
14138
+ /**
14139
+ * `auth_type_not_allowed` (not an OAuth access token, or a token derived from one; answered by the auth policy), `CREDENTIAL_UNSUPPORTED` (not the Desktop grant's own access token), `insufficient_scope` (no `comfy-cloud:web-session:mint`), or `web_session_unavailable` (an SSO sign-in, or no single enabled Firebase account)
14140
+ */
14141
+ 403: ErrorResponse;
14142
+ /**
14143
+ * Too many web sessions issued to this user, or too many refused, in the current clock hour
14144
+ */
14145
+ 429: ErrorResponse;
14146
+ /**
14147
+ * `desktop_web_session_disabled` (not switched on), or `SERVICE_UNAVAILABLE` (Firebase could not be reached)
14148
+ */
14149
+ 503: ErrorResponse;
14150
+ };
14151
+ export type CreateDesktopWebSessionError = CreateDesktopWebSessionErrors[keyof CreateDesktopWebSessionErrors];
14152
+ export type CreateDesktopWebSessionResponses = {
14153
+ /**
14154
+ * Custom token minted
14155
+ */
14156
+ 200: DesktopWebSessionResponse;
14157
+ };
14158
+ export type CreateDesktopWebSessionResponse = CreateDesktopWebSessionResponses[keyof CreateDesktopWebSessionResponses];
12716
14159
  export type CreateBillingHandoffData = {
12717
14160
  body: BillingHandoffCreateRequest;
12718
14161
  path?: never;
@@ -13340,8 +14783,8 @@ export type CreateBillingBudgetErrors = {
13340
14783
  404: ErrorResponse;
13341
14784
  /**
13342
14785
  * `budget_exists` (the scope already has a live budget) or
13343
- * `no_billing_period` (`repeat: current_period` on a workspace with
13344
- * no open paid subscription term).
14786
+ * `no_billing_period` (`repeat: current_period` when the budget period
14787
+ * cannot be resolved).
13345
14788
  *
13346
14789
  */
13347
14790
  409: ErrorResponse;
@@ -13453,7 +14896,7 @@ export type UpdateBillingBudgetErrors = {
13453
14896
  */
13454
14897
  404: ErrorResponse;
13455
14898
  /**
13456
- * `no_billing_period`: `repeat: current_period` on a workspace with no open paid subscription term.
14899
+ * `no_billing_period`: `repeat: current_period` when the budget period cannot be resolved.
13457
14900
  */
13458
14901
  409: ErrorResponse;
13459
14902
  /**
@@ -13518,6 +14961,38 @@ export type GetBillingBudgetHistoryResponses = {
13518
14961
  200: BudgetHistory;
13519
14962
  };
13520
14963
  export type GetBillingBudgetHistoryResponse = GetBillingBudgetHistoryResponses[keyof GetBillingBudgetHistoryResponses];
14964
+ export type ResumeHeldBudgetJobsData = {
14965
+ body?: BudgetHeldJobsResumeRequest;
14966
+ path?: never;
14967
+ query?: never;
14968
+ url: '/api/billing/budgets/held-jobs/resume';
14969
+ };
14970
+ export type ResumeHeldBudgetJobsErrors = {
14971
+ /**
14972
+ * `INVALID_REQUEST`: the body is not valid, or `job_ids` holds more than 100 ids.
14973
+ */
14974
+ 400: ErrorResponse;
14975
+ /**
14976
+ * Unauthorized
14977
+ */
14978
+ 401: ErrorResponse;
14979
+ /**
14980
+ * A refused request that changes data. For a web session, `code` is `csrf_invalid` (no `X-CSRF-Token`, or not the session's), `workspace_access_denied` (the selected workspace is unknown, deleted, or the user is not a member; the three look the same), `no_workspace_access` (the account has no personal workspace and is a member of no live workspace), `origin_not_allowed` or `cross_site_request`; see the `WebSessionAuth` scheme. For any credential, `sso_required` means an SSO organization holds the account (its email is on the organization's verified domains) and the credential is not an SSO sign-in, or the workspace is an SSO organization's and the account is not on its domains or the credential is not an SSO sign-in; `organization_id`, when present, names the organization to sign in with. `account_outside_organization` means the workspace is an SSO organization's and the account is on none of its domains, so no sign-in admits it; `organization_id` names the workspace's organization. `personal_workspace_disabled` means the workspace is the account's personal one and an SSO organization holds the account, so it cannot use it; `organization_id` names that organization. `FORBIDDEN` is the route's own authorization check failing, such as an unverified email, or, on `POST /api/workspaces`, an account an SSO organization holds (its organization manages its workspaces; signing in again does not change it). On the plan-lifecycle writes (`POST /api/billing/subscribe`, `POST /api/billing/subscription/cancel`, `POST /api/billing/subscription/resubscribe`, `POST /api/billing/subscription/revert-scheduled-change`, `POST /api/billing/ops/{id}/cancel` and the `/api/billing/retention*` routes), `NOT_ORIGINAL_OWNER` means the caller is an owner but not the workspace's creator, and only the creator may change the plan; it is returned only when the rollout mode is `creator`. A credential this route does not take gets AuthTypeNotAllowedError instead, and so does the session while `web_session_enabled` is off for the user, unless the operation says it takes the session whatever the flag.
14981
+ */
14982
+ 403: ForbiddenError;
14983
+ /**
14984
+ * Internal server error
14985
+ */
14986
+ 500: ErrorResponse;
14987
+ };
14988
+ export type ResumeHeldBudgetJobsError = ResumeHeldBudgetJobsErrors[keyof ResumeHeldBudgetJobsErrors];
14989
+ export type ResumeHeldBudgetJobsResponses = {
14990
+ /**
14991
+ * What happened to each selected job.
14992
+ */
14993
+ 200: BudgetHeldJobsResumeResult;
14994
+ };
14995
+ export type ResumeHeldBudgetJobsResponse = ResumeHeldBudgetJobsResponses[keyof ResumeHeldBudgetJobsResponses];
13521
14996
  export type GetBillingCapabilitiesData = {
13522
14997
  body?: never;
13523
14998
  path?: never;
@@ -13986,6 +15461,30 @@ export type PreviewSubscribeResponses = {
13986
15461
  200: PreviewSubscribeResponse;
13987
15462
  };
13988
15463
  export type PreviewSubscribeResponse2 = PreviewSubscribeResponses[keyof PreviewSubscribeResponses];
15464
+ export type GetBillingPromotionData = {
15465
+ body?: never;
15466
+ path?: never;
15467
+ query?: never;
15468
+ url: '/api/billing/promotion';
15469
+ };
15470
+ export type GetBillingPromotionErrors = {
15471
+ /**
15472
+ * `code` is `workspace_id_invalid`: the `X-Comfy-Workspace-ID` header or `workspace_id` query value is malformed, or conflicts with another value or with the workspace the credential resolves to. Answered only while `web_session_enabled` is on for the user. See the `WebSessionAuth` scheme.
15473
+ */
15474
+ 400: ErrorResponse;
15475
+ /**
15476
+ * `code` is `workspace_access_denied`: the selected workspace is unknown, deleted, or the user is not a member; the three look the same. This route also serves anonymous callers, so the session's other refusals fall back to an anonymous request. See the `WebSessionAuth` scheme.
15477
+ */
15478
+ 403: ErrorResponse;
15479
+ };
15480
+ export type GetBillingPromotionError = GetBillingPromotionErrors[keyof GetBillingPromotionErrors];
15481
+ export type GetBillingPromotionResponses = {
15482
+ /**
15483
+ * The promotion running right now, or null
15484
+ */
15485
+ 200: BillingPromotionResponse;
15486
+ };
15487
+ export type GetBillingPromotionResponse = GetBillingPromotionResponses[keyof GetBillingPromotionResponses];
13989
15488
  export type AcceptRetentionOfferData = {
13990
15489
  body: RetentionAcceptRequest;
13991
15490
  path?: never;
@@ -14308,6 +15807,10 @@ export type CreateTopupErrors = {
14308
15807
  * Internal server error
14309
15808
  */
14310
15809
  500: ErrorResponse;
15810
+ /**
15811
+ * `BILLING_SERVICE_ERROR`: billing could not decide the top-up right now (for example, the workspace's top-up limit could not be read); no billing operation was created. Retry after `Retry-After`.
15812
+ */
15813
+ 503: ErrorResponse;
14311
15814
  };
14312
15815
  export type CreateTopupError = CreateTopupErrors[keyof CreateTopupErrors];
14313
15816
  export type CreateTopupResponses = {
@@ -14628,6 +16131,10 @@ export type CreateTopupQuoteErrors = {
14628
16131
  * Internal server error
14629
16132
  */
14630
16133
  500: ErrorResponse;
16134
+ /**
16135
+ * `BILLING_SERVICE_ERROR`: billing could not quote right now (for example, the workspace's top-up limit could not be read). Retry after `Retry-After`.
16136
+ */
16137
+ 503: ErrorResponse;
14631
16138
  };
14632
16139
  export type CreateTopupQuoteError = CreateTopupQuoteErrors[keyof CreateTopupQuoteErrors];
14633
16140
  export type CreateTopupQuoteResponses = {
@@ -14655,7 +16162,8 @@ export type GetBillingUsageTimeSeriesData = {
14655
16162
  * `not_available` set. For every workspace `product_line` and
14656
16163
  * `model` are read from the ledger when the range starts on or
14657
16164
  * after the environment's ledger start, and from the invoice otherwise; a model the
14658
- * ledger has no name for is `unspecified`. Under Serverless the model
16165
+ * ledger has no name for is `unspecified/<api_name>` when its charges
16166
+ * name their partner and `unspecified` otherwise. Under Serverless the model
14659
16167
  * level is the deployment: `<deployment id>` for its GPU time and
14660
16168
  * `<deployment id>/storage` for its storage, each with a
14661
16169
  * `group_labels` entry naming the deployment and the `cost_kind`. Group keys for
@@ -14682,7 +16190,7 @@ export type GetBillingUsageTimeSeriesData = {
14682
16190
  */
14683
16191
  filter_product_line?: string;
14684
16192
  /**
14685
- * Keep only spend on this model (a key the `model` grouping returns, `unspecified` for none). See `filter_product_line`.
16193
+ * Keep only spend on this model (a key the `model` grouping returns, `unspecified/<api_name>` or `unspecified` for none). See `filter_product_line`.
14686
16194
  */
14687
16195
  filter_model?: string;
14688
16196
  /**
@@ -14693,6 +16201,35 @@ export type GetBillingUsageTimeSeriesData = {
14693
16201
  * Keep only spend from this source (a key the `source` grouping returns, or `unattributed`), or every source of one kind (`api_key` for every API key, `deployment` for every deployment). See `filter_product_line`.
14694
16202
  */
14695
16203
  filter_source?: string;
16204
+ /**
16205
+ * Keep one project's usage: a project id (`p-<uuid>`), `default` for
16206
+ * the workspace's default project (its own id reads as `default`), or
16207
+ * `unallocated` for deployment spend that no project's deployments
16208
+ * account for. Read only in a team workspace where Projects is on;
16209
+ * elsewhere it is ignored and the answer is the workspace's.
16210
+ *
16211
+ * A project read is served from the usage ledger only, for the
16212
+ * `product_line`, `model`, `person` and `source` groupings of a
16213
+ * workspace enabled for usage attribution; any other read answers an
16214
+ * empty series with `not_available` reason `filter_needs_ledger`.
16215
+ * Deployment spend is placed by the project's deployments, which the
16216
+ * server lists from the deployment service, deleted ones included.
16217
+ * Where it cannot list them, or the list is over 1,000, the answer is
16218
+ * an empty series with `not_available` reason
16219
+ * `deployments_unavailable` or `too_many_deployments`, never a
16220
+ * partial number.
16221
+ *
16222
+ * Owners and Workspace admins may read any project and
16223
+ * `unallocated`. A Project admin reads their project whole. Anyone
16224
+ * else reads only their own rows in the project. `unallocated` is
16225
+ * refused (403 `permission_denied`) to anyone but an owner or
16226
+ * Workspace admin; offer it only when GET /api/billing/capabilities
16227
+ * answers `can_view_unallocated_usage` true. A project id that is malformed is 400
16228
+ * `project_id_invalid`; one that is not in the workspace, or that the
16229
+ * caller may not view, is 404 `not_found`.
16230
+ *
16231
+ */
16232
+ project?: string;
14696
16233
  granularity?: 'hour' | 'day' | 'month';
14697
16234
  starting_on?: string;
14698
16235
  ending_before?: string;
@@ -14702,7 +16239,7 @@ export type GetBillingUsageTimeSeriesData = {
14702
16239
  };
14703
16240
  export type GetBillingUsageTimeSeriesErrors = {
14704
16241
  /**
14705
- * Invalid time range or filter value
16242
+ * Invalid time range, filter value or project id
14706
16243
  */
14707
16244
  400: ErrorResponse;
14708
16245
  /**
@@ -14713,6 +16250,10 @@ export type GetBillingUsageTimeSeriesErrors = {
14713
16250
  * A refused request. For a web session, `code` is `workspace_access_denied` (the selected workspace is unknown, deleted, or the user is not a member; the three look the same), `no_workspace_access` (the account has no personal workspace and is a member of no live workspace), `origin_not_allowed` or `cross_site_request`; see the `WebSessionAuth` scheme. For any credential, `sso_required` means an SSO organization holds the account (its email is on the organization's verified domains) and the credential is not an SSO sign-in, or the workspace is an SSO organization's and the account is not on its domains or the credential is not an SSO sign-in; `organization_id`, when present, names the organization to sign in with. `account_outside_organization` means the workspace is an SSO organization's and the account is on none of its domains, so no sign-in admits it; `organization_id` names the workspace's organization. `personal_workspace_disabled` means the workspace is the account's personal one and an SSO organization holds the account, so it cannot use it; `organization_id` names that organization. `FORBIDDEN` is the route's own authorization check failing, such as an unverified email. On `GET /api/billing/churnkey/auth`, `NOT_ORIGINAL_OWNER` means the caller is not the workspace's creator; it is returned only when the rollout mode is `creator`. A credential this route does not take gets AuthTypeNotAllowedError instead, and so does the session while `web_session_enabled` is off for the user, unless the operation says it takes the session whatever `web_session_enabled` says.
14714
16251
  */
14715
16252
  403: ForbiddenError;
16253
+ /**
16254
+ * The project `project` names is not in the workspace, or the caller may not view it (`not_found`)
16255
+ */
16256
+ 404: ErrorResponse;
14716
16257
  /**
14717
16258
  * Upstream or internal error
14718
16259
  */
@@ -14893,6 +16434,36 @@ export type GetEmbeddingsResponses = {
14893
16434
  export type GetEmbeddingsResponse = GetEmbeddingsResponses[keyof GetEmbeddingsResponses];
14894
16435
  export type GetModelFoldersData = {
14895
16436
  body?: never;
16437
+ headers?: {
16438
+ /**
16439
+ * The project a request acts in. The operations that list it are the
16440
+ * ones that read it: they list workflows, runs or assets, create one,
16441
+ * export assets, clear the caller's queue or History, pick the
16442
+ * deployment a browser runs on, or serve the editor that deployment
16443
+ * (the node, extension and model lists). Absent means
16444
+ * the workspace's default project, which is how existing clients keep
16445
+ * working.
16446
+ *
16447
+ * An operation on one existing workflow, run or asset does not take
16448
+ * it: the row's own project decides. Any other operation that creates
16449
+ * a workflow, run or asset acts in the default project until it lists
16450
+ * this parameter.
16451
+ *
16452
+ * The project must be in the workspace the request resolves to. A
16453
+ * project that does not exist, or that the caller may not view, is 404
16454
+ * `not_found`; the two look the same. Where Projects is not enabled for
16455
+ * the workspace the header is ignored.
16456
+ *
16457
+ * A Cloud JWT that carries a `project_id` claim acts only in that
16458
+ * project. Without the header such a request acts in the claimed
16459
+ * project; a header naming any other project, the default project
16460
+ * included, is 403 `permission_denied`, and so is any such request
16461
+ * where Projects is not enabled for the workspace. The refusal says the
16462
+ * token is bound to another project, not what the caller's role allows.
16463
+ *
16464
+ */
16465
+ 'X-Comfy-Project-ID'?: string;
16466
+ };
14896
16467
  path?: never;
14897
16468
  query?: never;
14898
16469
  url: '/api/experiment/models';
@@ -14906,6 +16477,10 @@ export type GetModelFoldersErrors = {
14906
16477
  * `code` is `workspace_access_denied`: the selected workspace is unknown, deleted, or the user is not a member; the three look the same. This route also serves anonymous callers, so the session's other refusals fall back to an anonymous request. See the `WebSessionAuth` scheme.
14907
16478
  */
14908
16479
  403: ErrorResponse;
16480
+ /**
16481
+ * The project `X-Comfy-Project-ID` names does not exist or the caller may not view it (`not_found`)
16482
+ */
16483
+ 404: ErrorResponse;
14909
16484
  /**
14910
16485
  * Internal server error
14911
16486
  */
@@ -14921,6 +16496,36 @@ export type GetModelFoldersResponses = {
14921
16496
  export type GetModelFoldersResponse = GetModelFoldersResponses[keyof GetModelFoldersResponses];
14922
16497
  export type GetModelsInFolderData = {
14923
16498
  body?: never;
16499
+ headers?: {
16500
+ /**
16501
+ * The project a request acts in. The operations that list it are the
16502
+ * ones that read it: they list workflows, runs or assets, create one,
16503
+ * export assets, clear the caller's queue or History, pick the
16504
+ * deployment a browser runs on, or serve the editor that deployment
16505
+ * (the node, extension and model lists). Absent means
16506
+ * the workspace's default project, which is how existing clients keep
16507
+ * working.
16508
+ *
16509
+ * An operation on one existing workflow, run or asset does not take
16510
+ * it: the row's own project decides. Any other operation that creates
16511
+ * a workflow, run or asset acts in the default project until it lists
16512
+ * this parameter.
16513
+ *
16514
+ * The project must be in the workspace the request resolves to. A
16515
+ * project that does not exist, or that the caller may not view, is 404
16516
+ * `not_found`; the two look the same. Where Projects is not enabled for
16517
+ * the workspace the header is ignored.
16518
+ *
16519
+ * A Cloud JWT that carries a `project_id` claim acts only in that
16520
+ * project. Without the header such a request acts in the claimed
16521
+ * project; a header naming any other project, the default project
16522
+ * included, is 403 `permission_denied`, and so is any such request
16523
+ * where Projects is not enabled for the workspace. The refusal says the
16524
+ * token is bound to another project, not what the caller's role allows.
16525
+ *
16526
+ */
16527
+ 'X-Comfy-Project-ID'?: string;
16528
+ };
14924
16529
  path: {
14925
16530
  /**
14926
16531
  * The folder name to list models from
@@ -14940,7 +16545,7 @@ export type GetModelsInFolderErrors = {
14940
16545
  */
14941
16546
  403: ErrorResponse;
14942
16547
  /**
14943
- * Folder not found or no models in folder
16548
+ * Folder not found or no models in folder; or `code` `not_found` for a project `X-Comfy-Project-ID` names that does not exist or that the caller may not view
14944
16549
  */
14945
16550
  404: ErrorResponse;
14946
16551
  /**
@@ -15046,6 +16651,36 @@ export type GetNodeByIdResponses = {
15046
16651
  };
15047
16652
  export type GetExtensionsData = {
15048
16653
  body?: never;
16654
+ headers?: {
16655
+ /**
16656
+ * The project a request acts in. The operations that list it are the
16657
+ * ones that read it: they list workflows, runs or assets, create one,
16658
+ * export assets, clear the caller's queue or History, pick the
16659
+ * deployment a browser runs on, or serve the editor that deployment
16660
+ * (the node, extension and model lists). Absent means
16661
+ * the workspace's default project, which is how existing clients keep
16662
+ * working.
16663
+ *
16664
+ * An operation on one existing workflow, run or asset does not take
16665
+ * it: the row's own project decides. Any other operation that creates
16666
+ * a workflow, run or asset acts in the default project until it lists
16667
+ * this parameter.
16668
+ *
16669
+ * The project must be in the workspace the request resolves to. A
16670
+ * project that does not exist, or that the caller may not view, is 404
16671
+ * `not_found`; the two look the same. Where Projects is not enabled for
16672
+ * the workspace the header is ignored.
16673
+ *
16674
+ * A Cloud JWT that carries a `project_id` claim acts only in that
16675
+ * project. Without the header such a request acts in the claimed
16676
+ * project; a header naming any other project, the default project
16677
+ * included, is 403 `permission_denied`, and so is any such request
16678
+ * where Projects is not enabled for the workspace. The refusal says the
16679
+ * token is bound to another project, not what the caller's role allows.
16680
+ *
16681
+ */
16682
+ 'X-Comfy-Project-ID'?: string;
16683
+ };
15049
16684
  path?: never;
15050
16685
  query?: never;
15051
16686
  url: '/api/extensions';
@@ -15059,6 +16694,10 @@ export type GetExtensionsErrors = {
15059
16694
  * `code` is `workspace_access_denied`: the selected workspace is unknown, deleted, or the user is not a member; the three look the same. This route also serves anonymous callers, so the session's other refusals fall back to an anonymous request. See the `WebSessionAuth` scheme.
15060
16695
  */
15061
16696
  403: ErrorResponse;
16697
+ /**
16698
+ * The project `X-Comfy-Project-ID` names does not exist or the caller may not view it (`not_found`)
16699
+ */
16700
+ 404: ErrorResponse;
15062
16701
  };
15063
16702
  export type GetExtensionsError = GetExtensionsErrors[keyof GetExtensionsErrors];
15064
16703
  export type GetExtensionsResponses = {
@@ -15101,18 +16740,15 @@ export type GetFeaturesResponses = {
15101
16740
  */
15102
16741
  'agent-credit-usage-summary'?: 'control' | 'treatment';
15103
16742
  /**
15104
- * Authenticated assignment for the Agent free-use notice placement experiment. Current Cloud responses include it and default to control when the caller is unauthenticated, evaluation is unavailable, or no treatment is assigned. It remains optional in the client contract, as agent-starter-prompt-set does, so older environments mid-rolling-deploy and partial feature fixtures fail closed rather than decoding an absent field as the empty string, which is not a member of this enum.
16743
+ * Authenticated assignment for the Agent free-use notice placement experiment. Current Cloud responses include it and default to control when the caller is unauthenticated, evaluation is unavailable, or no treatment is assigned. It remains optional in the client contract so older environments mid-rolling-deploy and partial feature fixtures fail closed rather than decoding an absent field as the empty string, which is not a member of this enum.
15105
16744
  */
15106
16745
  'agent-free-use-message-placement'?: 'control' | 'top-banner' | 'near-composer' | 'above-input' | 'inside-input';
15107
- /**
15108
- * Authenticated assignment for the Agent starter-prompt experiment. Current Cloud responses include it and default to control when the caller is unauthenticated, evaluation is unavailable, or no treatment is assigned. It remains optional in the client contract so older environments and partial feature fixtures fail closed. Reading this field does not constitute experiment exposure; the frontend emits the custom exposure event only after rendering the starter prompt surface.
15109
- */
15110
- 'agent-starter-prompt-set'?: 'control' | 'test';
15111
16746
  /**
15112
16747
  * The signed-in caller's arm in the local agent free-credit experiment (PostHog flag agent-gratis-cents-local-experiment): control or treatment. It answers which arm the caller is in, not whether credit has been granted, and does not depend on the grant being issued.
15113
16748
  * Absent, never null or empty, when no arm is resolved: unauthenticated callers, a failed or unavailable flag evaluation, or no variant assigned yet. It has no default; a consumer treats absence as "no arm known" and shows no free-credit surface, without recording the caller as outside the experiment. Served on this HTTP response only, never in the WebSocket feature_flags push, and dynamic configuration cannot set it.
15114
16749
  */
15115
16750
  agent_gratis_local_arm?: 'control' | 'treatment';
16751
+ agent_proactive_greeting_assignment?: AgentProactiveGreetingAssignment;
15116
16752
  /**
15117
16753
  * Origin of the billing-web deployment paired with this Cloud environment (e.g. https://billing.comfy.org). Absent when BILLING_WEB_URL is not configured on the server, so a client can tell "not configured" from "configured as empty".
15118
16754
  */
@@ -15189,6 +16825,14 @@ export type GetFeaturesResponses = {
15189
16825
  * Whether this environment advertises the authenticated private saved-workflow UUID link contract (?workflow=UUID&workspace=ID, with deployment=ID for a custom environment or environment=standard). Absent or false means unsupported. Published only from an explicit boolean FrontendFeatureFlags dynamic-config entry, enabled by an operator after the matching frontend release. This describes URL support, not workflow access or deployment eligibility; those remain authenticated checks. No default configuration enables it.
15190
16826
  */
15191
16827
  private_workflow_links_enabled?: boolean;
16828
+ /**
16829
+ * Served assignment for the prompt editor surface experiment: where the text widget's Expand opens a long prompt. Control opens a centred dialog; panel opens the prompt in the right side panel. It is omitted while the flag is inactive, evaluation is unavailable, the caller is anonymous, or no valid assignment is present, so clients cannot mistake the off state for a randomized control. Reading this field is not exposure; the frontend records exposure on the first Expand.
16830
+ */
16831
+ 'prompt-editor-surface'?: 'control' | 'panel';
16832
+ /**
16833
+ * Local ComfyUI only: a random id that is new on every server start. A client that reconnects and gets a different value knows the server restarted, so node definitions it loaded earlier may be stale. Not settable with --feature-flag.
16834
+ */
16835
+ server_boot_id?: string;
15192
16836
  /**
15193
16837
  * Global switch, the same for every caller and readable without credentials. When true, the frontend shows enterprise single sign-on (the SSO sign-in entry and SSO workspace states); when false it shows today's app. It gates no backend behaviour. Defaults to false.
15194
16838
  */
@@ -15507,6 +17151,36 @@ export type GetLegacyHistoryErrors = {
15507
17151
  };
15508
17152
  export type ManageHistoryData = {
15509
17153
  body: HistoryManageRequest;
17154
+ headers?: {
17155
+ /**
17156
+ * The project a request acts in. The operations that list it are the
17157
+ * ones that read it: they list workflows, runs or assets, create one,
17158
+ * export assets, clear the caller's queue or History, pick the
17159
+ * deployment a browser runs on, or serve the editor that deployment
17160
+ * (the node, extension and model lists). Absent means
17161
+ * the workspace's default project, which is how existing clients keep
17162
+ * working.
17163
+ *
17164
+ * An operation on one existing workflow, run or asset does not take
17165
+ * it: the row's own project decides. Any other operation that creates
17166
+ * a workflow, run or asset acts in the default project until it lists
17167
+ * this parameter.
17168
+ *
17169
+ * The project must be in the workspace the request resolves to. A
17170
+ * project that does not exist, or that the caller may not view, is 404
17171
+ * `not_found`; the two look the same. Where Projects is not enabled for
17172
+ * the workspace the header is ignored.
17173
+ *
17174
+ * A Cloud JWT that carries a `project_id` claim acts only in that
17175
+ * project. Without the header such a request acts in the claimed
17176
+ * project; a header naming any other project, the default project
17177
+ * included, is 403 `permission_denied`, and so is any such request
17178
+ * where Projects is not enabled for the workspace. The refusal says the
17179
+ * token is bound to another project, not what the caller's role allows.
17180
+ *
17181
+ */
17182
+ 'X-Comfy-Project-ID'?: string;
17183
+ };
15510
17184
  path?: never;
15511
17185
  query?: never;
15512
17186
  url: '/api/history';
@@ -15524,6 +17198,10 @@ export type ManageHistoryErrors = {
15524
17198
  * A refused request that changes data. For a web session, `code` is `csrf_invalid` (no `X-CSRF-Token`, or not the session's), `workspace_access_denied` (the selected workspace is unknown, deleted, or the user is not a member; the three look the same), `no_workspace_access` (the account has no personal workspace and is a member of no live workspace), `origin_not_allowed` or `cross_site_request`; see the `WebSessionAuth` scheme. For any credential, `sso_required` means an SSO organization holds the account (its email is on the organization's verified domains) and the credential is not an SSO sign-in, or the workspace is an SSO organization's and the account is not on its domains or the credential is not an SSO sign-in; `organization_id`, when present, names the organization to sign in with. `account_outside_organization` means the workspace is an SSO organization's and the account is on none of its domains, so no sign-in admits it; `organization_id` names the workspace's organization. `personal_workspace_disabled` means the workspace is the account's personal one and an SSO organization holds the account, so it cannot use it; `organization_id` names that organization. `FORBIDDEN` is the route's own authorization check failing, such as an unverified email, or, on `POST /api/workspaces`, an account an SSO organization holds (its organization manages its workspaces; signing in again does not change it). On the plan-lifecycle writes (`POST /api/billing/subscribe`, `POST /api/billing/subscription/cancel`, `POST /api/billing/subscription/resubscribe`, `POST /api/billing/subscription/revert-scheduled-change`, `POST /api/billing/ops/{id}/cancel` and the `/api/billing/retention*` routes), `NOT_ORIGINAL_OWNER` means the caller is an owner but not the workspace's creator, and only the creator may change the plan; it is returned only when the rollout mode is `creator`. A credential this route does not take gets AuthTypeNotAllowedError instead, and so does the session while `web_session_enabled` is off for the user, unless the operation says it takes the session whatever the flag.
15525
17199
  */
15526
17200
  403: ForbiddenError;
17201
+ /**
17202
+ * The project `X-Comfy-Project-ID` names does not exist or the caller may not view it (`not_found`)
17203
+ */
17204
+ 404: ErrorResponse;
15527
17205
  /**
15528
17206
  * Internal server error
15529
17207
  */
@@ -16152,6 +17830,36 @@ export type CreateInputUploadUrlResponses = {
16152
17830
  export type CreateInputUploadUrlResponse = CreateInputUploadUrlResponses[keyof CreateInputUploadUrlResponses];
16153
17831
  export type InterruptJobData = {
16154
17832
  body?: never;
17833
+ headers?: {
17834
+ /**
17835
+ * The project a request acts in. The operations that list it are the
17836
+ * ones that read it: they list workflows, runs or assets, create one,
17837
+ * export assets, clear the caller's queue or History, pick the
17838
+ * deployment a browser runs on, or serve the editor that deployment
17839
+ * (the node, extension and model lists). Absent means
17840
+ * the workspace's default project, which is how existing clients keep
17841
+ * working.
17842
+ *
17843
+ * An operation on one existing workflow, run or asset does not take
17844
+ * it: the row's own project decides. Any other operation that creates
17845
+ * a workflow, run or asset acts in the default project until it lists
17846
+ * this parameter.
17847
+ *
17848
+ * The project must be in the workspace the request resolves to. A
17849
+ * project that does not exist, or that the caller may not view, is 404
17850
+ * `not_found`; the two look the same. Where Projects is not enabled for
17851
+ * the workspace the header is ignored.
17852
+ *
17853
+ * A Cloud JWT that carries a `project_id` claim acts only in that
17854
+ * project. Without the header such a request acts in the claimed
17855
+ * project; a header naming any other project, the default project
17856
+ * included, is 403 `permission_denied`, and so is any such request
17857
+ * where Projects is not enabled for the workspace. The refusal says the
17858
+ * token is bound to another project, not what the caller's role allows.
17859
+ *
17860
+ */
17861
+ 'X-Comfy-Project-ID'?: string;
17862
+ };
16155
17863
  path?: never;
16156
17864
  query?: never;
16157
17865
  url: '/api/interrupt';
@@ -16172,7 +17880,8 @@ export type InterruptJobErrors = {
16172
17880
  /**
16173
17881
  * `prompt_id` is not one of the caller's jobs in this workspace, or
16174
17882
  * is not a job ID (a 36-character UUID) at all. Code NOT_FOUND;
16175
- * nothing was cancelled.
17883
+ * nothing was cancelled. Or the project `X-Comfy-Project-ID` names
17884
+ * does not exist or the caller may not view it (`not_found`).
16176
17885
  *
16177
17886
  */
16178
17887
  404: ErrorResponse;
@@ -16305,9 +18014,12 @@ export type ListJobsData = {
16305
18014
  headers?: {
16306
18015
  /**
16307
18016
  * The project a request acts in. The operations that list it are the
16308
- * ones that read it: they list workflows, runs or assets, or create
16309
- * one. Absent means the workspace's default project, which is how
16310
- * existing clients keep working.
18017
+ * ones that read it: they list workflows, runs or assets, create one,
18018
+ * export assets, clear the caller's queue or History, pick the
18019
+ * deployment a browser runs on, or serve the editor that deployment
18020
+ * (the node, extension and model lists). Absent means
18021
+ * the workspace's default project, which is how existing clients keep
18022
+ * working.
16311
18023
  *
16312
18024
  * An operation on one existing workflow, run or asset does not take
16313
18025
  * it: the row's own project decides. Any other operation that creates
@@ -16319,13 +18031,20 @@ export type ListJobsData = {
16319
18031
  * `not_found`; the two look the same. Where Projects is not enabled for
16320
18032
  * the workspace the header is ignored.
16321
18033
  *
18034
+ * A Cloud JWT that carries a `project_id` claim acts only in that
18035
+ * project. Without the header such a request acts in the claimed
18036
+ * project; a header naming any other project, the default project
18037
+ * included, is 403 `permission_denied`, and so is any such request
18038
+ * where Projects is not enabled for the workspace. The refusal says the
18039
+ * token is bound to another project, not what the caller's role allows.
18040
+ *
16322
18041
  */
16323
18042
  'X-Comfy-Project-ID'?: string;
16324
18043
  };
16325
18044
  path?: never;
16326
18045
  query?: {
16327
18046
  /**
16328
- * Filter by one or more statuses (comma-separated). If not provided, returns all jobs.
18047
+ * Filter by one or more statuses (comma-separated). Use held_budget for jobs paused by a budget decision. Omit to return all jobs.
16329
18048
  */
16330
18049
  status?: string;
16331
18050
  /**
@@ -16433,11 +18152,11 @@ export type DeleteJobErrors = {
16433
18152
  */
16434
18153
  403: ForbiddenError;
16435
18154
  /**
16436
- * Job not found or does not belong to the user
18155
+ * Job not found, does not belong to the user, or is in a project where the caller may not delete it
16437
18156
  */
16438
18157
  404: ErrorResponse;
16439
18158
  /**
16440
- * A linked asset cannot be deleted because it is referenced by another resource, e.g. a workflow version (error code: ASSET_IN_USE); the job is left in place
18159
+ * A linked asset cannot be deleted because it is referenced by another resource, e.g. a workflow version, or because content moderation still holds it (error code: ASSET_IN_USE for both; a moderation hold is deliberately not distinguishable); the job and every linked asset are left in place
16441
18160
  */
16442
18161
  409: ErrorResponse;
16443
18162
  /**
@@ -16463,7 +18182,7 @@ export type GetJobDetailData = {
16463
18182
  };
16464
18183
  query?: {
16465
18184
  /**
16466
- * When present, each output item in the response receives a `short_url` field containing a short link for that asset. Omit this parameter (the default) to receive a response identical to the no-param baseline. The value selects the link's lifetime and auth model: use `ephemeral_tool_chain` for short-lived (≤5 minute) machine-to-machine handoffs — these are public bearer links where the link ID itself is the credential, so anyone holding the link can resolve it (intended for pasting into an agent/MCP tool chain); use `default` for durable (30 day) human-revisitable links, which are owner-gated and resolvable only by the authenticated owner. Links are always minted under the authenticated request owner's identity; the auth model is selected by the server and is never settable by the caller.
18185
+ * When present, each output item in the response receives a `short_url` field containing a short link for that asset. Omit this parameter (the default) to receive a response identical to the no-param baseline. The value selects the link's lifetime and auth model: use `ephemeral_tool_chain` for short-lived (≤5 minute) machine-to-machine handoffs — these are public bearer links where the link ID itself is the credential, so anyone holding the link can resolve it (intended for pasting into an agent/MCP tool chain); use `default` for durable (30 day) human-revisitable links, which are owner-gated and resolvable only by the authenticated owner. Links are always minted under the authenticated request owner's identity; the auth model is selected by the server and is never settable by the caller. A run in a project other than the default gets no `short_url` whatever the value: its outputs have no short link.
16467
18186
  *
16468
18187
  */
16469
18188
  short_link?: 'ephemeral_tool_chain' | 'default';
@@ -16677,6 +18396,36 @@ export type GetNodeReplacementsResponses = {
16677
18396
  export type GetNodeReplacementsResponse = GetNodeReplacementsResponses[keyof GetNodeReplacementsResponses];
16678
18397
  export type GetNodeInfoData = {
16679
18398
  body?: never;
18399
+ headers?: {
18400
+ /**
18401
+ * The project a request acts in. The operations that list it are the
18402
+ * ones that read it: they list workflows, runs or assets, create one,
18403
+ * export assets, clear the caller's queue or History, pick the
18404
+ * deployment a browser runs on, or serve the editor that deployment
18405
+ * (the node, extension and model lists). Absent means
18406
+ * the workspace's default project, which is how existing clients keep
18407
+ * working.
18408
+ *
18409
+ * An operation on one existing workflow, run or asset does not take
18410
+ * it: the row's own project decides. Any other operation that creates
18411
+ * a workflow, run or asset acts in the default project until it lists
18412
+ * this parameter.
18413
+ *
18414
+ * The project must be in the workspace the request resolves to. A
18415
+ * project that does not exist, or that the caller may not view, is 404
18416
+ * `not_found`; the two look the same. Where Projects is not enabled for
18417
+ * the workspace the header is ignored.
18418
+ *
18419
+ * A Cloud JWT that carries a `project_id` claim acts only in that
18420
+ * project. Without the header such a request acts in the claimed
18421
+ * project; a header naming any other project, the default project
18422
+ * included, is 403 `permission_denied`, and so is any such request
18423
+ * where Projects is not enabled for the workspace. The refusal says the
18424
+ * token is bound to another project, not what the caller's role allows.
18425
+ *
18426
+ */
18427
+ 'X-Comfy-Project-ID'?: string;
18428
+ };
16680
18429
  path?: never;
16681
18430
  query?: {
16682
18431
  /**
@@ -16706,6 +18455,10 @@ export type GetNodeInfoErrors = {
16706
18455
  * A refused request. For a web session, `code` is `workspace_access_denied` (the selected workspace is unknown, deleted, or the user is not a member; the three look the same), `no_workspace_access` (the account has no personal workspace and is a member of no live workspace), `origin_not_allowed` or `cross_site_request`; see the `WebSessionAuth` scheme. For any credential, `sso_required` means an SSO organization holds the account (its email is on the organization's verified domains) and the credential is not an SSO sign-in, or the workspace is an SSO organization's and the account is not on its domains or the credential is not an SSO sign-in; `organization_id`, when present, names the organization to sign in with. `account_outside_organization` means the workspace is an SSO organization's and the account is on none of its domains, so no sign-in admits it; `organization_id` names the workspace's organization. `personal_workspace_disabled` means the workspace is the account's personal one and an SSO organization holds the account, so it cannot use it; `organization_id` names that organization. `FORBIDDEN` is the route's own authorization check failing, such as an unverified email. On `GET /api/billing/churnkey/auth`, `NOT_ORIGINAL_OWNER` means the caller is not the workspace's creator; it is returned only when the rollout mode is `creator`. A credential this route does not take gets AuthTypeNotAllowedError instead, and so does the session while `web_session_enabled` is off for the user, unless the operation says it takes the session whatever `web_session_enabled` says.
16707
18456
  */
16708
18457
  403: ForbiddenError;
18458
+ /**
18459
+ * The project `X-Comfy-Project-ID` names does not exist or the caller may not view it (`not_found`)
18460
+ */
18461
+ 404: ErrorResponse;
16709
18462
  };
16710
18463
  export type GetNodeInfoError = GetNodeInfoErrors[keyof GetNodeInfoErrors];
16711
18464
  export type GetNodeInfoResponses = {
@@ -17069,9 +18822,12 @@ export type ExecutePromptData = {
17069
18822
  headers?: {
17070
18823
  /**
17071
18824
  * The project a request acts in. The operations that list it are the
17072
- * ones that read it: they list workflows, runs or assets, or create
17073
- * one. Absent means the workspace's default project, which is how
17074
- * existing clients keep working.
18825
+ * ones that read it: they list workflows, runs or assets, create one,
18826
+ * export assets, clear the caller's queue or History, pick the
18827
+ * deployment a browser runs on, or serve the editor that deployment
18828
+ * (the node, extension and model lists). Absent means
18829
+ * the workspace's default project, which is how existing clients keep
18830
+ * working.
17075
18831
  *
17076
18832
  * An operation on one existing workflow, run or asset does not take
17077
18833
  * it: the row's own project decides. Any other operation that creates
@@ -17083,8 +18839,19 @@ export type ExecutePromptData = {
17083
18839
  * `not_found`; the two look the same. Where Projects is not enabled for
17084
18840
  * the workspace the header is ignored.
17085
18841
  *
18842
+ * A Cloud JWT that carries a `project_id` claim acts only in that
18843
+ * project. Without the header such a request acts in the claimed
18844
+ * project; a header naming any other project, the default project
18845
+ * included, is 403 `permission_denied`, and so is any such request
18846
+ * where Projects is not enabled for the workspace. The refusal says the
18847
+ * token is bound to another project, not what the caller's role allows.
18848
+ *
17086
18849
  */
17087
18850
  'X-Comfy-Project-ID'?: string;
18851
+ /**
18852
+ * The Release the editor loaded its node list from, for a browser that picked a developer-platform deployment. When the deployment runs another Release now, the submission is refused with a 409 `RELEASE_CHANGED` before its workflow is validated, and nothing is queued. Without it the submission is answered as before.
18853
+ */
18854
+ 'Comfy-Loaded-Release'?: string;
17088
18855
  };
17089
18856
  path?: never;
17090
18857
  query?: never;
@@ -17092,7 +18859,7 @@ export type ExecutePromptData = {
17092
18859
  };
17093
18860
  export type ExecutePromptErrors = {
17094
18861
  /**
17095
- * Invalid prompt, or `code` `workspace_id_invalid` (see SessionWorkspaceIDInvalid).
18862
+ * Invalid prompt, or `code` `workspace_id_invalid` (see SessionWorkspaceIDInvalid). An `error` whose `details` is `deployment_not_permitted` says the run's project may not use the target, and nothing ran: `error.deployment_id` names a picked deployment that belongs to another project, and `error.target` `shared_cloud` says the project does not run on Comfy Cloud. The caller picks another target. It says nothing about the caller's role.
17096
18863
  */
17097
18864
  400: PromptErrorResponse;
17098
18865
  /**
@@ -17100,13 +18867,17 @@ export type ExecutePromptErrors = {
17100
18867
  */
17101
18868
  401: ErrorResponse;
17102
18869
  /**
17103
- * The account's plan does not allow this submission; nothing was queued and retrying without changing the plan never succeeds. Disambiguated by the body's `error.type`, NOT by parsing `error.message`: `PAYMENT_REQUIRED` (no active subscription, no funds, blocked tier), `CLOUD_SUBSCRIPTION_REQUIRED`, `FREE_TIER_EXHAUSTED`, `PARTNER_NODE_PAYMENT_REQUIRED`, or `MODEL_PAYMENT_REQUIRED`. A `PAYMENT_REQUIRED` body may also carry `error.reason`, the billing policy's reason for the refusal, e.g. `subscription_inactive`, `no_funds` or `manual_block`; treat an absent or unknown reason as the generic refusal.
18870
+ * The account cannot run this submission; nothing was queued and retrying unchanged will not resolve the refusal. Disambiguated by the body's `error.type`, NOT by parsing `error.message`: `PAYMENT_REQUIRED` (no active subscription, no funds, blocked tier), `CLOUD_SUBSCRIPTION_REQUIRED`, `FREE_TIER_EXHAUSTED`, `PARTNER_NODE_PAYMENT_REQUIRED`, or `MODEL_PAYMENT_REQUIRED`. A `PAYMENT_REQUIRED` body may also carry `error.reason`, the billing policy's reason for the refusal, e.g. `subscription_inactive`, `no_funds` or `manual_block`; treat an absent or unknown reason as the generic refusal. When the free-tier master switch is enabled, `CLOUD_SUBSCRIPTION_REQUIRED` may carry `error.reason: google_sign_in_required` for the Google-session gate. This identifies the gate hit, not a promise of unused allowance or partner-node eligibility; later free-tier checks still apply. A hard cap responds with top-level `error_type: budget_exceeded`, `denied_reason` and `budget`. Only workspace Owners receive amounts and `blocking_budgets`.
17104
18871
  */
17105
- 402: PromptErrorResponse;
18872
+ 402: PromptPaymentRequired;
17106
18873
  /**
17107
18874
  * Workspace governance policy blocks one or more partner providers (error.type PARTNER_NODE_DISABLED; error.class_types lists the offending nodes, error.providers the disabled providers), or a refused request with `code` and `message` (see SessionWriteForbidden).
17108
18875
  */
17109
18876
  403: PromptErrorResponse;
18877
+ /**
18878
+ * The request's `Comfy-Loaded-Release` names a Release other than the one the picked deployment runs now (error.type `RELEASE_CHANGED`; error.release_id is the Release it runs now). Nothing was queued; reload that Release before submitting again. Answered before the workflow is validated.
18879
+ */
18880
+ 409: PromptErrorResponse;
17110
18881
  /**
17111
18882
  * Workflow JSON too large
17112
18883
  */
@@ -17120,7 +18891,7 @@ export type ExecutePromptErrors = {
17120
18891
  */
17121
18892
  500: PromptErrorResponse;
17122
18893
  /**
17123
- * Service unavailable
18894
+ * Service unavailable. A hard budget check outage carries `error_type: budget_check_unavailable` and `denied_reason`.
17124
18895
  */
17125
18896
  503: PromptErrorResponse;
17126
18897
  };
@@ -17178,6 +18949,26 @@ export type GetProvidersResponses = {
17178
18949
  200: ProviderCatalogResponse;
17179
18950
  };
17180
18951
  export type GetProvidersResponse = GetProvidersResponses[keyof GetProvidersResponses];
18952
+ export type ListPublicModelsData = {
18953
+ body?: never;
18954
+ path?: never;
18955
+ query?: never;
18956
+ url: '/api/public_models';
18957
+ };
18958
+ export type ListPublicModelsErrors = {
18959
+ /**
18960
+ * The catalog could not be read in full
18961
+ */
18962
+ 503: ErrorResponse;
18963
+ };
18964
+ export type ListPublicModelsError = ListPublicModelsErrors[keyof ListPublicModelsErrors];
18965
+ export type ListPublicModelsResponses = {
18966
+ /**
18967
+ * The public model catalog
18968
+ */
18969
+ 200: PublicModelsResponse;
18970
+ };
18971
+ export type ListPublicModelsResponse = ListPublicModelsResponses[keyof ListPublicModelsResponses];
17181
18972
  export type GetQueueInfoData = {
17182
18973
  body?: never;
17183
18974
  path?: never;
@@ -17212,6 +19003,36 @@ export type GetQueueInfoResponses = {
17212
19003
  export type GetQueueInfoResponse = GetQueueInfoResponses[keyof GetQueueInfoResponses];
17213
19004
  export type ManageQueueData = {
17214
19005
  body: QueueManageRequest;
19006
+ headers?: {
19007
+ /**
19008
+ * The project a request acts in. The operations that list it are the
19009
+ * ones that read it: they list workflows, runs or assets, create one,
19010
+ * export assets, clear the caller's queue or History, pick the
19011
+ * deployment a browser runs on, or serve the editor that deployment
19012
+ * (the node, extension and model lists). Absent means
19013
+ * the workspace's default project, which is how existing clients keep
19014
+ * working.
19015
+ *
19016
+ * An operation on one existing workflow, run or asset does not take
19017
+ * it: the row's own project decides. Any other operation that creates
19018
+ * a workflow, run or asset acts in the default project until it lists
19019
+ * this parameter.
19020
+ *
19021
+ * The project must be in the workspace the request resolves to. A
19022
+ * project that does not exist, or that the caller may not view, is 404
19023
+ * `not_found`; the two look the same. Where Projects is not enabled for
19024
+ * the workspace the header is ignored.
19025
+ *
19026
+ * A Cloud JWT that carries a `project_id` claim acts only in that
19027
+ * project. Without the header such a request acts in the claimed
19028
+ * project; a header naming any other project, the default project
19029
+ * included, is 403 `permission_denied`, and so is any such request
19030
+ * where Projects is not enabled for the workspace. The refusal says the
19031
+ * token is bound to another project, not what the caller's role allows.
19032
+ *
19033
+ */
19034
+ 'X-Comfy-Project-ID'?: string;
19035
+ };
17215
19036
  path?: never;
17216
19037
  query?: never;
17217
19038
  url: '/api/queue';
@@ -17229,6 +19050,10 @@ export type ManageQueueErrors = {
17229
19050
  * A refused request that changes data. For a web session, `code` is `csrf_invalid` (no `X-CSRF-Token`, or not the session's), `workspace_access_denied` (the selected workspace is unknown, deleted, or the user is not a member; the three look the same), `no_workspace_access` (the account has no personal workspace and is a member of no live workspace), `origin_not_allowed` or `cross_site_request`; see the `WebSessionAuth` scheme. For any credential, `sso_required` means an SSO organization holds the account (its email is on the organization's verified domains) and the credential is not an SSO sign-in, or the workspace is an SSO organization's and the account is not on its domains or the credential is not an SSO sign-in; `organization_id`, when present, names the organization to sign in with. `account_outside_organization` means the workspace is an SSO organization's and the account is on none of its domains, so no sign-in admits it; `organization_id` names the workspace's organization. `personal_workspace_disabled` means the workspace is the account's personal one and an SSO organization holds the account, so it cannot use it; `organization_id` names that organization. `FORBIDDEN` is the route's own authorization check failing, such as an unverified email, or, on `POST /api/workspaces`, an account an SSO organization holds (its organization manages its workspaces; signing in again does not change it). On the plan-lifecycle writes (`POST /api/billing/subscribe`, `POST /api/billing/subscription/cancel`, `POST /api/billing/subscription/resubscribe`, `POST /api/billing/subscription/revert-scheduled-change`, `POST /api/billing/ops/{id}/cancel` and the `/api/billing/retention*` routes), `NOT_ORIGINAL_OWNER` means the caller is an owner but not the workspace's creator, and only the creator may change the plan; it is returned only when the rollout mode is `creator`. A credential this route does not take gets AuthTypeNotAllowedError instead, and so does the session while `web_session_enabled` is off for the user, unless the operation says it takes the session whatever the flag.
17230
19051
  */
17231
19052
  403: ForbiddenError;
19053
+ /**
19054
+ * The project `X-Comfy-Project-ID` names does not exist or the caller may not view it (`not_found`)
19055
+ */
19056
+ 404: ErrorResponse;
17232
19057
  /**
17233
19058
  * Internal server error
17234
19059
  */
@@ -17244,6 +19069,36 @@ export type ManageQueueResponses = {
17244
19069
  export type ManageQueueResponse = ManageQueueResponses[keyof ManageQueueResponses];
17245
19070
  export type GetReleaseUnsupportedPacksData = {
17246
19071
  body?: never;
19072
+ headers?: {
19073
+ /**
19074
+ * The project a request acts in. The operations that list it are the
19075
+ * ones that read it: they list workflows, runs or assets, create one,
19076
+ * export assets, clear the caller's queue or History, pick the
19077
+ * deployment a browser runs on, or serve the editor that deployment
19078
+ * (the node, extension and model lists). Absent means
19079
+ * the workspace's default project, which is how existing clients keep
19080
+ * working.
19081
+ *
19082
+ * An operation on one existing workflow, run or asset does not take
19083
+ * it: the row's own project decides. Any other operation that creates
19084
+ * a workflow, run or asset acts in the default project until it lists
19085
+ * this parameter.
19086
+ *
19087
+ * The project must be in the workspace the request resolves to. A
19088
+ * project that does not exist, or that the caller may not view, is 404
19089
+ * `not_found`; the two look the same. Where Projects is not enabled for
19090
+ * the workspace the header is ignored.
19091
+ *
19092
+ * A Cloud JWT that carries a `project_id` claim acts only in that
19093
+ * project. Without the header such a request acts in the claimed
19094
+ * project; a header naming any other project, the default project
19095
+ * included, is 403 `permission_denied`, and so is any such request
19096
+ * where Projects is not enabled for the workspace. The refusal says the
19097
+ * token is bound to another project, not what the caller's role allows.
19098
+ *
19099
+ */
19100
+ 'X-Comfy-Project-ID'?: string;
19101
+ };
17247
19102
  path?: never;
17248
19103
  query?: never;
17249
19104
  url: '/api/release/unsupported-packs';
@@ -17261,6 +19116,10 @@ export type GetReleaseUnsupportedPacksErrors = {
17261
19116
  * A refused request. For a web session, `code` is `workspace_access_denied` (the selected workspace is unknown, deleted, or the user is not a member; the three look the same), `no_workspace_access` (the account has no personal workspace and is a member of no live workspace), `origin_not_allowed` or `cross_site_request`; see the `WebSessionAuth` scheme. For any credential, `sso_required` means an SSO organization holds the account (its email is on the organization's verified domains) and the credential is not an SSO sign-in, or the workspace is an SSO organization's and the account is not on its domains or the credential is not an SSO sign-in; `organization_id`, when present, names the organization to sign in with. `account_outside_organization` means the workspace is an SSO organization's and the account is on none of its domains, so no sign-in admits it; `organization_id` names the workspace's organization. `personal_workspace_disabled` means the workspace is the account's personal one and an SSO organization holds the account, so it cannot use it; `organization_id` names that organization. `FORBIDDEN` is the route's own authorization check failing, such as an unverified email. On `GET /api/billing/churnkey/auth`, `NOT_ORIGINAL_OWNER` means the caller is not the workspace's creator; it is returned only when the rollout mode is `creator`. A credential this route does not take gets AuthTypeNotAllowedError instead, and so does the session while `web_session_enabled` is off for the user, unless the operation says it takes the session whatever `web_session_enabled` says.
17262
19117
  */
17263
19118
  403: ForbiddenError;
19119
+ /**
19120
+ * The project `X-Comfy-Project-ID` names does not exist or the caller may not view it (`not_found`)
19121
+ */
19122
+ 404: ErrorResponse;
17264
19123
  };
17265
19124
  export type GetReleaseUnsupportedPacksError = GetReleaseUnsupportedPacksErrors[keyof GetReleaseUnsupportedPacksErrors];
17266
19125
  export type GetReleaseUnsupportedPacksResponses = {
@@ -17928,9 +19787,12 @@ export type UploadImageData = {
17928
19787
  headers?: {
17929
19788
  /**
17930
19789
  * The project a request acts in. The operations that list it are the
17931
- * ones that read it: they list workflows, runs or assets, or create
17932
- * one. Absent means the workspace's default project, which is how
17933
- * existing clients keep working.
19790
+ * ones that read it: they list workflows, runs or assets, create one,
19791
+ * export assets, clear the caller's queue or History, pick the
19792
+ * deployment a browser runs on, or serve the editor that deployment
19793
+ * (the node, extension and model lists). Absent means
19794
+ * the workspace's default project, which is how existing clients keep
19795
+ * working.
17934
19796
  *
17935
19797
  * An operation on one existing workflow, run or asset does not take
17936
19798
  * it: the row's own project decides. Any other operation that creates
@@ -17942,6 +19804,13 @@ export type UploadImageData = {
17942
19804
  * `not_found`; the two look the same. Where Projects is not enabled for
17943
19805
  * the workspace the header is ignored.
17944
19806
  *
19807
+ * A Cloud JWT that carries a `project_id` claim acts only in that
19808
+ * project. Without the header such a request acts in the claimed
19809
+ * project; a header naming any other project, the default project
19810
+ * included, is 403 `permission_denied`, and so is any such request
19811
+ * where Projects is not enabled for the workspace. The refusal says the
19812
+ * token is bound to another project, not what the caller's role allows.
19813
+ *
17945
19814
  */
17946
19815
  'X-Comfy-Project-ID'?: string;
17947
19816
  };
@@ -18006,9 +19875,12 @@ export type UploadMaskData = {
18006
19875
  headers?: {
18007
19876
  /**
18008
19877
  * The project a request acts in. The operations that list it are the
18009
- * ones that read it: they list workflows, runs or assets, or create
18010
- * one. Absent means the workspace's default project, which is how
18011
- * existing clients keep working.
19878
+ * ones that read it: they list workflows, runs or assets, create one,
19879
+ * export assets, clear the caller's queue or History, pick the
19880
+ * deployment a browser runs on, or serve the editor that deployment
19881
+ * (the node, extension and model lists). Absent means
19882
+ * the workspace's default project, which is how existing clients keep
19883
+ * working.
18012
19884
  *
18013
19885
  * An operation on one existing workflow, run or asset does not take
18014
19886
  * it: the row's own project decides. Any other operation that creates
@@ -18020,6 +19892,13 @@ export type UploadMaskData = {
18020
19892
  * `not_found`; the two look the same. Where Projects is not enabled for
18021
19893
  * the workspace the header is ignored.
18022
19894
  *
19895
+ * A Cloud JWT that carries a `project_id` claim acts only in that
19896
+ * project. Without the header such a request acts in the claimed
19897
+ * project; a header naming any other project, the default project
19898
+ * included, is 403 `permission_denied`, and so is any such request
19899
+ * where Projects is not enabled for the workspace. The refusal says the
19900
+ * token is bound to another project, not what the caller's role allows.
19901
+ *
18023
19902
  */
18024
19903
  'X-Comfy-Project-ID'?: string;
18025
19904
  };
@@ -18692,7 +20571,7 @@ export type ListCccWebsiteCardsErrors = {
18692
20571
  */
18693
20572
  409: unknown;
18694
20573
  /**
18695
- * Catalog unavailable or card budget exceeded
20574
+ * Catalog unavailable, card budget exceeded, or the pod busy. A page with a cursor waits at most 2 s for one of the few slots each pod keeps for cursor pages, then gets 503 with Retry-After: 1 and X-Comfy-Catalog-Busy: 1.
18696
20575
  */
18697
20576
  503: unknown;
18698
20577
  };
@@ -20255,6 +22134,92 @@ export type GetCccTypeSchemaResponses = {
20255
22134
  200: CccTypeSchema;
20256
22135
  };
20257
22136
  export type GetCccTypeSchemaResponse = GetCccTypeSchemaResponses[keyof GetCccTypeSchemaResponses];
22137
+ export type ListCccStaffAppsData = {
22138
+ body?: never;
22139
+ path?: never;
22140
+ query?: {
22141
+ limit?: number;
22142
+ cursor?: string;
22143
+ };
22144
+ url: '/api/v1/catalog/staff-apps';
22145
+ };
22146
+ export type ListCccStaffAppsErrors = {
22147
+ /**
22148
+ * Unknown or repeated parameter, a bad limit or a cursor from another limit; or `code` `workspace_id_invalid` (see SessionWorkspaceIDInvalid).
22149
+ */
22150
+ 400: ErrorResponse;
22151
+ /**
22152
+ * No valid credential, or an `Authorization` header, `X-API-Key` header or `?token=` next to the session cookie that could not be read, which is refused rather than answered with the session. `code` is `UNAUTHORIZED`.
22153
+ */
22154
+ 401: ErrorResponse;
22155
+ /**
22156
+ * A refused request. For a web session, `code` is `workspace_access_denied` (the selected workspace is unknown, deleted, or the user is not a member; the three look the same), `no_workspace_access` (the account has no personal workspace and is a member of no live workspace), `origin_not_allowed` or `cross_site_request`; see the `WebSessionAuth` scheme. For any credential, `sso_required` means an SSO organization holds the account (its email is on the organization's verified domains) and the credential is not an SSO sign-in, or the workspace is an SSO organization's and the account is not on its domains or the credential is not an SSO sign-in; `organization_id`, when present, names the organization to sign in with. `account_outside_organization` means the workspace is an SSO organization's and the account is on none of its domains, so no sign-in admits it; `organization_id` names the workspace's organization. `personal_workspace_disabled` means the workspace is the account's personal one and an SSO organization holds the account, so it cannot use it; `organization_id` names that organization. `FORBIDDEN` is the route's own authorization check failing, such as an unverified email. On `GET /api/billing/churnkey/auth`, `NOT_ORIGINAL_OWNER` means the caller is not the workspace's creator; it is returned only when the rollout mode is `creator`. A credential this route does not take gets AuthTypeNotAllowedError instead, and so does the session while `web_session_enabled` is off for the user, unless the operation says it takes the session whatever `web_session_enabled` says.
22157
+ */
22158
+ 403: ForbiddenError;
22159
+ /**
22160
+ * The cursor belongs to a stale Draft snapshot
22161
+ */
22162
+ 409: unknown;
22163
+ /**
22164
+ * Dedicated catalog or account verification unavailable
22165
+ */
22166
+ 503: unknown;
22167
+ };
22168
+ export type ListCccStaffAppsError = ListCccStaffAppsErrors[keyof ListCccStaffAppsErrors];
22169
+ export type ListCccStaffAppsResponses = {
22170
+ /**
22171
+ * One page of app rows and the optional opaque next_cursor
22172
+ */
22173
+ 200: CccStaffAppsPage;
22174
+ };
22175
+ export type ListCccStaffAppsResponse = ListCccStaffAppsResponses[keyof ListCccStaffAppsResponses];
22176
+ export type GetCccStaffAppPictureData = {
22177
+ body?: never;
22178
+ path: {
22179
+ uid: string;
22180
+ version: string;
22181
+ };
22182
+ query?: never;
22183
+ url: '/api/v1/catalog/staff-apps/{uid}/picture/{version}';
22184
+ };
22185
+ export type GetCccStaffAppPictureErrors = {
22186
+ /**
22187
+ * `code` is `workspace_id_invalid`: the `X-Comfy-Workspace-ID` header or `workspace_id` query value is malformed, or conflicts with another value or with the workspace the credential resolves to. Answered only while `web_session_enabled` is on for the user. See the `WebSessionAuth` scheme.
22188
+ */
22189
+ 400: ErrorResponse;
22190
+ /**
22191
+ * No valid credential, or an `Authorization` header, `X-API-Key` header or `?token=` next to the session cookie that could not be read, which is refused rather than answered with the session. `code` is `UNAUTHORIZED`.
22192
+ */
22193
+ 401: ErrorResponse;
22194
+ /**
22195
+ * A refused request. For a web session, `code` is `workspace_access_denied` (the selected workspace is unknown, deleted, or the user is not a member; the three look the same), `no_workspace_access` (the account has no personal workspace and is a member of no live workspace), `origin_not_allowed` or `cross_site_request`; see the `WebSessionAuth` scheme. For any credential, `sso_required` means an SSO organization holds the account (its email is on the organization's verified domains) and the credential is not an SSO sign-in, or the workspace is an SSO organization's and the account is not on its domains or the credential is not an SSO sign-in; `organization_id`, when present, names the organization to sign in with. `account_outside_organization` means the workspace is an SSO organization's and the account is on none of its domains, so no sign-in admits it; `organization_id` names the workspace's organization. `personal_workspace_disabled` means the workspace is the account's personal one and an SSO organization holds the account, so it cannot use it; `organization_id` names that organization. `FORBIDDEN` is the route's own authorization check failing, such as an unverified email. On `GET /api/billing/churnkey/auth`, `NOT_ORIGINAL_OWNER` means the caller is not the workspace's creator; it is returned only when the rollout mode is `creator`. A credential this route does not take gets AuthTypeNotAllowedError instead, and so does the session while `web_session_enabled` is off for the user, unless the operation says it takes the session whatever `web_session_enabled` says.
22196
+ */
22197
+ 403: ForbiddenError;
22198
+ /**
22199
+ * Not an app, no image picture, another version, unavailable, or a query string
22200
+ */
22201
+ 404: unknown;
22202
+ /**
22203
+ * Requested range is outside the file
22204
+ */
22205
+ 416: unknown;
22206
+ /**
22207
+ * Account verification unavailable
22208
+ */
22209
+ 503: unknown;
22210
+ };
22211
+ export type GetCccStaffAppPictureError = GetCccStaffAppPictureErrors[keyof GetCccStaffAppPictureErrors];
22212
+ export type GetCccStaffAppPictureResponses = {
22213
+ /**
22214
+ * The picture bytes; private no-store
22215
+ */
22216
+ 200: Blob | File;
22217
+ /**
22218
+ * Requested byte range (Range header) of the same bytes, after the same checks
22219
+ */
22220
+ 206: Blob | File;
22221
+ };
22222
+ export type GetCccStaffAppPictureResponse = GetCccStaffAppPictureResponses[keyof GetCccStaffAppPictureResponses];
20258
22223
  export type GetCccStateData = {
20259
22224
  body?: never;
20260
22225
  path?: never;
@@ -20641,6 +22606,10 @@ export type ViewFileErrors = {
20641
22606
  * Internal server error
20642
22607
  */
20643
22608
  500: ErrorResponse;
22609
+ /**
22610
+ * With `channel` or `res`: the pod's upload buffer budget, which the image's bytes and decoded pixels are charged to, is exhausted; retry after the Retry-After seconds. `code` is `UPLOAD_BUDGET_EXHAUSTED`.
22611
+ */
22612
+ 503: ErrorResponse;
20644
22613
  };
20645
22614
  export type ViewFileError = ViewFileErrors[keyof ViewFileErrors];
20646
22615
  export type ViewFileResponses = {
@@ -20749,9 +22718,12 @@ export type ListWorkflowsData = {
20749
22718
  headers?: {
20750
22719
  /**
20751
22720
  * The project a request acts in. The operations that list it are the
20752
- * ones that read it: they list workflows, runs or assets, or create
20753
- * one. Absent means the workspace's default project, which is how
20754
- * existing clients keep working.
22721
+ * ones that read it: they list workflows, runs or assets, create one,
22722
+ * export assets, clear the caller's queue or History, pick the
22723
+ * deployment a browser runs on, or serve the editor that deployment
22724
+ * (the node, extension and model lists). Absent means
22725
+ * the workspace's default project, which is how existing clients keep
22726
+ * working.
20755
22727
  *
20756
22728
  * An operation on one existing workflow, run or asset does not take
20757
22729
  * it: the row's own project decides. Any other operation that creates
@@ -20763,6 +22735,13 @@ export type ListWorkflowsData = {
20763
22735
  * `not_found`; the two look the same. Where Projects is not enabled for
20764
22736
  * the workspace the header is ignored.
20765
22737
  *
22738
+ * A Cloud JWT that carries a `project_id` claim acts only in that
22739
+ * project. Without the header such a request acts in the claimed
22740
+ * project; a header naming any other project, the default project
22741
+ * included, is 403 `permission_denied`, and so is any such request
22742
+ * where Projects is not enabled for the workspace. The refusal says the
22743
+ * token is bound to another project, not what the caller's role allows.
22744
+ *
20766
22745
  */
20767
22746
  'X-Comfy-Project-ID'?: string;
20768
22747
  };
@@ -20820,9 +22799,12 @@ export type CreateWorkflowData = {
20820
22799
  headers?: {
20821
22800
  /**
20822
22801
  * The project a request acts in. The operations that list it are the
20823
- * ones that read it: they list workflows, runs or assets, or create
20824
- * one. Absent means the workspace's default project, which is how
20825
- * existing clients keep working.
22802
+ * ones that read it: they list workflows, runs or assets, create one,
22803
+ * export assets, clear the caller's queue or History, pick the
22804
+ * deployment a browser runs on, or serve the editor that deployment
22805
+ * (the node, extension and model lists). Absent means
22806
+ * the workspace's default project, which is how existing clients keep
22807
+ * working.
20826
22808
  *
20827
22809
  * An operation on one existing workflow, run or asset does not take
20828
22810
  * it: the row's own project decides. Any other operation that creates
@@ -20834,6 +22816,13 @@ export type CreateWorkflowData = {
20834
22816
  * `not_found`; the two look the same. Where Projects is not enabled for
20835
22817
  * the workspace the header is ignored.
20836
22818
  *
22819
+ * A Cloud JWT that carries a `project_id` claim acts only in that
22820
+ * project. Without the header such a request acts in the claimed
22821
+ * project; a header naming any other project, the default project
22822
+ * included, is 403 `permission_denied`, and so is any such request
22823
+ * where Projects is not enabled for the workspace. The refusal says the
22824
+ * token is bound to another project, not what the caller's role allows.
22825
+ *
20837
22826
  */
20838
22827
  'X-Comfy-Project-ID'?: string;
20839
22828
  };
@@ -21044,9 +23033,12 @@ export type ForkWorkflowData = {
21044
23033
  headers?: {
21045
23034
  /**
21046
23035
  * The project a request acts in. The operations that list it are the
21047
- * ones that read it: they list workflows, runs or assets, or create
21048
- * one. Absent means the workspace's default project, which is how
21049
- * existing clients keep working.
23036
+ * ones that read it: they list workflows, runs or assets, create one,
23037
+ * export assets, clear the caller's queue or History, pick the
23038
+ * deployment a browser runs on, or serve the editor that deployment
23039
+ * (the node, extension and model lists). Absent means
23040
+ * the workspace's default project, which is how existing clients keep
23041
+ * working.
21050
23042
  *
21051
23043
  * An operation on one existing workflow, run or asset does not take
21052
23044
  * it: the row's own project decides. Any other operation that creates
@@ -21058,6 +23050,13 @@ export type ForkWorkflowData = {
21058
23050
  * `not_found`; the two look the same. Where Projects is not enabled for
21059
23051
  * the workspace the header is ignored.
21060
23052
  *
23053
+ * A Cloud JWT that carries a `project_id` claim acts only in that
23054
+ * project. Without the header such a request acts in the claimed
23055
+ * project; a header naming any other project, the default project
23056
+ * included, is 403 `permission_denied`, and so is any such request
23057
+ * where Projects is not enabled for the workspace. The refusal says the
23058
+ * token is bound to another project, not what the caller's role allows.
23059
+ *
21061
23060
  */
21062
23061
  'X-Comfy-Project-ID'?: string;
21063
23062
  };
@@ -21470,7 +23469,7 @@ export type ListWorkspaceInvitesErrors = {
21470
23469
  */
21471
23470
  401: ErrorResponse;
21472
23471
  /**
21473
- * Owner role required
23472
+ * Owner role, or Workspace admin, required
21474
23473
  */
21475
23474
  403: ErrorResponse;
21476
23475
  /**
@@ -21502,7 +23501,7 @@ export type CreateWorkspaceInviteErrors = {
21502
23501
  */
21503
23502
  401: ErrorResponse;
21504
23503
  /**
21505
- * Owner role required or personal workspace (invites not allowed)
23504
+ * Owner role, or Workspace admin, required; or personal workspace (invites not allowed)
21506
23505
  */
21507
23506
  403: ErrorResponse;
21508
23507
  /**
@@ -21551,7 +23550,7 @@ export type RevokeWorkspaceInviteErrors = {
21551
23550
  */
21552
23551
  401: ErrorResponse;
21553
23552
  /**
21554
- * Owner role required
23553
+ * Owner role, or Workspace admin, required; or the caller is a Workspace admin and the invite is an owner invite
21555
23554
  */
21556
23555
  403: ErrorResponse;
21557
23556
  /**
@@ -21592,7 +23591,7 @@ export type ResendWorkspaceInviteErrors = {
21592
23591
  */
21593
23592
  401: ErrorResponse;
21594
23593
  /**
21595
- * Owner role required
23594
+ * Owner role, or Workspace admin, required; or the caller is a Workspace admin and the invite is an owner invite
21596
23595
  */
21597
23596
  403: ErrorResponse;
21598
23597
  /**
@@ -21763,7 +23762,7 @@ export type RemoveWorkspaceMemberErrors = {
21763
23762
  */
21764
23763
  401: ErrorResponse;
21765
23764
  /**
21766
- * Owner role required, cannot remove yourself, the original owner of a personal workspace cannot be removed (`CANNOT_REMOVE_ORIGINAL_OWNER`), or the creator of a team workspace cannot be removed (`CANNOT_REMOVE_CREATOR`)
23765
+ * Owner role, or Workspace admin, required (`FORBIDDEN`); the caller is a Workspace admin and the member is an owner or another Workspace admin (`NOT_OWNER`); cannot remove yourself; the original owner of a personal workspace cannot be removed (`CANNOT_REMOVE_ORIGINAL_OWNER`), or the creator of a team workspace cannot be removed (`CANNOT_REMOVE_CREATOR`)
21767
23766
  */
21768
23767
  403: ErrorResponse;
21769
23768
  /**
@@ -22271,7 +24270,7 @@ export type SetWorkspaceDefaultDeploymentErrors = {
22271
24270
  */
22272
24271
  404: ErrorResponse;
22273
24272
  /**
22274
- * Validation error, including a deployment_id that is not one of the workspace's deployments or has been deleted
24273
+ * Validation error, including a deployment_id that is not one of the workspace's deployments or has been deleted. `code` `deployment_not_permitted` is a deployment that belongs to a project other than the default: the workspace default applies in the default project alone.
22275
24274
  */
22276
24275
  422: ErrorResponse;
22277
24276
  /**
@@ -22339,6 +24338,36 @@ export type ClearWorkspaceDeploymentResponses = {
22339
24338
  export type ClearWorkspaceDeploymentResponse = ClearWorkspaceDeploymentResponses[keyof ClearWorkspaceDeploymentResponses];
22340
24339
  export type PickWorkspaceDeploymentData = {
22341
24340
  body: PickWorkspaceDeploymentRequest;
24341
+ headers?: {
24342
+ /**
24343
+ * The project a request acts in. The operations that list it are the
24344
+ * ones that read it: they list workflows, runs or assets, create one,
24345
+ * export assets, clear the caller's queue or History, pick the
24346
+ * deployment a browser runs on, or serve the editor that deployment
24347
+ * (the node, extension and model lists). Absent means
24348
+ * the workspace's default project, which is how existing clients keep
24349
+ * working.
24350
+ *
24351
+ * An operation on one existing workflow, run or asset does not take
24352
+ * it: the row's own project decides. Any other operation that creates
24353
+ * a workflow, run or asset acts in the default project until it lists
24354
+ * this parameter.
24355
+ *
24356
+ * The project must be in the workspace the request resolves to. A
24357
+ * project that does not exist, or that the caller may not view, is 404
24358
+ * `not_found`; the two look the same. Where Projects is not enabled for
24359
+ * the workspace the header is ignored.
24360
+ *
24361
+ * A Cloud JWT that carries a `project_id` claim acts only in that
24362
+ * project. Without the header such a request acts in the claimed
24363
+ * project; a header naming any other project, the default project
24364
+ * included, is 403 `permission_denied`, and so is any such request
24365
+ * where Projects is not enabled for the workspace. The refusal says the
24366
+ * token is bound to another project, not what the caller's role allows.
24367
+ *
24368
+ */
24369
+ 'X-Comfy-Project-ID'?: string;
24370
+ };
22342
24371
  path: {
22343
24372
  /**
22344
24373
  * Workspace ID (w-{uuid} format)
@@ -22362,11 +24391,11 @@ export type PickWorkspaceDeploymentErrors = {
22362
24391
  */
22363
24392
  403: ErrorResponse;
22364
24393
  /**
22365
- * Workspace not found, or the caller is not a member of it
24394
+ * Workspace not found, or the caller is not a member of it; or `code` `not_found` for a project that does not exist or that the caller may not view
22366
24395
  */
22367
24396
  404: ErrorResponse;
22368
24397
  /**
22369
- * Validation error, including a deployment_id that is not one of the workspace's deployments or has been deleted
24398
+ * Validation error, including a deployment_id that is not one of the workspace's deployments or has been deleted. `code` `deployment_not_permitted` is a live deployment that belongs to a project other than the one the pick is made in; nothing is picked. It says which project the deployment is in, not what the caller's role allows.
22370
24399
  */
22371
24400
  422: ErrorResponse;
22372
24401
  /**
@@ -22388,6 +24417,36 @@ export type PickWorkspaceDeploymentResponses = {
22388
24417
  export type PickWorkspaceDeploymentResponse = PickWorkspaceDeploymentResponses[keyof PickWorkspaceDeploymentResponses];
22389
24418
  export type GetWorkspaceDeploymentCpuServerData = {
22390
24419
  body?: never;
24420
+ headers?: {
24421
+ /**
24422
+ * The project a request acts in. The operations that list it are the
24423
+ * ones that read it: they list workflows, runs or assets, create one,
24424
+ * export assets, clear the caller's queue or History, pick the
24425
+ * deployment a browser runs on, or serve the editor that deployment
24426
+ * (the node, extension and model lists). Absent means
24427
+ * the workspace's default project, which is how existing clients keep
24428
+ * working.
24429
+ *
24430
+ * An operation on one existing workflow, run or asset does not take
24431
+ * it: the row's own project decides. Any other operation that creates
24432
+ * a workflow, run or asset acts in the default project until it lists
24433
+ * this parameter.
24434
+ *
24435
+ * The project must be in the workspace the request resolves to. A
24436
+ * project that does not exist, or that the caller may not view, is 404
24437
+ * `not_found`; the two look the same. Where Projects is not enabled for
24438
+ * the workspace the header is ignored.
24439
+ *
24440
+ * A Cloud JWT that carries a `project_id` claim acts only in that
24441
+ * project. Without the header such a request acts in the claimed
24442
+ * project; a header naming any other project, the default project
24443
+ * included, is 403 `permission_denied`, and so is any such request
24444
+ * where Projects is not enabled for the workspace. The refusal says the
24445
+ * token is bound to another project, not what the caller's role allows.
24446
+ *
24447
+ */
24448
+ 'X-Comfy-Project-ID'?: string;
24449
+ };
22391
24450
  path: {
22392
24451
  /**
22393
24452
  * Workspace ID (w-{uuid} format)
@@ -22411,7 +24470,7 @@ export type GetWorkspaceDeploymentCpuServerErrors = {
22411
24470
  */
22412
24471
  403: ForbiddenError;
22413
24472
  /**
22414
- * Workspace not found, or the caller is not a member
24473
+ * Workspace not found, or the caller is not a member; or `code` `not_found` for a project that does not exist or that the caller may not view
22415
24474
  */
22416
24475
  404: ErrorResponse;
22417
24476
  /**
@@ -22481,6 +24540,67 @@ export type ListWorkspaceDeploymentsResponses = {
22481
24540
  200: WorkspaceDeploymentList;
22482
24541
  };
22483
24542
  export type ListWorkspaceDeploymentsResponse = ListWorkspaceDeploymentsResponses[keyof ListWorkspaceDeploymentsResponses];
24543
+ export type AddWorkspaceDeploymentBuildModelData = {
24544
+ body: AddDeploymentBuildModelRequest;
24545
+ path: {
24546
+ /**
24547
+ * Workspace ID (w-{uuid} format)
24548
+ */
24549
+ id: string;
24550
+ /**
24551
+ * One of the workspace's deployments (dep-{uuid} format)
24552
+ */
24553
+ deployment_id: string;
24554
+ };
24555
+ query?: never;
24556
+ url: '/api/workspaces/{id}/deployments/{deployment_id}/build-models';
24557
+ };
24558
+ export type AddWorkspaceDeploymentBuildModelErrors = {
24559
+ /**
24560
+ * `code` `INVALID_REQUEST`: a field is empty or the filename is not a safe relative path; or comfy-builder's own refusal of the save or the cut, with its status and body unchanged; or `code` `workspace_id_invalid` (see SessionWorkspaceIDInvalid).
24561
+ */
24562
+ 400: DeploymentModelsRefusalBody;
24563
+ /**
24564
+ * No valid credential, or an `Authorization` header, `X-API-Key` header or `?token=` next to the session cookie that could not be read, which is refused rather than answered with the session. `code` is `UNAUTHORIZED`.
24565
+ */
24566
+ 401: ErrorResponse;
24567
+ /**
24568
+ * comfy-deploy's or comfy-builder's own refusal, with its status and body unchanged: `{error, message}`, `error` its machine-readable code and `message` written for the person.
24569
+ */
24570
+ 402: PlatformPassthroughBody;
24571
+ /**
24572
+ * An API key (these routes need a signed-in session), or the rollout flag is off for this account, as `code` and `message`; or the platform's own 403, unchanged. For a web session, `code` may also be one of the SessionWriteForbidden refusals. A credential these routes never take, such as `X-ComfyAPI-Secret`, and the session while `web_session_enabled` is off for the user, get ingest's authentication refusal instead, AuthTypeNotAllowedError with `accepted` and no `code`, before any other check. See DeploymentModelsForbiddenBody.
24573
+ */
24574
+ 403: DeploymentModelsForbiddenBody;
24575
+ /**
24576
+ * Workspace not found, the caller is not a member, the deployment id is not one, the deployment is deleted, or comfy-builder does not name the Build its Release was cut from: ingest's own refusal, `code` `NOT_FOUND`. Or the platform's own 404, its body unchanged and without `code`.
24577
+ */
24578
+ 404: DeploymentModelsRefusalBody;
24579
+ /**
24580
+ * `code` `MODEL_NAME_TAKEN`: the Build already lists a model on this path (type and filename joined by `/`, so a subfolder may sit in either) from another upload, the filename given or taken from that upload's name or link. `code` `MODEL_NAME_UNKNOWN`: the Build lists an upload of this type with no filename and comfy-builder's newest 100 model uploads do not name it; give that model a filename in the Build. `code` `BUILD_CHANGED`: twice, another save changed the Build between this save and the cut, and the new Release does not stage this upload on this path. Or comfy-builder's own 409, unchanged: the save found the Build changed twice, or the workspace has reached its release limit.
24581
+ */
24582
+ 409: DeploymentModelsRefusalBody;
24583
+ /**
24584
+ * comfy-deploy's or comfy-builder's own refusal, with its status and body unchanged: `{error, message}`, `error` its machine-readable code and `message` written for the person.
24585
+ */
24586
+ 429: PlatformPassthroughBody;
24587
+ /**
24588
+ * Ingest could not read the workspace or mint the caller's token (`code` `INTERNAL_ERROR` and `message`, before any platform call); or the platform's own 500, unchanged, which need not carry a `code`: comfy-builder answers a storage or database failure with only `message`.
24589
+ */
24590
+ 500: PlatformPassthroughBody;
24591
+ /**
24592
+ * comfy-deploy or comfy-builder could not be asked, refused the token ingest minted (its 401), or is not configured in this environment, as `code` and `message`; or the platform's own 503, unchanged, such as comfy-deploy's `{error, message}` for a request that ran past its deadline.
24593
+ */
24594
+ 503: PlatformPassthroughBody;
24595
+ };
24596
+ export type AddWorkspaceDeploymentBuildModelError = AddWorkspaceDeploymentBuildModelErrors[keyof AddWorkspaceDeploymentBuildModelErrors];
24597
+ export type AddWorkspaceDeploymentBuildModelResponses = {
24598
+ /**
24599
+ * The new version was cut; poll it by its releaseId
24600
+ */
24601
+ 200: DeploymentBuildModelRelease;
24602
+ };
24603
+ export type AddWorkspaceDeploymentBuildModelResponse = AddWorkspaceDeploymentBuildModelResponses[keyof AddWorkspaceDeploymentBuildModelResponses];
22484
24604
  export type CreateWorkspaceDeploymentModelUploadData = {
22485
24605
  body: DeploymentModelUploadRequest;
22486
24606
  path: {
@@ -22510,7 +24630,7 @@ export type CreateWorkspaceDeploymentModelUploadErrors = {
22510
24630
  */
22511
24631
  403: DeploymentModelsForbiddenBody;
22512
24632
  /**
22513
- * Workspace not found, the caller is not a member, the deployment id is not one, or the model id (on the remove) or blob id (on the parts and complete) is only dot segments: ingest's own refusal, `code` `NOT_FOUND`, before any platform call. Or the platform's own 404, its body unchanged and without `code`: on the add, list and remove, the deployment is not one of the workspace's, comfy-deploy's models switch is off, or the upload or entry is not found; on the parts and complete, comfy-builder has no such upload in the workspace (the upload routes do not check the deployment). A body with `code` is ingest's; read comfy-deploy's 404 as "not on yet" only when `code` is absent. See DeploymentModelsRefusalBody.
24633
+ * Workspace not found, the caller is not a member, the deployment id is not one, or the model id (on the remove) or blob id (on the parts and complete) is only dot segments: ingest's own refusal, `code` `NOT_FOUND`, before any platform call. Or the platform's own 404, its body unchanged and without `code`: on the add, list and remove, the deployment is not one of the workspace's, or on the add and remove is being deleted (`error` `NOT_FOUND`); on the add, the upload is not found (`error` `UPLOAD_NOT_FOUND`); on the remove, the entry is not found (`error` `NOT_FOUND`); on the parts and complete, comfy-builder has no such upload in the workspace (the upload routes do not check the deployment). A body with `code` is ingest's; one without it is the platform's. See DeploymentModelsRefusalBody.
22514
24634
  */
22515
24635
  404: PlatformPassthroughBody;
22516
24636
  /**
@@ -22563,7 +24683,7 @@ export type CompleteWorkspaceDeploymentModelUploadErrors = {
22563
24683
  */
22564
24684
  403: DeploymentModelsForbiddenBody;
22565
24685
  /**
22566
- * Workspace not found, the caller is not a member, the deployment id is not one, or the model id (on the remove) or blob id (on the parts and complete) is only dot segments: ingest's own refusal, `code` `NOT_FOUND`, before any platform call. Or the platform's own 404, its body unchanged and without `code`: on the add, list and remove, the deployment is not one of the workspace's, comfy-deploy's models switch is off, or the upload or entry is not found; on the parts and complete, comfy-builder has no such upload in the workspace (the upload routes do not check the deployment). A body with `code` is ingest's; read comfy-deploy's 404 as "not on yet" only when `code` is absent. See DeploymentModelsRefusalBody.
24686
+ * Workspace not found, the caller is not a member, the deployment id is not one, or the model id (on the remove) or blob id (on the parts and complete) is only dot segments: ingest's own refusal, `code` `NOT_FOUND`, before any platform call. Or the platform's own 404, its body unchanged and without `code`: on the add, list and remove, the deployment is not one of the workspace's, or on the add and remove is being deleted (`error` `NOT_FOUND`); on the add, the upload is not found (`error` `UPLOAD_NOT_FOUND`); on the remove, the entry is not found (`error` `NOT_FOUND`); on the parts and complete, comfy-builder has no such upload in the workspace (the upload routes do not check the deployment). A body with `code` is ingest's; one without it is the platform's. See DeploymentModelsRefusalBody.
22567
24687
  */
22568
24688
  404: PlatformPassthroughBody;
22569
24689
  /**
@@ -22620,7 +24740,7 @@ export type RefreshWorkspaceDeploymentModelUploadPartsErrors = {
22620
24740
  */
22621
24741
  403: DeploymentModelsForbiddenBody;
22622
24742
  /**
22623
- * Workspace not found, the caller is not a member, the deployment id is not one, or the model id (on the remove) or blob id (on the parts and complete) is only dot segments: ingest's own refusal, `code` `NOT_FOUND`, before any platform call. Or the platform's own 404, its body unchanged and without `code`: on the add, list and remove, the deployment is not one of the workspace's, comfy-deploy's models switch is off, or the upload or entry is not found; on the parts and complete, comfy-builder has no such upload in the workspace (the upload routes do not check the deployment). A body with `code` is ingest's; read comfy-deploy's 404 as "not on yet" only when `code` is absent. See DeploymentModelsRefusalBody.
24743
+ * Workspace not found, the caller is not a member, the deployment id is not one, or the model id (on the remove) or blob id (on the parts and complete) is only dot segments: ingest's own refusal, `code` `NOT_FOUND`, before any platform call. Or the platform's own 404, its body unchanged and without `code`: on the add, list and remove, the deployment is not one of the workspace's, or on the add and remove is being deleted (`error` `NOT_FOUND`); on the add, the upload is not found (`error` `UPLOAD_NOT_FOUND`); on the remove, the entry is not found (`error` `NOT_FOUND`); on the parts and complete, comfy-builder has no such upload in the workspace (the upload routes do not check the deployment). A body with `code` is ingest's; one without it is the platform's. See DeploymentModelsRefusalBody.
22624
24744
  */
22625
24745
  404: PlatformPassthroughBody;
22626
24746
  /**
@@ -22673,7 +24793,7 @@ export type ListWorkspaceDeploymentModelsErrors = {
22673
24793
  */
22674
24794
  403: DeploymentModelsForbiddenBody;
22675
24795
  /**
22676
- * Workspace not found, the caller is not a member, the deployment id is not one, or the model id (on the remove) or blob id (on the parts and complete) is only dot segments: ingest's own refusal, `code` `NOT_FOUND`, before any platform call. Or the platform's own 404, its body unchanged and without `code`: on the add, list and remove, the deployment is not one of the workspace's, comfy-deploy's models switch is off, or the upload or entry is not found; on the parts and complete, comfy-builder has no such upload in the workspace (the upload routes do not check the deployment). A body with `code` is ingest's; read comfy-deploy's 404 as "not on yet" only when `code` is absent. See DeploymentModelsRefusalBody.
24796
+ * Workspace not found, the caller is not a member, the deployment id is not one, or the model id (on the remove) or blob id (on the parts and complete) is only dot segments: ingest's own refusal, `code` `NOT_FOUND`, before any platform call. Or the platform's own 404, its body unchanged and without `code`: on the add, list and remove, the deployment is not one of the workspace's, or on the add and remove is being deleted (`error` `NOT_FOUND`); on the add, the upload is not found (`error` `UPLOAD_NOT_FOUND`); on the remove, the entry is not found (`error` `NOT_FOUND`); on the parts and complete, comfy-builder has no such upload in the workspace (the upload routes do not check the deployment). A body with `code` is ingest's; one without it is the platform's. See DeploymentModelsRefusalBody.
22677
24797
  */
22678
24798
  404: PlatformPassthroughBody;
22679
24799
  /**
@@ -22690,7 +24810,7 @@ export type ListWorkspaceDeploymentModelsResponses = {
22690
24810
  /**
22691
24811
  * comfy-deploy's model list, unchanged
22692
24812
  */
22693
- 200: PlatformPassthroughBody;
24813
+ 200: DeploymentModelList;
22694
24814
  };
22695
24815
  export type ListWorkspaceDeploymentModelsResponse = ListWorkspaceDeploymentModelsResponses[keyof ListWorkspaceDeploymentModelsResponses];
22696
24816
  export type AddWorkspaceDeploymentModelData = {
@@ -22722,7 +24842,7 @@ export type AddWorkspaceDeploymentModelErrors = {
22722
24842
  */
22723
24843
  403: DeploymentModelsForbiddenBody;
22724
24844
  /**
22725
- * Workspace not found, the caller is not a member, the deployment id is not one, or the model id (on the remove) or blob id (on the parts and complete) is only dot segments: ingest's own refusal, `code` `NOT_FOUND`, before any platform call. Or the platform's own 404, its body unchanged and without `code`: on the add, list and remove, the deployment is not one of the workspace's, comfy-deploy's models switch is off, or the upload or entry is not found; on the parts and complete, comfy-builder has no such upload in the workspace (the upload routes do not check the deployment). A body with `code` is ingest's; read comfy-deploy's 404 as "not on yet" only when `code` is absent. See DeploymentModelsRefusalBody.
24845
+ * Workspace not found, the caller is not a member, the deployment id is not one, or the model id (on the remove) or blob id (on the parts and complete) is only dot segments: ingest's own refusal, `code` `NOT_FOUND`, before any platform call. Or the platform's own 404, its body unchanged and without `code`: on the add, list and remove, the deployment is not one of the workspace's, or on the add and remove is being deleted (`error` `NOT_FOUND`); on the add, the upload is not found (`error` `UPLOAD_NOT_FOUND`); on the remove, the entry is not found (`error` `NOT_FOUND`); on the parts and complete, comfy-builder has no such upload in the workspace (the upload routes do not check the deployment). A body with `code` is ingest's; one without it is the platform's. See DeploymentModelsRefusalBody.
22726
24846
  */
22727
24847
  404: PlatformPassthroughBody;
22728
24848
  /**
@@ -22743,7 +24863,7 @@ export type AddWorkspaceDeploymentModelResponses = {
22743
24863
  /**
22744
24864
  * comfy-deploy's new entry, unchanged
22745
24865
  */
22746
- 202: PlatformPassthroughBody;
24866
+ 202: DeploymentModel;
22747
24867
  };
22748
24868
  export type AddWorkspaceDeploymentModelResponse = AddWorkspaceDeploymentModelResponses[keyof AddWorkspaceDeploymentModelResponses];
22749
24869
  export type RemoveWorkspaceDeploymentModelData = {
@@ -22779,7 +24899,7 @@ export type RemoveWorkspaceDeploymentModelErrors = {
22779
24899
  */
22780
24900
  403: DeploymentModelsForbiddenBody;
22781
24901
  /**
22782
- * Workspace not found, the caller is not a member, the deployment id is not one, or the model id (on the remove) or blob id (on the parts and complete) is only dot segments: ingest's own refusal, `code` `NOT_FOUND`, before any platform call. Or the platform's own 404, its body unchanged and without `code`: on the add, list and remove, the deployment is not one of the workspace's, comfy-deploy's models switch is off, or the upload or entry is not found; on the parts and complete, comfy-builder has no such upload in the workspace (the upload routes do not check the deployment). A body with `code` is ingest's; read comfy-deploy's 404 as "not on yet" only when `code` is absent. See DeploymentModelsRefusalBody.
24902
+ * Workspace not found, the caller is not a member, the deployment id is not one, or the model id (on the remove) or blob id (on the parts and complete) is only dot segments: ingest's own refusal, `code` `NOT_FOUND`, before any platform call. Or the platform's own 404, its body unchanged and without `code`: on the add, list and remove, the deployment is not one of the workspace's, or on the add and remove is being deleted (`error` `NOT_FOUND`); on the add, the upload is not found (`error` `UPLOAD_NOT_FOUND`); on the remove, the entry is not found (`error` `NOT_FOUND`); on the parts and complete, comfy-builder has no such upload in the workspace (the upload routes do not check the deployment). A body with `code` is ingest's; one without it is the platform's. See DeploymentModelsRefusalBody.
22783
24903
  */
22784
24904
  404: PlatformPassthroughBody;
22785
24905
  /**