@comfyorg/ingest-types 1.6.0 → 1.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +1 -1
- package/dist/types.gen.d.ts +924 -51
- package/dist/zod.gen.d.ts +652 -16
- package/dist/zod.gen.js +250 -18
- package/package.json +1 -1
package/dist/types.gen.d.ts
CHANGED
|
@@ -1316,6 +1316,26 @@ export type AutoReloadPreview = {
|
|
|
1316
1316
|
*
|
|
1317
1317
|
*/
|
|
1318
1318
|
export type AutoReloadSettings = {
|
|
1319
|
+
/**
|
|
1320
|
+
* Answers one UI question: should the UI warn that auto top-up can
|
|
1321
|
+
* refill credits past a hard cap?
|
|
1322
|
+
* True: auto top-up's `status` is `on` (enabled and currently able to
|
|
1323
|
+
* charge) and the workspace has at least one live budget with
|
|
1324
|
+
* `mode: hard`. Show the warning.
|
|
1325
|
+
* False: show no warning, and read it as unknown, not as proof that
|
|
1326
|
+
* there is no conflict. Either half is missing, or the half this
|
|
1327
|
+
* response does not carry could not be read (the server then reports
|
|
1328
|
+
* false and logs it). When billing-api omits this field, ingest serves
|
|
1329
|
+
* false, so during a rollout false carries no information.
|
|
1330
|
+
* On a save it reflects the settings just saved.
|
|
1331
|
+
* Not a gate: it never blocks saving a budget or auto top-up, and it is
|
|
1332
|
+
* not authorization. Render it as received; do not compare the budget
|
|
1333
|
+
* list with the auto top-up settings to rebuild it. The same value is
|
|
1334
|
+
* served on the budget list, the budget write results and the auto
|
|
1335
|
+
* top-up settings.
|
|
1336
|
+
*
|
|
1337
|
+
*/
|
|
1338
|
+
auto_top_up_conflict: boolean;
|
|
1319
1339
|
/**
|
|
1320
1340
|
* True when the validated default card is already expired or its expiry-month boundary (00:00 UTC on the first day of the following month) is within the next 30 days. Absent or null means unknown, never a healthy-card claim. This includes non-card methods, malformed data, provider errors or a live Stripe default that differs from the recorded default payment method (for example, before a portal-change webhook syncs). Independent of status and charge eligibility; save responses omit the fact. Missing on an older server also means unknown.
|
|
1321
1341
|
*
|
|
@@ -1901,6 +1921,41 @@ export type BillingCapabilities = {
|
|
|
1901
1921
|
* Point-in-time Cloud billing guidance for this actor, combining the supplied workflow_run decision with ingest's existing account gate and cutover mode, local enrollment, Google-session requirement, and acting-user allowance. Legacy authority includes the same fail-open behavior as submission. True means these account gates allow the attempt; false has a denial when recognized. Billing-disabled environments return true. False without a reason is unknown where authoritative guidance is unavailable. No allowance is consumed or reserved. This is not authorization for a specific job or project: the submission path rechecks its full context.
|
|
1902
1922
|
*/
|
|
1903
1923
|
can_run_workflows: boolean;
|
|
1924
|
+
/**
|
|
1925
|
+
* - Answers: should the client offer creating and changing workspace
|
|
1926
|
+
* budgets (the Budgets controls)?
|
|
1927
|
+
* - True: the actor is a workspace owner (the creator alone while a
|
|
1928
|
+
* personal workspace's billing identity is not provisioned, as for
|
|
1929
|
+
* can_manage_billing), and the workspace has a
|
|
1930
|
+
* subscription whose term is open (active or canceled, with any
|
|
1931
|
+
* cancellation date still ahead) on a plan other than FREE.
|
|
1932
|
+
* - False: denied_reasons.can_set_budgets names the first refusal.
|
|
1933
|
+
* False with no reason means no recognised explanation.
|
|
1934
|
+
* - Not: authorization; the budget write endpoints decide again with
|
|
1935
|
+
* the same rule. A caller who is not a member is refused before
|
|
1936
|
+
* this rule runs, with FORBIDDEN and no reason from this list. Not whether a hard cap may be set
|
|
1937
|
+
* (can_set_hard_caps). Not whether budgets may be read: any member
|
|
1938
|
+
* may read the budget on themselves. Payment state (past due,
|
|
1939
|
+
* paused top-ups) does not affect it.
|
|
1940
|
+
* - When billing-api omits this field, ingest serves false, with no reason.
|
|
1941
|
+
*
|
|
1942
|
+
*/
|
|
1943
|
+
can_set_budgets: boolean;
|
|
1944
|
+
/**
|
|
1945
|
+
* - Answers: should the client unlock the hard-cap control on a
|
|
1946
|
+
* budget, or show it locked with the path to sales?
|
|
1947
|
+
* - True: can_set_budgets is true and the plan is Enterprise.
|
|
1948
|
+
* - False: denied_reasons.can_set_hard_caps names the first refusal.
|
|
1949
|
+
* False with no reason means no recognised explanation.
|
|
1950
|
+
* `plan_not_enterprise` is the one case where budgets are available
|
|
1951
|
+
* and only the hard cap is locked.
|
|
1952
|
+
* - Not: authorization. Not whether soft budgets may be set
|
|
1953
|
+
* (can_set_budgets). A budget that is already hard stays editable
|
|
1954
|
+
* after a downgrade; this field is about setting a new hard cap.
|
|
1955
|
+
* - When billing-api omits this field, ingest serves false, with no reason.
|
|
1956
|
+
*
|
|
1957
|
+
*/
|
|
1958
|
+
can_set_hard_caps: boolean;
|
|
1904
1959
|
/**
|
|
1905
1960
|
* - Answers: may this user start, recover or change a self-serve plan?
|
|
1906
1961
|
* - True: the user is a workspace owner and no resolver branch closed it. When
|
|
@@ -2032,6 +2087,21 @@ export type BillingCapabilitiesResponse = {
|
|
|
2032
2087
|
*
|
|
2033
2088
|
*/
|
|
2034
2089
|
billing_web_checkout_ui: 'embedded' | 'full_page';
|
|
2090
|
+
/**
|
|
2091
|
+
* Whether a cancel requested now ends the plan today instead of at the
|
|
2092
|
+
* end of the billing period. True only when can_cancel is true, the
|
|
2093
|
+
* workspace payment state is payment_failed or paused, and the provider
|
|
2094
|
+
* confirms its bound live Stripe subscription is past_due or unpaid: the
|
|
2095
|
+
* cancel then ends it immediately, stops payment retries, and bills no
|
|
2096
|
+
* unpaid period. False when can_cancel is false or the cancel is
|
|
2097
|
+
* scheduled for period end, including a provider-paused subscription.
|
|
2098
|
+
* No denied_reasons key explains it. Absent when the live binding or
|
|
2099
|
+
* provider state cannot be verified, on older servers, or when billing
|
|
2100
|
+
* is disabled; absence means unknown. Not authorization: the cancel
|
|
2101
|
+
* route rechecks the provider and its cancel_at is the result.
|
|
2102
|
+
*
|
|
2103
|
+
*/
|
|
2104
|
+
cancel_takes_effect_immediately?: boolean;
|
|
2035
2105
|
capabilities: BillingCapabilities;
|
|
2036
2106
|
denied_reason_params?: BillingCapabilityDenialParams;
|
|
2037
2107
|
denied_reasons?: BillingCapabilityDenials;
|
|
@@ -2476,6 +2546,33 @@ export type BillingCapabilityDenials = {
|
|
|
2476
2546
|
*
|
|
2477
2547
|
*/
|
|
2478
2548
|
can_run_workflows?: 'manual_block' | 'subscription_inactive' | 'payment_past_due' | 'no_funds' | 'workspace_cap_exceeded' | 'project_cap_exceeded' | 'user_cap_exceeded' | 'free_tier_exhausted';
|
|
2549
|
+
/**
|
|
2550
|
+
* Why can_set_budgets 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: the role refusals, then the plan refusals. The status branches never compete, since a subscription has one status.
|
|
2551
|
+
* - not_a_member: The actor is not a workspace member.
|
|
2552
|
+
* - not_workspace_owner: The actor is a member whose role is not owner.
|
|
2553
|
+
* - creator_only_provisioning: Only the creator can act on this personal workspace's billing until its billing identity is provisioned.
|
|
2554
|
+
* - no_subscription: The workspace has no subscription, so it has no billing period to budget over.
|
|
2555
|
+
* - free_plan: The plan is FREE, whose usage is not charged spend.
|
|
2556
|
+
* - subscription_ended: The subscription has stopped for good, ended or canceled with no end date ahead.
|
|
2557
|
+
* - subscription_not_started: The subscription is scheduled and has not started.
|
|
2558
|
+
* - subscription_status_unrecognized: The subscription status is one the resolver has no guidance for.
|
|
2559
|
+
*
|
|
2560
|
+
*/
|
|
2561
|
+
can_set_budgets?: 'not_a_member' | 'not_workspace_owner' | 'creator_only_provisioning' | 'no_subscription' | 'free_plan' | 'subscription_ended' | 'subscription_not_started' | 'subscription_status_unrecognized';
|
|
2562
|
+
/**
|
|
2563
|
+
* Why can_set_hard_caps 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: every can_set_budgets refusal in its order, then the plan check.
|
|
2564
|
+
* - not_a_member: The actor is not a workspace member.
|
|
2565
|
+
* - not_workspace_owner: The actor is a member whose role is not owner.
|
|
2566
|
+
* - creator_only_provisioning: Only the creator can act on this personal workspace's billing until its billing identity is provisioned.
|
|
2567
|
+
* - no_subscription: The workspace has no subscription.
|
|
2568
|
+
* - free_plan: The plan is FREE.
|
|
2569
|
+
* - subscription_ended: The subscription has stopped for good.
|
|
2570
|
+
* - subscription_not_started: The subscription is scheduled and has not started.
|
|
2571
|
+
* - subscription_status_unrecognized: The subscription status is one the resolver has no guidance for.
|
|
2572
|
+
* - plan_not_enterprise: Budgets are available, but hard caps are an Enterprise feature. Show the control locked and offer the path to sales.
|
|
2573
|
+
*
|
|
2574
|
+
*/
|
|
2575
|
+
can_set_hard_caps?: 'not_a_member' | 'not_workspace_owner' | 'creator_only_provisioning' | 'no_subscription' | 'free_plan' | 'subscription_ended' | 'subscription_not_started' | 'subscription_status_unrecognized' | 'plan_not_enterprise';
|
|
2479
2576
|
/**
|
|
2480
2577
|
* Present only when can_subscribe_self_serve is false. The value names the
|
|
2481
2578
|
* resolver branch that decided, not customer wording. Values are listed in the
|
|
@@ -2676,7 +2773,7 @@ export type BillingEvent = {
|
|
|
2676
2773
|
*/
|
|
2677
2774
|
member_user_id?: string;
|
|
2678
2775
|
/**
|
|
2679
|
-
* Event-specific parameters
|
|
2776
|
+
* Event-specific parameters. On a usage row, `credits_used` is what the row cost in credits. A `cloud_workflow_executed` (GPU run) row carries it when the usage ledger holds a charge for the run. Absent means the charge is unknown (a run from before the ledger began, an unpriced row, or the ledger could not be read); it must not be read as a free run.
|
|
2680
2777
|
*/
|
|
2681
2778
|
params?: {
|
|
2682
2779
|
[key: string]: unknown;
|
|
@@ -2712,14 +2809,35 @@ export type BillingEventsResponse = {
|
|
|
2712
2809
|
*/
|
|
2713
2810
|
totalPages: number;
|
|
2714
2811
|
};
|
|
2812
|
+
/**
|
|
2813
|
+
* The plan a Platform billing tab continues to checkout with. Selections only; checkout prices them.
|
|
2814
|
+
*/
|
|
2815
|
+
export type BillingHandoffCheckoutRequest = {
|
|
2816
|
+
/**
|
|
2817
|
+
* Plan the checkout opens with, as GET /api/billing/plans names it. Sent in the entry URL's query as `plan`.
|
|
2818
|
+
*/
|
|
2819
|
+
plan_slug: string;
|
|
2820
|
+
/**
|
|
2821
|
+
* Team credit stop the checkout opens with, for a per-credit Team plan. Sent in the entry URL's query as `team_credit_stop_id`.
|
|
2822
|
+
*/
|
|
2823
|
+
team_credit_stop_id?: string;
|
|
2824
|
+
};
|
|
2715
2825
|
/**
|
|
2716
2826
|
* Asks for a one-time handoff that signs a billing receiver tab in as the caller.
|
|
2717
2827
|
*/
|
|
2718
2828
|
export type BillingHandoffCreateRequest = {
|
|
2829
|
+
/**
|
|
2830
|
+
* 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.
|
|
2831
|
+
*/
|
|
2832
|
+
amount_cents?: number;
|
|
2719
2833
|
/**
|
|
2720
2834
|
* Version of the issuing app, for logs.
|
|
2721
2835
|
*/
|
|
2722
2836
|
client_version: string;
|
|
2837
|
+
/**
|
|
2838
|
+
* Page the receiver opens after the exchange: top-up opens the credit checkout, subscription the plan checkout, none the receiver's billing home. Only billing_web accepts one; platform answers 400 INVALID_REQUEST. Sent in the entry URL's query, never its fragment. It is not a credential and grants nothing.
|
|
2839
|
+
*/
|
|
2840
|
+
intent?: 'top-up' | 'subscription';
|
|
2723
2841
|
/**
|
|
2724
2842
|
* Billing app that will exchange the handoff; its origin is the only one the exchange accepts.
|
|
2725
2843
|
*/
|
|
@@ -2738,7 +2856,7 @@ export type BillingHandoffCreateRequest = {
|
|
|
2738
2856
|
*/
|
|
2739
2857
|
export type BillingHandoffCreateResponse = {
|
|
2740
2858
|
/**
|
|
2741
|
-
* The receiver's handoff page with the token in the fragment. Open it, never display it.
|
|
2859
|
+
* The receiver's handoff page, with the intent and amount_cents (if any) in the query and the token in the fragment. Open it, never display it.
|
|
2742
2860
|
*/
|
|
2743
2861
|
entry_url: string;
|
|
2744
2862
|
/**
|
|
@@ -2868,6 +2986,20 @@ export type BillingOpChargeReason = {
|
|
|
2868
2986
|
*/
|
|
2869
2987
|
kind: 'promo_code' | 'subscription_discount' | 'account_balance';
|
|
2870
2988
|
};
|
|
2989
|
+
/**
|
|
2990
|
+
* How a billing operation ended, for a billing handoff tab whose scoped session has ended.
|
|
2991
|
+
*/
|
|
2992
|
+
export type BillingOpOutcomeResponse = {
|
|
2993
|
+
/**
|
|
2994
|
+
* The `status` that `GET /api/billing/ops/{id}` reports for the same
|
|
2995
|
+
* operation. It answers whether the payment has finished and how:
|
|
2996
|
+
* pending means keep polling, the other three are final for polling.
|
|
2997
|
+
* It does not say why a payment failed or what the customer can do
|
|
2998
|
+
* next.
|
|
2999
|
+
*
|
|
3000
|
+
*/
|
|
3001
|
+
status: 'pending' | 'succeeded' | 'failed' | 'reconciliation_needed';
|
|
3002
|
+
};
|
|
2871
3003
|
/**
|
|
2872
3004
|
* Display only. The plan the operation targets; for a scheduled change,
|
|
2873
3005
|
* the plan it switches to at period end. Present for plan changes,
|
|
@@ -2953,8 +3085,10 @@ export type BillingOpStatusResponse = {
|
|
|
2953
3085
|
authentication_deadline?: string;
|
|
2954
3086
|
/**
|
|
2955
3087
|
* State derived from the PaymentIntent attached to this operation's
|
|
2956
|
-
* exact stored Stripe invoice.
|
|
2957
|
-
*
|
|
3088
|
+
* exact stored Stripe invoice. One exception: a pending plan change
|
|
3089
|
+
* saving a new card reports requires_action while that card's
|
|
3090
|
+
* SetupIntent awaits 3-D Secure, before any invoice exists. Absent
|
|
3091
|
+
* when the operation has neither.
|
|
2958
3092
|
*
|
|
2959
3093
|
*/
|
|
2960
3094
|
authentication_state?: 'requires_action' | 'processing' | 'failed_retryable' | 'succeeded' | 'reconciliation_needed';
|
|
@@ -3015,9 +3149,11 @@ export type BillingOpStatusResponse = {
|
|
|
3015
3149
|
*/
|
|
3016
3150
|
id: string;
|
|
3017
3151
|
/**
|
|
3018
|
-
* Stripe
|
|
3019
|
-
*
|
|
3020
|
-
*
|
|
3152
|
+
* Stripe client secret for completing requires_action: the invoice's
|
|
3153
|
+
* PaymentIntent, or for a plan change saving a new card, that card's
|
|
3154
|
+
* SetupIntent (pass either to Stripe.js handleNextAction). This bearer
|
|
3155
|
+
* capability is returned only to workspace billing managers and is
|
|
3156
|
+
* absent otherwise.
|
|
3021
3157
|
*
|
|
3022
3158
|
*/
|
|
3023
3159
|
payment_intent_client_secret?: string;
|
|
@@ -3027,7 +3163,11 @@ export type BillingOpStatusResponse = {
|
|
|
3027
3163
|
* The two awaiting_ values are blocked on the customer and will not
|
|
3028
3164
|
* advance on their own: awaiting_payment_method is parked on a hosted
|
|
3029
3165
|
* checkout needing a card, awaiting_invoice_payment on an invoice
|
|
3030
|
-
* needing payment or authentication
|
|
3166
|
+
* needing payment or authentication, or on a plan change's new card
|
|
3167
|
+
* awaiting 3-D Secure before any invoice exists (then
|
|
3168
|
+
* authentication_state is requires_action and
|
|
3169
|
+
* payment_intent_client_secret is that card's SetupIntent secret).
|
|
3170
|
+
* in_progress means the operation
|
|
3031
3171
|
* is ours to finish, so polling is the right response. Deliberately
|
|
3032
3172
|
* coarser than the internal phase — phases that differ only in what
|
|
3033
3173
|
* the workflow is doing all report in_progress. Absent for a terminal
|
|
@@ -3097,7 +3237,7 @@ export type BillingStatusResponse = {
|
|
|
3097
3237
|
*/
|
|
3098
3238
|
cancel_at?: string;
|
|
3099
3239
|
/**
|
|
3100
|
-
* When the current
|
|
3240
|
+
* When the current subscription term began. Together with renewal_date it is the term the plan renews over (a year on an annual plan); render the pair as received rather than deriving one from the other. It is not the window usage and budgets are counted over: use usage_period_start and usage_period_end for that. Present exactly when renewal_date is: omitted for a canceled plan, a never-subscribed workspace and a free plan with no subscription.
|
|
3101
3241
|
*/
|
|
3102
3242
|
current_period_start?: string;
|
|
3103
3243
|
/**
|
|
@@ -3179,7 +3319,7 @@ export type BillingStatusResponse = {
|
|
|
3179
3319
|
*/
|
|
3180
3320
|
previous_plan?: PreviousPlan;
|
|
3181
3321
|
/**
|
|
3182
|
-
* When the current
|
|
3322
|
+
* When the current subscription term ends and the next one begins: the end of the term current_period_start begins.
|
|
3183
3323
|
*/
|
|
3184
3324
|
renewal_date?: string;
|
|
3185
3325
|
renewal_invoice?: RenewalInvoice;
|
|
@@ -3214,6 +3354,14 @@ export type BillingStatusResponse = {
|
|
|
3214
3354
|
* The team credit stop the workspace is currently subscribed to, for per-credit Team plans (BE-1254). Lets clients tell apart team subscriptions, which all share subscription_tier=TEAM. Always present; null for personal plans (use subscription_tier to distinguish those) and for legacy team plans without a credit stop.
|
|
3215
3355
|
*/
|
|
3216
3356
|
team_credit_stop: TeamCreditStopSummary | null;
|
|
3357
|
+
/**
|
|
3358
|
+
* End (exclusive) of the period usage_period_start begins, and when a budget's spend next resets. Not the renewal date: on an annual plan it is the next monthly anniversary, and for a subscription set to cancel it is never later than the cancellation.
|
|
3359
|
+
*/
|
|
3360
|
+
usage_period_end?: string;
|
|
3361
|
+
/**
|
|
3362
|
+
* 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.
|
|
3363
|
+
*/
|
|
3364
|
+
usage_period_start?: string;
|
|
3217
3365
|
};
|
|
3218
3366
|
/**
|
|
3219
3367
|
* A tax identifier for a company Stripe customer. Stripe validates the
|
|
@@ -3231,6 +3379,210 @@ export type BillingTaxId = {
|
|
|
3231
3379
|
type: string;
|
|
3232
3380
|
value: string;
|
|
3233
3381
|
};
|
|
3382
|
+
/**
|
|
3383
|
+
* 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.
|
|
3384
|
+
*
|
|
3385
|
+
*/
|
|
3386
|
+
export type Budget = {
|
|
3387
|
+
/**
|
|
3388
|
+
* The percentages of the limit at which an alert is sent, ascending.
|
|
3389
|
+
*/
|
|
3390
|
+
alert_percents: Array<number>;
|
|
3391
|
+
/**
|
|
3392
|
+
* Alerts sent for the budget in the current period. Always `[]` until alerting ships.
|
|
3393
|
+
*/
|
|
3394
|
+
alerts: Array<BudgetAlert>;
|
|
3395
|
+
/**
|
|
3396
|
+
* User id that created the budget.
|
|
3397
|
+
*/
|
|
3398
|
+
created_by: string;
|
|
3399
|
+
/**
|
|
3400
|
+
* End of the last billing period the budget applies to; null when it repeats indefinitely.
|
|
3401
|
+
*/
|
|
3402
|
+
ends_at: string | null;
|
|
3403
|
+
id: string;
|
|
3404
|
+
/**
|
|
3405
|
+
* The limit in credits, rounded to the nearest credit.
|
|
3406
|
+
*/
|
|
3407
|
+
limit_credits: number;
|
|
3408
|
+
/**
|
|
3409
|
+
* The limit as stored, in micro-USD of list value.
|
|
3410
|
+
*/
|
|
3411
|
+
limit_micro_usd: number;
|
|
3412
|
+
mode: BudgetMode;
|
|
3413
|
+
/**
|
|
3414
|
+
* Whole percent of the limit spent, rounded down, so 100 means the limit is reached. It can exceed 100.
|
|
3415
|
+
*
|
|
3416
|
+
*/
|
|
3417
|
+
percent_used: number;
|
|
3418
|
+
repeat: BudgetRepeat;
|
|
3419
|
+
/**
|
|
3420
|
+
* When spend next resets to 0: the end of the current billing period. Null when the workspace has no billing period.
|
|
3421
|
+
*
|
|
3422
|
+
*/
|
|
3423
|
+
resets_at: string | null;
|
|
3424
|
+
/**
|
|
3425
|
+
* The workspace id, the member's user id, the API key's prefix or the deployment id.
|
|
3426
|
+
*/
|
|
3427
|
+
scope_id: string;
|
|
3428
|
+
scope_kind: BudgetScopeKind;
|
|
3429
|
+
/**
|
|
3430
|
+
* When the totals behind spent_micro_usd were last written. Shows how fresh the spend is: a deployment's usage arrives hourly. Null when the scope has spent nothing this period.
|
|
3431
|
+
*
|
|
3432
|
+
*/
|
|
3433
|
+
spend_updated_at: string | null;
|
|
3434
|
+
/**
|
|
3435
|
+
* spent_micro_usd in credits, rounded to the nearest credit.
|
|
3436
|
+
*/
|
|
3437
|
+
spent_credits: number;
|
|
3438
|
+
/**
|
|
3439
|
+
* What the scope has spent since the current billing period began: the charged usage the usage page counts for the same range. A member budget counts session spend only; spend through the member's API keys counts toward the key. 0 when the workspace has no billing period.
|
|
3440
|
+
*
|
|
3441
|
+
*/
|
|
3442
|
+
spent_micro_usd: number;
|
|
3443
|
+
/**
|
|
3444
|
+
* User id that last changed the budget.
|
|
3445
|
+
*/
|
|
3446
|
+
updated_by: string;
|
|
3447
|
+
};
|
|
3448
|
+
export type BudgetAlert = {
|
|
3449
|
+
percent: number;
|
|
3450
|
+
sent_at: string;
|
|
3451
|
+
status: string;
|
|
3452
|
+
};
|
|
3453
|
+
export type BudgetChange = {
|
|
3454
|
+
action: 'created' | 'updated' | 'archived' | 'downgraded';
|
|
3455
|
+
/**
|
|
3456
|
+
* User id that made the change, or `system` for one the platform made.
|
|
3457
|
+
*/
|
|
3458
|
+
actor_user_id: string;
|
|
3459
|
+
/**
|
|
3460
|
+
* The budget's settings after the change; null for `archived`.
|
|
3461
|
+
*/
|
|
3462
|
+
after: {
|
|
3463
|
+
[key: string]: unknown;
|
|
3464
|
+
} | null;
|
|
3465
|
+
/**
|
|
3466
|
+
* The budget's settings before the change; null for `created`.
|
|
3467
|
+
*/
|
|
3468
|
+
before: {
|
|
3469
|
+
[key: string]: unknown;
|
|
3470
|
+
} | null;
|
|
3471
|
+
changed_at: string;
|
|
3472
|
+
};
|
|
3473
|
+
export type BudgetCreateRequest = {
|
|
3474
|
+
/**
|
|
3475
|
+
* Ascending, no repeats. Defaults to [50, 80, 100].
|
|
3476
|
+
*/
|
|
3477
|
+
alert_percents?: Array<number>;
|
|
3478
|
+
/**
|
|
3479
|
+
* Required with `repeat: until`, and must be in the future; refused with any other repeat.
|
|
3480
|
+
*/
|
|
3481
|
+
ends_at?: string;
|
|
3482
|
+
/**
|
|
3483
|
+
* The limit in credits. Send exactly one of limit_credits and limit_micro_usd.
|
|
3484
|
+
*/
|
|
3485
|
+
limit_credits?: number;
|
|
3486
|
+
/**
|
|
3487
|
+
* The limit in micro-USD. Send exactly one of limit_credits and limit_micro_usd.
|
|
3488
|
+
*/
|
|
3489
|
+
limit_micro_usd?: number;
|
|
3490
|
+
mode: BudgetMode;
|
|
3491
|
+
/**
|
|
3492
|
+
* Defaults to current_period.
|
|
3493
|
+
*/
|
|
3494
|
+
repeat?: BudgetRepeat;
|
|
3495
|
+
/**
|
|
3496
|
+
* The workspace id (for `workspace`, it must be this workspace), the member's user id, the API key's prefix or the deployment id.
|
|
3497
|
+
*
|
|
3498
|
+
*/
|
|
3499
|
+
scope_id: string;
|
|
3500
|
+
scope_kind: BudgetScopeKind;
|
|
3501
|
+
};
|
|
3502
|
+
export type BudgetHistory = {
|
|
3503
|
+
changes: Array<BudgetChange>;
|
|
3504
|
+
};
|
|
3505
|
+
export type BudgetList = {
|
|
3506
|
+
/**
|
|
3507
|
+
* Answers one UI question: should the UI warn that auto top-up can
|
|
3508
|
+
* refill credits past a hard cap?
|
|
3509
|
+
* True: auto top-up's `status` is `on` (enabled and currently able to
|
|
3510
|
+
* charge) and the workspace has at least one live budget with
|
|
3511
|
+
* `mode: hard`. Show the warning.
|
|
3512
|
+
* False: show no warning, and read it as unknown, not as proof that
|
|
3513
|
+
* there is no conflict. Either half is missing, or the half this
|
|
3514
|
+
* response does not carry could not be read (the server then reports
|
|
3515
|
+
* false and logs it). When billing-api omits this field, ingest serves
|
|
3516
|
+
* false, so during a rollout false carries no information.
|
|
3517
|
+
* Always false for a member who is not an owner: it is an owner-facing warning.
|
|
3518
|
+
* Not a gate: it never blocks saving a budget or auto top-up, and it is
|
|
3519
|
+
* not authorization. Render it as received; do not compare the budget
|
|
3520
|
+
* list with the auto top-up settings to rebuild it. The same value is
|
|
3521
|
+
* served on the budget list, the budget write results and the auto
|
|
3522
|
+
* top-up settings.
|
|
3523
|
+
*
|
|
3524
|
+
*/
|
|
3525
|
+
auto_top_up_conflict: boolean;
|
|
3526
|
+
budgets: Array<Budget>;
|
|
3527
|
+
};
|
|
3528
|
+
/**
|
|
3529
|
+
* `soft` alerts at its thresholds and never refuses spend. `hard` also refuses spend once the limit is reached; Enterprise plans only.
|
|
3530
|
+
*
|
|
3531
|
+
*/
|
|
3532
|
+
export type BudgetMode = 'hard' | 'soft';
|
|
3533
|
+
/**
|
|
3534
|
+
* How long a budget applies. `current_period`: until the current billing period ends. `until`: through the period holding `ends_at`. `indefinitely`: every period, with no end.
|
|
3535
|
+
*
|
|
3536
|
+
*/
|
|
3537
|
+
export type BudgetRepeat = 'current_period' | 'until' | 'indefinitely';
|
|
3538
|
+
/**
|
|
3539
|
+
* What a budget limits.
|
|
3540
|
+
*/
|
|
3541
|
+
export type BudgetScopeKind = 'workspace' | 'member' | 'api_key' | 'deployment';
|
|
3542
|
+
export type BudgetUpdateRequest = {
|
|
3543
|
+
/**
|
|
3544
|
+
* Ascending, no repeats.
|
|
3545
|
+
*/
|
|
3546
|
+
alert_percents?: Array<number>;
|
|
3547
|
+
/**
|
|
3548
|
+
* With `repeat: until`, or alone (which means the same): the new end, in the future. Refused with any other repeat.
|
|
3549
|
+
*
|
|
3550
|
+
*/
|
|
3551
|
+
ends_at?: string;
|
|
3552
|
+
/**
|
|
3553
|
+
* The new limit in credits. Send at most one of limit_credits and limit_micro_usd.
|
|
3554
|
+
*/
|
|
3555
|
+
limit_credits?: number;
|
|
3556
|
+
/**
|
|
3557
|
+
* The new limit in micro-USD. Send at most one of limit_credits and limit_micro_usd.
|
|
3558
|
+
*/
|
|
3559
|
+
limit_micro_usd?: number;
|
|
3560
|
+
mode?: BudgetMode;
|
|
3561
|
+
repeat?: BudgetRepeat;
|
|
3562
|
+
};
|
|
3563
|
+
export type BudgetWriteResult = {
|
|
3564
|
+
/**
|
|
3565
|
+
* Answers one UI question: should the UI warn that auto top-up can
|
|
3566
|
+
* refill credits past a hard cap?
|
|
3567
|
+
* True: auto top-up's `status` is `on` (enabled and currently able to
|
|
3568
|
+
* charge) and the workspace has at least one live budget with
|
|
3569
|
+
* `mode: hard`. Show the warning.
|
|
3570
|
+
* False: show no warning, and read it as unknown, not as proof that
|
|
3571
|
+
* there is no conflict. Either half is missing, or the half this
|
|
3572
|
+
* response does not carry could not be read (the server then reports
|
|
3573
|
+
* false and logs it). When billing-api omits this field, ingest serves
|
|
3574
|
+
* false, so during a rollout false carries no information.
|
|
3575
|
+
* Reflects the workspace after this write, the written budget included.
|
|
3576
|
+
* Not a gate: it never blocks saving a budget or auto top-up, and it is
|
|
3577
|
+
* not authorization. Render it as received; do not compare the budget
|
|
3578
|
+
* list with the auto top-up settings to rebuild it. The same value is
|
|
3579
|
+
* served on the budget list, the budget write results and the auto
|
|
3580
|
+
* top-up settings.
|
|
3581
|
+
*
|
|
3582
|
+
*/
|
|
3583
|
+
auto_top_up_conflict: boolean;
|
|
3584
|
+
budget: Budget;
|
|
3585
|
+
};
|
|
3234
3586
|
/**
|
|
3235
3587
|
* Response after bulk-revoking API keys for a workspace member.
|
|
3236
3588
|
*/
|
|
@@ -3532,6 +3884,10 @@ export type CccPageRow = {
|
|
|
3532
3884
|
* Deleted in Draft.
|
|
3533
3885
|
*/
|
|
3534
3886
|
is_deleted: boolean;
|
|
3887
|
+
/**
|
|
3888
|
+
* The Draft head lists desktop_starters in available_surfaces. status does not read it.
|
|
3889
|
+
*/
|
|
3890
|
+
on_desktop: boolean;
|
|
3535
3891
|
/**
|
|
3536
3892
|
* The Draft head lists hub in available_surfaces. The website serves only such pages.
|
|
3537
3893
|
*/
|
|
@@ -3825,7 +4181,7 @@ export type CccWebsiteCardsPage = {
|
|
|
3825
4181
|
page_size: number;
|
|
3826
4182
|
previous_cursor?: string;
|
|
3827
4183
|
revision_id: number;
|
|
3828
|
-
sort_orders: Array<'popular' | 'name' | 'priceAsc' | 'priceDesc'>;
|
|
4184
|
+
sort_orders: Array<'popular' | 'name' | 'newest' | 'priceAsc' | 'priceDesc'>;
|
|
3829
4185
|
/**
|
|
3830
4186
|
* Staff-only filtered count; omitted for anonymous callers
|
|
3831
4187
|
*/
|
|
@@ -3874,7 +4230,7 @@ export type CccWebsiteRootPresentation = {
|
|
|
3874
4230
|
export type CccWebsiteRootTab = {
|
|
3875
4231
|
facets: CccWebsiteCardFacets;
|
|
3876
4232
|
page: CccWebsiteRootPageInfo;
|
|
3877
|
-
sort_orders: Array<'popular' | 'name' | 'priceAsc' | 'priceDesc'>;
|
|
4233
|
+
sort_orders: Array<'popular' | 'name' | 'newest' | 'priceAsc' | 'priceDesc'>;
|
|
3878
4234
|
};
|
|
3879
4235
|
export type CccWebsiteRootTabs = {
|
|
3880
4236
|
apps: CccWebsiteRootTab;
|
|
@@ -5909,7 +6265,15 @@ export type ListAssetsResponse = {
|
|
|
5909
6265
|
*/
|
|
5910
6266
|
next_cursor?: string;
|
|
5911
6267
|
/**
|
|
5912
|
-
*
|
|
6268
|
+
* Number of assets matching the filters, counted up to 10,000 unless
|
|
6269
|
+
* the request sends `capped_total=false`. A capped 10,000 means "at
|
|
6270
|
+
* least 10,000" and must not be read as the exact count or used to
|
|
6271
|
+
* work out the last page. With `include_total=false` no count runs
|
|
6272
|
+
* and `total` is a lower bound: the assets through this page (on an
|
|
6273
|
+
* offset page, the skipped `offset` rows included), plus one when
|
|
6274
|
+
* `has_more` is true, and 0 for an empty page. To page, follow
|
|
6275
|
+
* `has_more` and `next_cursor`, which do not depend on the total.
|
|
6276
|
+
*
|
|
5913
6277
|
*/
|
|
5914
6278
|
total: number;
|
|
5915
6279
|
};
|
|
@@ -6357,7 +6721,7 @@ export type OAuthConsentChallengeWorkspace = {
|
|
|
6357
6721
|
/**
|
|
6358
6722
|
* The platform this authorization code will be delivered to, when the
|
|
6359
6723
|
* request's validated redirect_uri is one of a known platform's own OAuth
|
|
6360
|
-
* callbacks (ChatGPT, Claude). Derived server-side ONLY from the
|
|
6724
|
+
* callbacks (ChatGPT, Claude, Cursor). Derived server-side ONLY from the
|
|
6361
6725
|
* redirect_uri this request was byte-matched against at GET time —
|
|
6362
6726
|
* never from the registrant-supplied client_name — against a
|
|
6363
6727
|
* version-controlled registry of exact callbacks and anchored callback
|
|
@@ -6365,8 +6729,10 @@ export type OAuthConsentChallengeWorkspace = {
|
|
|
6365
6729
|
* clients; omitted for first-party clients and for any redirect that is
|
|
6366
6730
|
* not a registered platform callback. It verifies the destination
|
|
6367
6731
|
* platform, NOT that the registrant is that platform's own app (any
|
|
6368
|
-
* connector on the platform can hold such a callback
|
|
6369
|
-
*
|
|
6732
|
+
* connector on the platform can hold such a callback, and any local
|
|
6733
|
+
* process can listen on Cursor's loopback callback or claim its
|
|
6734
|
+
* `cursor://` scheme), so consumers should label it by `display_name`
|
|
6735
|
+
* and still show the redirect host.
|
|
6370
6736
|
* `client_display_name` is unchanged and remains registrant-supplied.
|
|
6371
6737
|
*
|
|
6372
6738
|
*/
|
|
@@ -6378,7 +6744,7 @@ export type OAuthConsentVerifiedClient = {
|
|
|
6378
6744
|
/**
|
|
6379
6745
|
* Stable identifier of the verified platform.
|
|
6380
6746
|
*/
|
|
6381
|
-
platform: 'chatgpt' | 'claude';
|
|
6747
|
+
platform: 'chatgpt' | 'claude' | 'cursor';
|
|
6382
6748
|
};
|
|
6383
6749
|
/**
|
|
6384
6750
|
* OAuth 2.1 protected-resource metadata (RFC 9728).
|
|
@@ -6566,7 +6932,13 @@ export type PaginationInfo = {
|
|
|
6566
6932
|
*/
|
|
6567
6933
|
offset: number;
|
|
6568
6934
|
/**
|
|
6569
|
-
*
|
|
6935
|
+
* Number of items matching the filters (may be 0 when using cursor
|
|
6936
|
+
* pagination). `GET /api/jobs` counts it up to 10,000 unless the
|
|
6937
|
+
* request sends `capped_total=false`, so 10,000 there means "at
|
|
6938
|
+
* least 10,000" and must not be read as the exact count or used to
|
|
6939
|
+
* work out the last page. To page, follow `has_more` and
|
|
6940
|
+
* `next_cursor`, which do not depend on the total.
|
|
6941
|
+
*
|
|
6570
6942
|
*/
|
|
6571
6943
|
total: number;
|
|
6572
6944
|
};
|
|
@@ -7082,6 +7454,70 @@ export type PromptInfo = {
|
|
|
7082
7454
|
queue_remaining?: number;
|
|
7083
7455
|
};
|
|
7084
7456
|
};
|
|
7457
|
+
/**
|
|
7458
|
+
* The `data` of a prompt_outputs_skipped WebSocket event. Sent when ComfyUI accepts a Cloud job's prompt but rejects some nodes: ComfyUI skips the outputs that depend on them and runs the rest, and the job keeps running. The inference server sends it to the user's channel (services/inference/server/services/joborchestrator/prompt_validation.go). Every string taken from ComfyUI has its lists of allowed values or file names replaced ("is not a valid value", "[list omitted]") and is capped at 512 characters.
|
|
7459
|
+
*/
|
|
7460
|
+
export type PromptOutputsSkippedData = {
|
|
7461
|
+
/**
|
|
7462
|
+
* The rejected nodes, keyed by node id, in the shape ComfyUI's /prompt returns. At most 50 nodes, the lowest ids kept, and 64 KiB as JSON.
|
|
7463
|
+
*/
|
|
7464
|
+
node_errors: {
|
|
7465
|
+
[key: string]: PromptOutputsSkippedNodeError;
|
|
7466
|
+
};
|
|
7467
|
+
/**
|
|
7468
|
+
* The Cloud job id.
|
|
7469
|
+
*/
|
|
7470
|
+
prompt_id: string;
|
|
7471
|
+
};
|
|
7472
|
+
/**
|
|
7473
|
+
* Server-to-client prompt_outputs_skipped frame on /ws. ComfyUI skipped some of a Cloud job's outputs because nodes failed validation.
|
|
7474
|
+
*/
|
|
7475
|
+
export type PromptOutputsSkippedFrame = {
|
|
7476
|
+
data: PromptOutputsSkippedData;
|
|
7477
|
+
type: 'prompt_outputs_skipped';
|
|
7478
|
+
};
|
|
7479
|
+
/**
|
|
7480
|
+
* One rejected node in a prompt_outputs_skipped event.
|
|
7481
|
+
*/
|
|
7482
|
+
export type PromptOutputsSkippedNodeError = {
|
|
7483
|
+
/**
|
|
7484
|
+
* The node's type. Empty when ComfyUI sent none.
|
|
7485
|
+
*/
|
|
7486
|
+
class_type: string;
|
|
7487
|
+
/**
|
|
7488
|
+
* The ids of the output nodes ComfyUI skipped because of this node, at most 50. Only ids ComfyUI sent as strings are kept; any other entry is dropped.
|
|
7489
|
+
*/
|
|
7490
|
+
dependent_outputs: Array<string>;
|
|
7491
|
+
/**
|
|
7492
|
+
* Why ComfyUI rejected the node, at most 10. A custom node's validator may report a bare string, which is sent as that string. Can be empty when the size cap left no room for the node's errors.
|
|
7493
|
+
*/
|
|
7494
|
+
errors: Array<string | PromptOutputsSkippedValidationError>;
|
|
7495
|
+
};
|
|
7496
|
+
/**
|
|
7497
|
+
* One validation error as ComfyUI reports it, with tracebacks and every other field removed. type, message and details are each present only when ComfyUI sent them as strings.
|
|
7498
|
+
*/
|
|
7499
|
+
export type PromptOutputsSkippedValidationError = {
|
|
7500
|
+
details?: string;
|
|
7501
|
+
/**
|
|
7502
|
+
* Only the keys the editor reads, each present when ComfyUI sent it. A list or object value becomes the string "[list omitted]".
|
|
7503
|
+
*/
|
|
7504
|
+
extra_info?: {
|
|
7505
|
+
/**
|
|
7506
|
+
* The input the error belongs to.
|
|
7507
|
+
*/
|
|
7508
|
+
input_name?: string | number | boolean;
|
|
7509
|
+
/**
|
|
7510
|
+
* The type the node received.
|
|
7511
|
+
*/
|
|
7512
|
+
received_type?: string | number | boolean;
|
|
7513
|
+
/**
|
|
7514
|
+
* The value the node received.
|
|
7515
|
+
*/
|
|
7516
|
+
received_value?: string | number | boolean;
|
|
7517
|
+
};
|
|
7518
|
+
message?: string;
|
|
7519
|
+
type?: string;
|
|
7520
|
+
};
|
|
7085
7521
|
/**
|
|
7086
7522
|
* Request body for submitting a ComfyUI workflow prompt for execution.
|
|
7087
7523
|
*/
|
|
@@ -7675,7 +8111,16 @@ export type SubscribeRequest = {
|
|
|
7675
8111
|
/**
|
|
7676
8112
|
* Stripe ConfirmationToken created from deferred Payment Element
|
|
7677
8113
|
* details. For an initial subscription, the backend creates the exact
|
|
7678
|
-
* invoice PaymentIntent and confirms it with this token.
|
|
8114
|
+
* invoice PaymentIntent and confirms it with this token. For a change
|
|
8115
|
+
* of an existing plan (upgrade, billing-cycle reset or scheduled
|
|
8116
|
+
* downgrade), the backend saves the card with a SetupIntent first; if
|
|
8117
|
+
* that needs 3-D Secure, the operation's payment_intent_client_secret
|
|
8118
|
+
* on /billing/ops/{id} carries the SetupIntent's client secret for
|
|
8119
|
+
* Stripe.js handleNextAction. An immediate upgrade then charges the
|
|
8120
|
+
* prorated amount to this card. On success the card becomes the
|
|
8121
|
+
* workspace default (Stripe customer default and the subscription's);
|
|
8122
|
+
* a declined or unauthenticated card changes no default. Requires
|
|
8123
|
+
* return_url. Mutually exclusive with saved_payment_method_id.
|
|
7679
8124
|
*
|
|
7680
8125
|
*/
|
|
7681
8126
|
confirmation_token?: string;
|
|
@@ -7726,9 +8171,15 @@ export type SubscribeRequest = {
|
|
|
7726
8171
|
*/
|
|
7727
8172
|
return_url?: string;
|
|
7728
8173
|
/**
|
|
7729
|
-
* Optional saved payment method selected for
|
|
7730
|
-
*
|
|
7731
|
-
*
|
|
8174
|
+
* Optional saved payment method selected at checkout, for a new
|
|
8175
|
+
* subscription or a change of an existing plan (upgrade, billing-cycle
|
|
8176
|
+
* reset or scheduled downgrade). It must be attached to the current
|
|
8177
|
+
* workspace's Stripe customer. An immediate upgrade charges the
|
|
8178
|
+
* prorated amount to this card; a scheduled downgrade charges nothing.
|
|
8179
|
+
* On success the card becomes the workspace default (Stripe customer
|
|
8180
|
+
* default and the subscription's); a declined charge changes no
|
|
8181
|
+
* default. Omitted, the plan change charges the current default as
|
|
8182
|
+
* before. Mutually exclusive with confirmation_token.
|
|
7732
8183
|
*
|
|
7733
8184
|
*/
|
|
7734
8185
|
saved_payment_method_id?: string;
|
|
@@ -8526,6 +8977,15 @@ export type ValidationResult = {
|
|
|
8526
8977
|
*/
|
|
8527
8978
|
warnings?: Array<ValidationError>;
|
|
8528
8979
|
};
|
|
8980
|
+
/**
|
|
8981
|
+
* The signed link `GET /api/view?redirect=false` answers with: the same link the 302 sends in `Location`, so it expires like that one.
|
|
8982
|
+
*/
|
|
8983
|
+
export type ViewFileUrlResponse = {
|
|
8984
|
+
/**
|
|
8985
|
+
* Signed Google Cloud Storage link to the file. It needs no other credential, so treat it as a secret until it expires.
|
|
8986
|
+
*/
|
|
8987
|
+
url: string;
|
|
8988
|
+
};
|
|
8529
8989
|
/**
|
|
8530
8990
|
* The live web session and the user it belongs to
|
|
8531
8991
|
*/
|
|
@@ -9053,7 +9513,15 @@ export type ListAssetsResponseWritable = {
|
|
|
9053
9513
|
*/
|
|
9054
9514
|
next_cursor?: string;
|
|
9055
9515
|
/**
|
|
9056
|
-
*
|
|
9516
|
+
* Number of assets matching the filters, counted up to 10,000 unless
|
|
9517
|
+
* the request sends `capped_total=false`. A capped 10,000 means "at
|
|
9518
|
+
* least 10,000" and must not be read as the exact count or used to
|
|
9519
|
+
* work out the last page. With `include_total=false` no count runs
|
|
9520
|
+
* and `total` is a lower bound: the assets through this page (on an
|
|
9521
|
+
* offset page, the skipped `offset` rows included), plus one when
|
|
9522
|
+
* `has_more` is true, and 0 for an empty page. To page, follow
|
|
9523
|
+
* `has_more` and `next_cursor`, which do not depend on the total.
|
|
9524
|
+
*
|
|
9057
9525
|
*/
|
|
9058
9526
|
total: number;
|
|
9059
9527
|
};
|
|
@@ -10272,7 +10740,9 @@ export type ListAssetsData = {
|
|
|
10272
10740
|
*/
|
|
10273
10741
|
limit?: number;
|
|
10274
10742
|
/**
|
|
10275
|
-
* Number of assets to skip for pagination
|
|
10743
|
+
* Number of assets to skip for pagination. A negative offset returns
|
|
10744
|
+
* 400 `INVALID_OFFSET`.
|
|
10745
|
+
*
|
|
10276
10746
|
*/
|
|
10277
10747
|
offset?: number;
|
|
10278
10748
|
/**
|
|
@@ -10321,6 +10791,28 @@ export type ListAssetsData = {
|
|
|
10321
10791
|
*
|
|
10322
10792
|
*/
|
|
10323
10793
|
after?: string;
|
|
10794
|
+
/**
|
|
10795
|
+
* When true or omitted, `total` counts at most 10,000 matching
|
|
10796
|
+
* assets, so a total of 10,000 means "at least 10,000", not an exact
|
|
10797
|
+
* count. A capped count stops after 10,000 matching assets instead
|
|
10798
|
+
* of reading every one. Send false for the exact count, for example
|
|
10799
|
+
* to work out the last page from the total: `has_more` and
|
|
10800
|
+
* `next_cursor` do not depend on the total either way. Ignored when
|
|
10801
|
+
* `include_total` is false.
|
|
10802
|
+
*
|
|
10803
|
+
*/
|
|
10804
|
+
capped_total?: boolean;
|
|
10805
|
+
/**
|
|
10806
|
+
* Send false when the caller does not read `total`, for example a
|
|
10807
|
+
* list that pages by `has_more` and `next_cursor`. No count runs,
|
|
10808
|
+
* `capped_total` is ignored, and `total` is a lower bound instead of
|
|
10809
|
+
* a count: the assets through this page (on an offset page, the
|
|
10810
|
+
* skipped `offset` rows included), plus one when `has_more` is true,
|
|
10811
|
+
* and 0 for an empty page. When true or omitted, `total` is counted
|
|
10812
|
+
* as `capped_total` says.
|
|
10813
|
+
*
|
|
10814
|
+
*/
|
|
10815
|
+
include_total?: boolean;
|
|
10324
10816
|
};
|
|
10325
10817
|
url: '/api/assets';
|
|
10326
10818
|
};
|
|
@@ -11583,7 +12075,7 @@ export type CreateBillingHandoffData = {
|
|
|
11583
12075
|
};
|
|
11584
12076
|
export type CreateBillingHandoffErrors = {
|
|
11585
12077
|
/**
|
|
11586
|
-
* `INVALID_REQUEST`
|
|
12078
|
+
* `INVALID_REQUEST`, or `workspace_id_invalid`: X-Comfy-Workspace-ID or ?workspace_id= names another workspace than the body
|
|
11587
12079
|
*/
|
|
11588
12080
|
400: ErrorResponse;
|
|
11589
12081
|
/**
|
|
@@ -11611,6 +12103,42 @@ export type CreateBillingHandoffResponses = {
|
|
|
11611
12103
|
201: BillingHandoffCreateResponse;
|
|
11612
12104
|
};
|
|
11613
12105
|
export type CreateBillingHandoffResponse = CreateBillingHandoffResponses[keyof CreateBillingHandoffResponses];
|
|
12106
|
+
export type CreateBillingHandoffCheckoutData = {
|
|
12107
|
+
body: BillingHandoffCheckoutRequest;
|
|
12108
|
+
path?: never;
|
|
12109
|
+
query?: never;
|
|
12110
|
+
url: '/api/auth/handoffs/checkout';
|
|
12111
|
+
};
|
|
12112
|
+
export type CreateBillingHandoffCheckoutErrors = {
|
|
12113
|
+
/**
|
|
12114
|
+
* `INVALID_REQUEST`: plan_slug is missing, or plan_slug or team_credit_stop_id is not 1 to 128 letters, digits, `_` or `-`
|
|
12115
|
+
*/
|
|
12116
|
+
400: ErrorResponse;
|
|
12117
|
+
/**
|
|
12118
|
+
* `INVALID_CREDENTIAL`: no scoped-session bearer, or the session or its source sign-in has ended
|
|
12119
|
+
*/
|
|
12120
|
+
401: ErrorResponse;
|
|
12121
|
+
/**
|
|
12122
|
+
* `CREDENTIAL_UNSUPPORTED`: the session is not a Platform billing tab's; `BILLING_FORBIDDEN`: the request did not come from the Platform origin, or the user no longer owns the workspace; `HANDOFF_DISABLED`, or another billing policy refusal
|
|
12123
|
+
*/
|
|
12124
|
+
403: ErrorResponse;
|
|
12125
|
+
/**
|
|
12126
|
+
* Too many handoffs for this sign-in, client address or user in the last hour
|
|
12127
|
+
*/
|
|
12128
|
+
429: ErrorResponse;
|
|
12129
|
+
/**
|
|
12130
|
+
* `SERVICE_UNAVAILABLE`: the billing policy could not be checked
|
|
12131
|
+
*/
|
|
12132
|
+
503: ErrorResponse;
|
|
12133
|
+
};
|
|
12134
|
+
export type CreateBillingHandoffCheckoutError = CreateBillingHandoffCheckoutErrors[keyof CreateBillingHandoffCheckoutErrors];
|
|
12135
|
+
export type CreateBillingHandoffCheckoutResponses = {
|
|
12136
|
+
/**
|
|
12137
|
+
* Handoff issued. `entry_url` is billing-web's handoff page with `intent=checkout`, `plan` and `team_credit_stop_id` (if any) in the query and the token in the fragment.
|
|
12138
|
+
*/
|
|
12139
|
+
201: BillingHandoffCreateResponse;
|
|
12140
|
+
};
|
|
12141
|
+
export type CreateBillingHandoffCheckoutResponse = CreateBillingHandoffCheckoutResponses[keyof CreateBillingHandoffCheckoutResponses];
|
|
11614
12142
|
export type ExchangeBillingHandoffData = {
|
|
11615
12143
|
body: BillingHandoffExchangeRequest;
|
|
11616
12144
|
path?: never;
|
|
@@ -12084,6 +12612,266 @@ export type GetBillingBalanceResponses = {
|
|
|
12084
12612
|
200: BillingBalanceResponse;
|
|
12085
12613
|
};
|
|
12086
12614
|
export type GetBillingBalanceResponse = GetBillingBalanceResponses[keyof GetBillingBalanceResponses];
|
|
12615
|
+
export type ListBillingBudgetsData = {
|
|
12616
|
+
body?: never;
|
|
12617
|
+
path?: never;
|
|
12618
|
+
query?: never;
|
|
12619
|
+
url: '/api/billing/budgets';
|
|
12620
|
+
};
|
|
12621
|
+
export type ListBillingBudgetsErrors = {
|
|
12622
|
+
/**
|
|
12623
|
+
* `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.
|
|
12624
|
+
*/
|
|
12625
|
+
400: ErrorResponse;
|
|
12626
|
+
/**
|
|
12627
|
+
* 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`.
|
|
12628
|
+
*/
|
|
12629
|
+
401: ErrorResponse;
|
|
12630
|
+
/**
|
|
12631
|
+
* 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.
|
|
12632
|
+
*/
|
|
12633
|
+
403: ForbiddenError;
|
|
12634
|
+
/**
|
|
12635
|
+
* Internal server error
|
|
12636
|
+
*/
|
|
12637
|
+
500: ErrorResponse;
|
|
12638
|
+
/**
|
|
12639
|
+
* `budgets_unavailable`: budgets are not available in this environment.
|
|
12640
|
+
*/
|
|
12641
|
+
503: ErrorResponse;
|
|
12642
|
+
};
|
|
12643
|
+
export type ListBillingBudgetsError = ListBillingBudgetsErrors[keyof ListBillingBudgetsErrors];
|
|
12644
|
+
export type ListBillingBudgetsResponses = {
|
|
12645
|
+
/**
|
|
12646
|
+
* Success
|
|
12647
|
+
*/
|
|
12648
|
+
200: BudgetList;
|
|
12649
|
+
};
|
|
12650
|
+
export type ListBillingBudgetsResponse = ListBillingBudgetsResponses[keyof ListBillingBudgetsResponses];
|
|
12651
|
+
export type CreateBillingBudgetData = {
|
|
12652
|
+
body: BudgetCreateRequest;
|
|
12653
|
+
path?: never;
|
|
12654
|
+
query?: never;
|
|
12655
|
+
url: '/api/billing/budgets';
|
|
12656
|
+
};
|
|
12657
|
+
export type CreateBillingBudgetErrors = {
|
|
12658
|
+
/**
|
|
12659
|
+
* `INVALID_REQUEST` (the body is not a JSON object), `invalid_budget`
|
|
12660
|
+
* (unknown `scope_kind` or `mode`, no `scope_id`, a limit that is not
|
|
12661
|
+
* positive, both or neither limit fields, bad `alert_percents`,
|
|
12662
|
+
* `until` without a future `ends_at`, or `ends_at` with another
|
|
12663
|
+
* `repeat`), or `workspace_id_invalid` (see SessionWorkspaceIDInvalid).
|
|
12664
|
+
*
|
|
12665
|
+
*/
|
|
12666
|
+
400: ErrorResponse;
|
|
12667
|
+
/**
|
|
12668
|
+
* 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`.
|
|
12669
|
+
*/
|
|
12670
|
+
401: ErrorResponse;
|
|
12671
|
+
/**
|
|
12672
|
+
* `not_workspace_owner` (the caller is a member, not an owner),
|
|
12673
|
+
* `plan_not_enterprise` (`mode: hard` on a plan without hard caps),
|
|
12674
|
+
* a plan refusal whose code is the `can_set_budgets` denial reason
|
|
12675
|
+
* (`creator_only_provisioning`, `no_subscription`, `free_plan`, `subscription_ended`,
|
|
12676
|
+
* `subscription_not_started`, `subscription_status_unrecognized`),
|
|
12677
|
+
* `WORKSPACE_BLOCKED`, `api_key_not_allowed` (the request was made
|
|
12678
|
+
* with an API key; budgets are changed from a signed-in session
|
|
12679
|
+
* only), `INSUFFICIENT_SCOPE` (an OAuth session without the billing
|
|
12680
|
+
* write scope; sent with a `WWW-Authenticate` insufficient_scope
|
|
12681
|
+
* challenge), `FORBIDDEN` (the caller is no longer
|
|
12682
|
+
* a member of the workspace, or a deployment budget was asked for
|
|
12683
|
+
* with a credential that cannot be used to check the deployment;
|
|
12684
|
+
* sign in again), or a session refusal (see SessionWriteForbidden).
|
|
12685
|
+
*
|
|
12686
|
+
*/
|
|
12687
|
+
403: ForbiddenError;
|
|
12688
|
+
/**
|
|
12689
|
+
* `scope_not_found`: the member, API key or deployment is not in
|
|
12690
|
+
* this workspace. A deployment id must be the canonical lower-case
|
|
12691
|
+
* `dep-<uuid>` form.
|
|
12692
|
+
*
|
|
12693
|
+
*/
|
|
12694
|
+
404: ErrorResponse;
|
|
12695
|
+
/**
|
|
12696
|
+
* `budget_exists` (the scope already has a live budget) or
|
|
12697
|
+
* `no_billing_period` (`repeat: current_period` on a workspace with
|
|
12698
|
+
* no open paid subscription term).
|
|
12699
|
+
*
|
|
12700
|
+
*/
|
|
12701
|
+
409: ErrorResponse;
|
|
12702
|
+
/**
|
|
12703
|
+
* Internal server error
|
|
12704
|
+
*/
|
|
12705
|
+
500: ErrorResponse;
|
|
12706
|
+
/**
|
|
12707
|
+
* `budgets_unavailable` (budgets are not available in this
|
|
12708
|
+
* environment) or `deployment_check_unavailable` (the deployment
|
|
12709
|
+
* service could not be asked about a deployment scope; retry).
|
|
12710
|
+
*
|
|
12711
|
+
*/
|
|
12712
|
+
503: ErrorResponse;
|
|
12713
|
+
};
|
|
12714
|
+
export type CreateBillingBudgetError = CreateBillingBudgetErrors[keyof CreateBillingBudgetErrors];
|
|
12715
|
+
export type CreateBillingBudgetResponses = {
|
|
12716
|
+
/**
|
|
12717
|
+
* The new budget
|
|
12718
|
+
*/
|
|
12719
|
+
201: BudgetWriteResult;
|
|
12720
|
+
};
|
|
12721
|
+
export type CreateBillingBudgetResponse = CreateBillingBudgetResponses[keyof CreateBillingBudgetResponses];
|
|
12722
|
+
export type DeleteBillingBudgetData = {
|
|
12723
|
+
body?: never;
|
|
12724
|
+
path: {
|
|
12725
|
+
/**
|
|
12726
|
+
* Budget id (`bud_…`).
|
|
12727
|
+
*/
|
|
12728
|
+
id: string;
|
|
12729
|
+
};
|
|
12730
|
+
query?: never;
|
|
12731
|
+
url: '/api/billing/budgets/{id}';
|
|
12732
|
+
};
|
|
12733
|
+
export type DeleteBillingBudgetErrors = {
|
|
12734
|
+
/**
|
|
12735
|
+
* `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.
|
|
12736
|
+
*/
|
|
12737
|
+
400: ErrorResponse;
|
|
12738
|
+
/**
|
|
12739
|
+
* 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`.
|
|
12740
|
+
*/
|
|
12741
|
+
401: ErrorResponse;
|
|
12742
|
+
/**
|
|
12743
|
+
* `not_workspace_owner`, `api_key_not_allowed` (the request was made with an API key), `INSUFFICIENT_SCOPE`, `FORBIDDEN` (the caller is no longer a member of the workspace), or a session refusal (see SessionWriteForbidden).
|
|
12744
|
+
*/
|
|
12745
|
+
403: ForbiddenError;
|
|
12746
|
+
/**
|
|
12747
|
+
* `budget_not_found`: unknown or already archived budget id.
|
|
12748
|
+
*/
|
|
12749
|
+
404: ErrorResponse;
|
|
12750
|
+
/**
|
|
12751
|
+
* Internal server error
|
|
12752
|
+
*/
|
|
12753
|
+
500: ErrorResponse;
|
|
12754
|
+
/**
|
|
12755
|
+
* `budgets_unavailable`: budgets are not available in this environment.
|
|
12756
|
+
*/
|
|
12757
|
+
503: ErrorResponse;
|
|
12758
|
+
};
|
|
12759
|
+
export type DeleteBillingBudgetError = DeleteBillingBudgetErrors[keyof DeleteBillingBudgetErrors];
|
|
12760
|
+
export type DeleteBillingBudgetResponses = {
|
|
12761
|
+
/**
|
|
12762
|
+
* Archived
|
|
12763
|
+
*/
|
|
12764
|
+
204: void;
|
|
12765
|
+
};
|
|
12766
|
+
export type DeleteBillingBudgetResponse = DeleteBillingBudgetResponses[keyof DeleteBillingBudgetResponses];
|
|
12767
|
+
export type UpdateBillingBudgetData = {
|
|
12768
|
+
body: BudgetUpdateRequest;
|
|
12769
|
+
path: {
|
|
12770
|
+
/**
|
|
12771
|
+
* Budget id (`bud_…`).
|
|
12772
|
+
*/
|
|
12773
|
+
id: string;
|
|
12774
|
+
};
|
|
12775
|
+
query?: never;
|
|
12776
|
+
url: '/api/billing/budgets/{id}';
|
|
12777
|
+
};
|
|
12778
|
+
export type UpdateBillingBudgetErrors = {
|
|
12779
|
+
/**
|
|
12780
|
+
* `INVALID_REQUEST` (the body is not a JSON object), `invalid_budget`
|
|
12781
|
+
* (as on create), or `workspace_id_invalid` (see
|
|
12782
|
+
* SessionWorkspaceIDInvalid).
|
|
12783
|
+
*
|
|
12784
|
+
*/
|
|
12785
|
+
400: ErrorResponse;
|
|
12786
|
+
/**
|
|
12787
|
+
* 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`.
|
|
12788
|
+
*/
|
|
12789
|
+
401: ErrorResponse;
|
|
12790
|
+
/**
|
|
12791
|
+
* `not_workspace_owner`, `plan_not_enterprise` (changing a soft
|
|
12792
|
+
* budget to hard on a plan without hard caps), a plan refusal whose
|
|
12793
|
+
* code is the `can_set_budgets` denial reason
|
|
12794
|
+
* (`creator_only_provisioning`, `no_subscription`,
|
|
12795
|
+
* `free_plan`, `subscription_ended`, `subscription_not_started`,
|
|
12796
|
+
* `subscription_status_unrecognized`), `WORKSPACE_BLOCKED`,
|
|
12797
|
+
* `api_key_not_allowed` (the request was made with an API key),
|
|
12798
|
+
* `INSUFFICIENT_SCOPE` (sent with a `WWW-Authenticate`
|
|
12799
|
+
* insufficient_scope challenge), `FORBIDDEN` (the caller is no
|
|
12800
|
+
* longer a member of the workspace), or a session refusal (see
|
|
12801
|
+
* SessionWriteForbidden).
|
|
12802
|
+
*
|
|
12803
|
+
*/
|
|
12804
|
+
403: ForbiddenError;
|
|
12805
|
+
/**
|
|
12806
|
+
* `budget_not_found`: unknown or archived budget id.
|
|
12807
|
+
*/
|
|
12808
|
+
404: ErrorResponse;
|
|
12809
|
+
/**
|
|
12810
|
+
* `no_billing_period`: `repeat: current_period` on a workspace with no open paid subscription term.
|
|
12811
|
+
*/
|
|
12812
|
+
409: ErrorResponse;
|
|
12813
|
+
/**
|
|
12814
|
+
* Internal server error
|
|
12815
|
+
*/
|
|
12816
|
+
500: ErrorResponse;
|
|
12817
|
+
/**
|
|
12818
|
+
* `budgets_unavailable`: budgets are not available in this environment.
|
|
12819
|
+
*/
|
|
12820
|
+
503: ErrorResponse;
|
|
12821
|
+
};
|
|
12822
|
+
export type UpdateBillingBudgetError = UpdateBillingBudgetErrors[keyof UpdateBillingBudgetErrors];
|
|
12823
|
+
export type UpdateBillingBudgetResponses = {
|
|
12824
|
+
/**
|
|
12825
|
+
* The budget after the change
|
|
12826
|
+
*/
|
|
12827
|
+
200: BudgetWriteResult;
|
|
12828
|
+
};
|
|
12829
|
+
export type UpdateBillingBudgetResponse = UpdateBillingBudgetResponses[keyof UpdateBillingBudgetResponses];
|
|
12830
|
+
export type GetBillingBudgetHistoryData = {
|
|
12831
|
+
body?: never;
|
|
12832
|
+
path: {
|
|
12833
|
+
/**
|
|
12834
|
+
* Budget id (`bud_…`).
|
|
12835
|
+
*/
|
|
12836
|
+
id: string;
|
|
12837
|
+
};
|
|
12838
|
+
query?: never;
|
|
12839
|
+
url: '/api/billing/budgets/{id}/history';
|
|
12840
|
+
};
|
|
12841
|
+
export type GetBillingBudgetHistoryErrors = {
|
|
12842
|
+
/**
|
|
12843
|
+
* `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.
|
|
12844
|
+
*/
|
|
12845
|
+
400: ErrorResponse;
|
|
12846
|
+
/**
|
|
12847
|
+
* 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`.
|
|
12848
|
+
*/
|
|
12849
|
+
401: ErrorResponse;
|
|
12850
|
+
/**
|
|
12851
|
+
* `not_workspace_owner`, `FORBIDDEN` (the caller is no longer a member of the workspace), or a session refusal (see SessionForbidden).
|
|
12852
|
+
*/
|
|
12853
|
+
403: ForbiddenError;
|
|
12854
|
+
/**
|
|
12855
|
+
* `budget_not_found`: unknown or archived budget id.
|
|
12856
|
+
*/
|
|
12857
|
+
404: ErrorResponse;
|
|
12858
|
+
/**
|
|
12859
|
+
* Internal server error
|
|
12860
|
+
*/
|
|
12861
|
+
500: ErrorResponse;
|
|
12862
|
+
/**
|
|
12863
|
+
* `budgets_unavailable`: budgets are not available in this environment.
|
|
12864
|
+
*/
|
|
12865
|
+
503: ErrorResponse;
|
|
12866
|
+
};
|
|
12867
|
+
export type GetBillingBudgetHistoryError = GetBillingBudgetHistoryErrors[keyof GetBillingBudgetHistoryErrors];
|
|
12868
|
+
export type GetBillingBudgetHistoryResponses = {
|
|
12869
|
+
/**
|
|
12870
|
+
* Success
|
|
12871
|
+
*/
|
|
12872
|
+
200: BudgetHistory;
|
|
12873
|
+
};
|
|
12874
|
+
export type GetBillingBudgetHistoryResponse = GetBillingBudgetHistoryResponses[keyof GetBillingBudgetHistoryResponses];
|
|
12087
12875
|
export type GetBillingCapabilitiesData = {
|
|
12088
12876
|
body?: never;
|
|
12089
12877
|
path?: never;
|
|
@@ -12379,6 +13167,47 @@ export type CancelBillingOpResponses = {
|
|
|
12379
13167
|
202: BillingOpCancelResponse;
|
|
12380
13168
|
};
|
|
12381
13169
|
export type CancelBillingOpResponse = CancelBillingOpResponses[keyof CancelBillingOpResponses];
|
|
13170
|
+
export type GetBillingOpOutcomeData = {
|
|
13171
|
+
body?: never;
|
|
13172
|
+
path: {
|
|
13173
|
+
/**
|
|
13174
|
+
* The billing operation ID
|
|
13175
|
+
*/
|
|
13176
|
+
id: string;
|
|
13177
|
+
};
|
|
13178
|
+
query?: never;
|
|
13179
|
+
url: '/api/billing/ops/{id}/outcome';
|
|
13180
|
+
};
|
|
13181
|
+
export type GetBillingOpOutcomeErrors = {
|
|
13182
|
+
/**
|
|
13183
|
+
* `INVALID_CREDENTIAL`: no scoped-session bearer, or the session is unknown, revoked or expired 30 minutes ago or more
|
|
13184
|
+
*/
|
|
13185
|
+
401: ErrorResponse;
|
|
13186
|
+
/**
|
|
13187
|
+
* `HANDOFF_DISABLED`, `BILLING_FORBIDDEN` or another billing policy refusal
|
|
13188
|
+
*/
|
|
13189
|
+
403: ErrorResponse;
|
|
13190
|
+
/**
|
|
13191
|
+
* Billing operation not found in the session's workspace
|
|
13192
|
+
*/
|
|
13193
|
+
404: ErrorResponse;
|
|
13194
|
+
/**
|
|
13195
|
+
* Internal server error
|
|
13196
|
+
*/
|
|
13197
|
+
500: ErrorResponse;
|
|
13198
|
+
/**
|
|
13199
|
+
* `SERVICE_UNAVAILABLE`: the session or billing policy check could not be made
|
|
13200
|
+
*/
|
|
13201
|
+
503: ErrorResponse;
|
|
13202
|
+
};
|
|
13203
|
+
export type GetBillingOpOutcomeError = GetBillingOpOutcomeErrors[keyof GetBillingOpOutcomeErrors];
|
|
13204
|
+
export type GetBillingOpOutcomeResponses = {
|
|
13205
|
+
/**
|
|
13206
|
+
* Billing operation outcome
|
|
13207
|
+
*/
|
|
13208
|
+
200: BillingOpOutcomeResponse;
|
|
13209
|
+
};
|
|
13210
|
+
export type GetBillingOpOutcomeResponse = GetBillingOpOutcomeResponses[keyof GetBillingOpOutcomeResponses];
|
|
12382
13211
|
export type ListSavedPaymentMethodsData = {
|
|
12383
13212
|
body?: never;
|
|
12384
13213
|
path?: never;
|
|
@@ -13609,9 +14438,13 @@ export type GetFeaturesResponses = {
|
|
|
13609
14438
|
*/
|
|
13610
14439
|
new_free_tier_subscriptions?: boolean;
|
|
13611
14440
|
/**
|
|
13612
|
-
* Whether the frontend should
|
|
14441
|
+
* Whether the frontend should offer Open on Cloud. Requires a signed-in session with a verified email and a matching PostHog rollout. Defaults to false when evaluation is unavailable. Workflow access and execution still require their existing permissions.
|
|
13613
14442
|
*/
|
|
13614
14443
|
open_on_cloud_enabled?: boolean;
|
|
14444
|
+
/**
|
|
14445
|
+
* Whether the frontend should offer the local agent option in Open on Cloud. Requires a verified comfy.org session and a matching PostHog rollout. Defaults to false.
|
|
14446
|
+
*/
|
|
14447
|
+
open_on_cloud_use_local_agent_enabled?: boolean;
|
|
13615
14448
|
/**
|
|
13616
14449
|
* 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.
|
|
13617
14450
|
*/
|
|
@@ -14772,6 +15605,20 @@ export type ListJobsData = {
|
|
|
14772
15605
|
* Maximum items per page (1-1000)
|
|
14773
15606
|
*/
|
|
14774
15607
|
limit?: number;
|
|
15608
|
+
/**
|
|
15609
|
+
* When true or omitted, `pagination.total` counts at most 10,000
|
|
15610
|
+
* matching jobs, so a total of 10,000 means "at least 10,000", not an
|
|
15611
|
+
* exact count. A capped count stops after 10,000 matching jobs
|
|
15612
|
+
* instead of reading every one. Send false for the exact count, for
|
|
15613
|
+
* example to work out the last page from the total: `has_more` and
|
|
15614
|
+
* `next_cursor` do not depend on the total either way. Under the
|
|
15615
|
+
* default `sort_by=create_time` a request with `after` reports no
|
|
15616
|
+
* total, so this changes nothing there; under
|
|
15617
|
+
* `sort_by=execution_time` `after` is ignored and the total is
|
|
15618
|
+
* counted, capped unless this is false.
|
|
15619
|
+
*
|
|
15620
|
+
*/
|
|
15621
|
+
capped_total?: boolean;
|
|
14775
15622
|
};
|
|
14776
15623
|
url: '/api/jobs';
|
|
14777
15624
|
};
|
|
@@ -15172,7 +16019,7 @@ export type ExecutePromptErrors = {
|
|
|
15172
16019
|
*/
|
|
15173
16020
|
401: ErrorResponse;
|
|
15174
16021
|
/**
|
|
15175
|
-
* 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`.
|
|
16022
|
+
* 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.
|
|
15176
16023
|
*/
|
|
15177
16024
|
402: PromptErrorResponse;
|
|
15178
16025
|
/**
|
|
@@ -16621,14 +17468,27 @@ export type GetCatalogAgentInstructionsData = {
|
|
|
16621
17468
|
url: '/api/v1/catalog/agents';
|
|
16622
17469
|
};
|
|
16623
17470
|
export type GetCatalogAgentInstructionsErrors = {
|
|
17471
|
+
/**
|
|
17472
|
+
* `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.
|
|
17473
|
+
*/
|
|
17474
|
+
400: ErrorResponse;
|
|
17475
|
+
/**
|
|
17476
|
+
* 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`.
|
|
17477
|
+
*/
|
|
17478
|
+
401: ErrorResponse;
|
|
17479
|
+
/**
|
|
17480
|
+
* 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.
|
|
17481
|
+
*/
|
|
17482
|
+
403: ForbiddenError;
|
|
16624
17483
|
/**
|
|
16625
17484
|
* Catalog disabled or unavailable
|
|
16626
17485
|
*/
|
|
16627
17486
|
503: unknown;
|
|
16628
17487
|
};
|
|
17488
|
+
export type GetCatalogAgentInstructionsError = GetCatalogAgentInstructionsErrors[keyof GetCatalogAgentInstructionsErrors];
|
|
16629
17489
|
export type GetCatalogAgentInstructionsResponses = {
|
|
16630
17490
|
/**
|
|
16631
|
-
* Editing instructions from this deployed catalog API build
|
|
17491
|
+
* Editing instructions from this deployed catalog API build; private no-store
|
|
16632
17492
|
*/
|
|
16633
17493
|
200: string;
|
|
16634
17494
|
};
|
|
@@ -16680,7 +17540,10 @@ export type ListCccWebsiteCardsData = {
|
|
|
16680
17540
|
cursor?: string;
|
|
16681
17541
|
locale?: 'en' | 'zh-CN' | 'ja';
|
|
16682
17542
|
q?: string;
|
|
16683
|
-
|
|
17543
|
+
/**
|
|
17544
|
+
* newest orders by the time each page first went live on the Hub, newest first, then title and uid; pages with no recorded time come last.
|
|
17545
|
+
*/
|
|
17546
|
+
sort?: 'popular' | 'name' | 'newest' | 'priceAsc' | 'priceDesc';
|
|
16684
17547
|
category?: Array<string>;
|
|
16685
17548
|
model?: Array<string>;
|
|
16686
17549
|
use?: Array<string>;
|
|
@@ -16774,25 +17637,6 @@ export type GetCccCreatorResponses = {
|
|
|
16774
17637
|
200: CccCreatorProfile;
|
|
16775
17638
|
};
|
|
16776
17639
|
export type GetCccCreatorResponse = GetCccCreatorResponses[keyof GetCccCreatorResponses];
|
|
16777
|
-
export type GetCatalogDocsData = {
|
|
16778
|
-
body?: never;
|
|
16779
|
-
path?: never;
|
|
16780
|
-
query?: never;
|
|
16781
|
-
url: '/api/v1/catalog/docs';
|
|
16782
|
-
};
|
|
16783
|
-
export type GetCatalogDocsErrors = {
|
|
16784
|
-
/**
|
|
16785
|
-
* Catalog disabled or unavailable
|
|
16786
|
-
*/
|
|
16787
|
-
503: unknown;
|
|
16788
|
-
};
|
|
16789
|
-
export type GetCatalogDocsResponses = {
|
|
16790
|
-
/**
|
|
16791
|
-
* Build-coupled catalog instructions, permissions and endpoint contracts
|
|
16792
|
-
*/
|
|
16793
|
-
200: string;
|
|
16794
|
-
};
|
|
16795
|
-
export type GetCatalogDocsResponse = GetCatalogDocsResponses[keyof GetCatalogDocsResponses];
|
|
16796
17640
|
export type BatchCccItemsData = {
|
|
16797
17641
|
body: {
|
|
16798
17642
|
expected_draft_rev: number;
|
|
@@ -17820,14 +18664,27 @@ export type GetCatalogOpenApiData = {
|
|
|
17820
18664
|
url: '/api/v1/catalog/openapi.json';
|
|
17821
18665
|
};
|
|
17822
18666
|
export type GetCatalogOpenApiErrors = {
|
|
18667
|
+
/**
|
|
18668
|
+
* `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.
|
|
18669
|
+
*/
|
|
18670
|
+
400: ErrorResponse;
|
|
18671
|
+
/**
|
|
18672
|
+
* 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`.
|
|
18673
|
+
*/
|
|
18674
|
+
401: ErrorResponse;
|
|
18675
|
+
/**
|
|
18676
|
+
* 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.
|
|
18677
|
+
*/
|
|
18678
|
+
403: ForbiddenError;
|
|
17823
18679
|
/**
|
|
17824
18680
|
* Catalog disabled or unavailable
|
|
17825
18681
|
*/
|
|
17826
18682
|
503: unknown;
|
|
17827
18683
|
};
|
|
18684
|
+
export type GetCatalogOpenApiError = GetCatalogOpenApiErrors[keyof GetCatalogOpenApiErrors];
|
|
17828
18685
|
export type GetCatalogOpenApiResponses = {
|
|
17829
18686
|
/**
|
|
17830
|
-
* Catalog OpenAPI with contract fingerprint and environment
|
|
18687
|
+
* Catalog OpenAPI with contract fingerprint and environment; private no-store
|
|
17831
18688
|
*/
|
|
17832
18689
|
200: Cccjson;
|
|
17833
18690
|
};
|
|
@@ -18623,6 +19480,18 @@ export type ViewFileData = {
|
|
|
18623
19480
|
*
|
|
18624
19481
|
*/
|
|
18625
19482
|
res?: number;
|
|
19483
|
+
/**
|
|
19484
|
+
* `false` answers `200` with the signed link as JSON
|
|
19485
|
+
* (`ViewFileURLResponse`) instead of the `302` to it, after the same
|
|
19486
|
+
* sign-in, workspace and visibility checks. For a page on another
|
|
19487
|
+
* site that reads the file with `fetch`: a page cannot read a 302's
|
|
19488
|
+
* `Location`, and the browser sends `Origin: null` to storage after
|
|
19489
|
+
* following the redirect across sites, which storage refuses. Any
|
|
19490
|
+
* other value, or none, answers the `302`. `channel`, and `res` on
|
|
19491
|
+
* a raster image, answer with the image bytes either way.
|
|
19492
|
+
*
|
|
19493
|
+
*/
|
|
19494
|
+
redirect?: string;
|
|
18626
19495
|
/**
|
|
18627
19496
|
* The workspace a media request reads from, where a media tag cannot send `X-Comfy-Workspace-ID`; see the `MediaWorkspaceID` parameter.
|
|
18628
19497
|
*/
|
|
@@ -18655,9 +19524,9 @@ export type ViewFileErrors = {
|
|
|
18655
19524
|
export type ViewFileError = ViewFileErrors[keyof ViewFileErrors];
|
|
18656
19525
|
export type ViewFileResponses = {
|
|
18657
19526
|
/**
|
|
18658
|
-
*
|
|
19527
|
+
* Success - File content returned (used when channel or res parameter is present), or, with `redirect=false`, the signed link as JSON with `Cache-Control: no-store`.
|
|
18659
19528
|
*/
|
|
18660
|
-
200:
|
|
19529
|
+
200: ViewFileUrlResponse;
|
|
18661
19530
|
};
|
|
18662
19531
|
export type ViewFileResponse = ViewFileResponses[keyof ViewFileResponses];
|
|
18663
19532
|
export type GetLegacyViewMetadataData = {
|
|
@@ -20657,6 +21526,10 @@ export type GetOAuthAuthorizeErrors = {
|
|
|
20657
21526
|
* Invalid authorize request (pre-redirect failure — unknown client, redirect mismatch, malformed params). Content-negotiated; browser navigations (Accept includes text/html without application/json) receive a self-contained HTML error page instead of JSON. Or, always as JSON, `code` `workspace_id_invalid` (see SessionWorkspaceIDInvalid) for a token or API key whose workspace selector is malformed or names another workspace than its own, while `web_session_enabled` is on for its user.
|
|
20658
21527
|
*/
|
|
20659
21528
|
400: ErrorResponse;
|
|
21529
|
+
/**
|
|
21530
|
+
* `code` `login_required`: a resume request (`oauth_request_id` present) that is not a browser top-level navigation (Accept does not prefer text/html, as with the consent page's fetch) and has no signed-in session, or one whose email is unverified while email verification is on. The request stays open, so the client sends the user to sign in and resumes it. A browser navigation in the same state gets the 302 to login instead.
|
|
21531
|
+
*/
|
|
21532
|
+
401: ErrorResponse;
|
|
20660
21533
|
/**
|
|
20661
21534
|
* OAuth disabled
|
|
20662
21535
|
*/
|