@leaflow/sdk 0.103.0 → 0.104.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1737,6 +1737,8 @@ export interface components {
1737
1737
  CreditGroup: {
1738
1738
  /** @description What the credit in this group may pay for. No restrictions means anything on the account. */
1739
1739
  applies_to: components["schemas"]["Applicability"];
1740
+ /** @description Restricted to your first purchase of anything it applies to. */
1741
+ first_purchase_only?: boolean;
1740
1742
  amount: components["schemas"]["Money"];
1741
1743
  };
1742
1744
  ProjectBillingInfo: {
@@ -2300,6 +2302,8 @@ export interface components {
2300
2302
  currency: string;
2301
2303
  /** @description What this credit may pay for. No restrictions means anything on the account. */
2302
2304
  applies_to: components["schemas"]["Applicability"];
2305
+ /** @description Restricted to your first purchase of anything it applies to. */
2306
+ first_purchase_only?: boolean;
2303
2307
  /** @enum {string} */
2304
2308
  status: "active" | "depleted" | "expired" | "voided";
2305
2309
  /** Format: date-time */
@@ -2821,6 +2825,8 @@ export interface components {
2821
2825
  * including setup fees and traffic.
2822
2826
  */
2823
2827
  applies_to: components["schemas"]["Applicability"];
2828
+ /** @description Restricted to your first purchase of anything it applies to. */
2829
+ first_purchase_only?: boolean;
2824
2830
  /** Format: date-time */
2825
2831
  started_at?: string;
2826
2832
  /** Format: date-time */
@@ -2847,19 +2853,20 @@ export interface components {
2847
2853
  /** @description How many periods one purchase covers. */
2848
2854
  interval_count?: number;
2849
2855
  unit_amount?: components["schemas"]["Money"];
2856
+ /** @description False once the price is archived. It still applies to purchases already made at this price. */
2857
+ active: boolean;
2850
2858
  };
2851
2859
  /**
2852
- * @description Product, plan and price lists form a union; three empty lists permit every item.
2853
- * Other conditions apply together. Entries always include their display fields.
2860
+ * @description Anything not excluded that matches an inclusion, or anything not excluded when no inclusion is
2861
+ * given, subject to the billing type, operation and term conditions. Entries always include their
2862
+ * display fields; archived plans and prices stay listed with active set to false.
2854
2863
  */
2855
2864
  Applicability: {
2856
2865
  products?: components["schemas"]["Product"][];
2857
- plans?: components["schemas"]["ObjectIdentity"][];
2866
+ plans?: components["schemas"]["ApplicablePlan"][];
2858
2867
  prices?: components["schemas"]["PriceOption"][];
2859
2868
  price_types?: string[];
2860
2869
  operations?: components["schemas"]["PurchaseOperation"][];
2861
- /** @description Restricted to your first purchase of a covered product. */
2862
- first_purchase_only?: boolean;
2863
2870
  /**
2864
2871
  * @description The shortest term a purchase may have, in months. A purchase with no term, such as
2865
2872
  * metered usage, never qualifies while this is set.
@@ -2867,6 +2874,16 @@ export interface components {
2867
2874
  min_term_months?: number;
2868
2875
  /** @description The longest term a purchase may have, in months. */
2869
2876
  max_term_months?: number;
2877
+ excluded_products?: components["schemas"]["Product"][];
2878
+ excluded_plans?: components["schemas"]["ApplicablePlan"][];
2879
+ excluded_prices?: components["schemas"]["PriceOption"][];
2880
+ };
2881
+ /** @description A plan it refers to. active is false once the plan is archived; it still applies to subscriptions already on this plan. */
2882
+ ApplicablePlan: {
2883
+ /** Format: uuid */
2884
+ id: string;
2885
+ name: string;
2886
+ active: boolean;
2870
2887
  };
2871
2888
  /**
2872
2889
  * @description Frozen purchase terms. Monetary fields come from related invoice-line snapshots and are absent
@@ -503,7 +503,7 @@ export interface paths {
503
503
  * Release a floating IP
504
504
  * @description Releases the floating IP after unbinding it. The floating IP shows the `delete` operation until it is released.
505
505
  *
506
- * Refused with `COMPUTE_RESOURCE_SUBSCRIBED` while a subscription pays for the address or for its bandwidth, including a pay-as-you-go subscription. `meta.resource_id` names the floating IP. It is released by canceling the subscriptions listed in `meta.subscription_ids` through Billing, the same set as its `release_subscription_ids`.
506
+ * Refused with `COMPUTE_RESOURCE_SUBSCRIBED` while a subscription pays for the address, including a pay-as-you-go subscription. `meta.resource_id` names the floating IP. It is released by canceling the subscriptions listed in `meta.subscription_ids` through Billing, the same set as its `release_subscription_ids`.
507
507
  */
508
508
  delete: operations["release-floating-ip"];
509
509
  options?: never;
@@ -1794,10 +1794,10 @@ export interface components {
1794
1794
  */
1795
1795
  source_disk_id: string;
1796
1796
  /**
1797
- * @description `provisioning` while the backup is taken, then `available`. `failed` means the backup was not created.
1797
+ * @description `provisioning` while the backup is taken, then `available`. `failed` means the backup was not created. `missing` means the backup no longer exists in the cloud.
1798
1798
  * @enum {string}
1799
1799
  */
1800
- status: "provisioning" | "available" | "deleted" | "failed" | "error";
1800
+ status: "provisioning" | "available" | "deleted" | "failed" | "error" | "missing";
1801
1801
  /** @description The operation in progress on this backup, or null when none is. */
1802
1802
  readonly operation: components["schemas"]["BackupOperation"] | null;
1803
1803
  /** Format: int64 */
@@ -1869,10 +1869,10 @@ export interface components {
1869
1869
  */
1870
1870
  throughput_bytes_per_sec: number | null;
1871
1871
  /**
1872
- * @description `pending` until the order is accepted, with no storage allocated; `provisioning` while the disk is created; then `available`, or `in_use` once attached. `failed` means the disk was not created; `failure_reason` states why.
1872
+ * @description `pending` until the order is accepted, with no storage allocated; `provisioning` while the disk is created; then `available`, or `in_use` once attached. `failed` means the disk was not created; `failure_reason` states why. `missing` means the disk no longer exists in the cloud.
1873
1873
  * @enum {string}
1874
1874
  */
1875
- status: "pending" | "provisioning" | "available" | "in_use" | "deleted" | "failed" | "error";
1875
+ status: "pending" | "provisioning" | "available" | "in_use" | "deleted" | "failed" | "error" | "missing";
1876
1876
  /** Format: uuid */
1877
1877
  order_id: string | null;
1878
1878
  /**
@@ -1989,10 +1989,10 @@ export interface components {
1989
1989
  /** @description False means a new password can only be set by rebuilding an instance created from this image */
1990
1990
  supports_password_reset: boolean;
1991
1991
  /**
1992
- * @description Only `available` images can install instances. A public image is always `available`; a private image is `pending` until its order is accepted, then goes through `provisioning` and `uploading` while it is captured. `failed` means the capture produced no image; `failure_reason` states why.
1992
+ * @description Only `available` images can install instances. A public image is always `available`; a private image is `pending` until its order is accepted, then goes through `provisioning` and `uploading` while it is captured. `failed` means the capture produced no image; `failure_reason` states why. `missing` means a private image no longer exists in the cloud.
1993
1993
  * @enum {string}
1994
1994
  */
1995
- status: "pending" | "provisioning" | "uploading" | "available" | "deleted" | "failed" | "error";
1995
+ status: "pending" | "provisioning" | "uploading" | "available" | "deleted" | "failed" | "error" | "missing";
1996
1996
  /** @description Details of why the capture failed; non-empty only when `status` is `failed` */
1997
1997
  failure: string | null;
1998
1998
  /**
@@ -2162,8 +2162,8 @@ export interface components {
2162
2162
  };
2163
2163
  /**
2164
2164
  * @description One purchased public IP resource, including its bandwidth configuration. Bandwidth has no
2165
- * separate Compute resource ID. Billing may split fees internally; read the order for the
2166
- * commercial breakdown. Changing bandwidth updates this same resource, not another allocation.
2165
+ * separate Compute resource ID; one subscription pays for the address and its bandwidth.
2166
+ * Changing bandwidth updates this same resource, not another allocation.
2167
2167
  */
2168
2168
  FloatingIPResource: {
2169
2169
  /** @description The allocated public address. Null until the address is allocated. */
@@ -2177,10 +2177,10 @@ export interface components {
2177
2177
  /** Format: uuid */
2178
2178
  region_id: string;
2179
2179
  /**
2180
- * @description `pending` until the order is accepted, with no address allocated; `provisioning` while the address is allocated; then `available`. `failed` means no address was allocated; `failure_reason` states why.
2180
+ * @description `pending` until the order is accepted, with no address allocated; `provisioning` while the address is allocated; then `available`. `failed` means no address was allocated; `failure_reason` states why. `missing` means the address no longer exists in the cloud.
2181
2181
  * @enum {string}
2182
2182
  */
2183
- status: "pending" | "provisioning" | "available" | "deleted" | "failed" | "error" | "unknown";
2183
+ status: "pending" | "provisioning" | "available" | "deleted" | "failed" | "error" | "unknown" | "missing";
2184
2184
  /** Format: uuid */
2185
2185
  order_id: string | null;
2186
2186
  /**
@@ -2194,7 +2194,7 @@ export interface components {
2194
2194
  * presence does not imply delivery or metering. Null when no subscription is associated.
2195
2195
  */
2196
2196
  subscription_id: string | null;
2197
- /** @description The complete subscription set a cancellation through Billing has to cover to release this floating IP, including any internal fee components. Subscriptions that have ended are not listed, and the list is empty when no subscription pays for any of them. */
2197
+ /** @description The subscription a cancellation through Billing has to cover to release this floating IP. A subscription that has ended is not listed, and the list is empty when no subscription pays for the floating IP. */
2198
2198
  release_subscription_ids: string[];
2199
2199
  /** @description The subscriptions of `release_subscription_ids`, in the same order, each with the resource it pays for, so that each line of a cancellation can name what it releases. */
2200
2200
  release_set: components["schemas"]["ReleaseSetItem"][];
@@ -2300,16 +2300,14 @@ export interface components {
2300
2300
  /** Format: uuid */
2301
2301
  region_id: string;
2302
2302
  /**
2303
- * @description `pending` until the order is accepted: no virtual machine exists and addresses are null. `provisioning` while the instance is created, then `active`. `failed` means the instance was not created; `failure_reason` states why. The other values are the state last observed in the cloud; an operation in progress appears in `operation`, not here.
2303
+ * @description `pending` until the order is accepted: no virtual machine exists and addresses are null. `provisioning` while the instance is created, then `active`. `failed` means the instance was not created; `failure_reason` states why. `missing` means the virtual machine no longer exists in the cloud. The other values are the state last observed in the cloud; an operation in progress appears in `operation`, not here.
2304
2304
  * @enum {string}
2305
2305
  */
2306
- status: "pending" | "provisioning" | "active" | "stopped" | "paused" | "suspended" | "shelved" | "shelved_offloaded" | "rescued" | "deleted" | "failed" | "error" | "unknown";
2306
+ status: "pending" | "provisioning" | "active" | "stopped" | "paused" | "suspended" | "shelved" | "shelved_offloaded" | "rescued" | "deleted" | "failed" | "error" | "unknown" | "missing";
2307
2307
  /** Format: uuid */
2308
2308
  subnet_id: string | null;
2309
2309
  /** Format: date-time */
2310
2310
  updated_at: string;
2311
- /** @enum {string} */
2312
- power_state: "no_state" | "running" | "paused" | "shutdown" | "crashed" | "suspended" | "unknown";
2313
2311
  /** Format: int64 */
2314
2312
  generation: number;
2315
2313
  /** Format: date-time */
@@ -2515,8 +2513,11 @@ export interface components {
2515
2513
  public_ips: string[] | null;
2516
2514
  addresses?: components["schemas"]["PortAddress"][];
2517
2515
  attachment?: components["schemas"]["PortAttachment"] | null;
2518
- /** @enum {string} */
2519
- status: "pending" | "available" | "error" | "unknown";
2516
+ /**
2517
+ * @description `missing` means the interface no longer exists in the cloud.
2518
+ * @enum {string}
2519
+ */
2520
+ status: "pending" | "available" | "error" | "unknown" | "missing";
2520
2521
  /** Format: int64 */
2521
2522
  generation: number;
2522
2523
  /** Format: date-time */
@@ -2608,10 +2609,10 @@ export interface components {
2608
2609
  /** Format: uuid */
2609
2610
  region_id: string;
2610
2611
  /**
2611
- * @description Only `available` accepts new instances, interfaces and floating IPs
2612
+ * @description Only `available` accepts new instances, interfaces and floating IPs. `missing` means the network no longer exists in the cloud.
2612
2613
  * @enum {string}
2613
2614
  */
2614
- status: "pending" | "available" | "error" | "unknown";
2615
+ status: "pending" | "available" | "error" | "unknown" | "missing";
2615
2616
  /** Format: date-time */
2616
2617
  updated_at: string;
2617
2618
  /** @description The operation in progress on this private network, or null when none is. */
@@ -2808,6 +2809,10 @@ export interface components {
2808
2809
  * until a replacement quota is activated. Null when no purchase has been recorded.
2809
2810
  */
2810
2811
  subscription_id: string | null;
2812
+ /** @description The billing choice of the associated quota purchase, as given when it was bought. A change of an existing purchase has to give the same choice. Null when no purchase has been recorded. */
2813
+ billing: components["schemas"]["BillingChoice"] | null;
2814
+ /** @description The subscription a cancellation through Billing has to cover to release this snapshot quota. A subscription that has ended is not listed, and the list is empty when no subscription pays for the quota. */
2815
+ release_subscription_ids: string[];
2811
2816
  /**
2812
2817
  * Format: int64
2813
2818
  * @description Target count awaiting checkout or activation; null when no purchase is pending.
@@ -2867,10 +2872,10 @@ export interface components {
2867
2872
  */
2868
2873
  size_gb: number;
2869
2874
  /**
2870
- * @description `pending` once a quota slot is reserved, `provisioning` while the snapshot is taken, then `available`. `failed` means the snapshot was not created; its slot is released once no snapshot data remains.
2875
+ * @description `pending` once a quota slot is reserved, `provisioning` while the snapshot is taken, then `available`. `failed` means the snapshot was not created; its slot is released once no snapshot data remains. `missing` means the snapshot no longer exists in the cloud.
2871
2876
  * @enum {string}
2872
2877
  */
2873
- status: "pending" | "provisioning" | "available" | "deleted" | "failed" | "error";
2878
+ status: "pending" | "provisioning" | "available" | "deleted" | "failed" | "error" | "missing";
2874
2879
  /** @description The operation in progress on this snapshot, or null when none is. */
2875
2880
  readonly operation: components["schemas"]["SnapshotOperation"] | null;
2876
2881
  /** Format: int64 */
@@ -2969,6 +2974,8 @@ export interface components {
2969
2974
  * @description The Billing subscription that backup usage is billed under; null before an activation is requested.
2970
2975
  */
2971
2976
  subscription_id: string | null;
2977
+ /** @description The subscription a cancellation through Billing has to cover to release this backup service. A subscription that has ended is not listed, and the list is empty when no subscription pays for the service. */
2978
+ release_subscription_ids: string[];
2972
2979
  /**
2973
2980
  * Format: int64
2974
2981
  * @description The total `capacity_gib` of the backups retained in this region.
@@ -3016,11 +3023,8 @@ export interface components {
3016
3023
  * @description The pack's Billing subscription, through which it is renewed or canceled.
3017
3024
  */
3018
3025
  subscription_id: string | null;
3019
- /**
3020
- * Format: date-time
3021
- * @description The end of the current paid term; null until the pack is active.
3022
- */
3023
- paid_until: string | null;
3026
+ /** @description The subscription a cancellation through Billing has to cover to release this capacity pack. A subscription that has ended is not listed, and the list is empty when no subscription pays for the pack. */
3027
+ release_subscription_ids: string[];
3024
3028
  /** Format: date-time */
3025
3029
  created_at: string;
3026
3030
  };
@@ -3418,7 +3422,7 @@ export interface components {
3418
3422
  name: string;
3419
3423
  /** @description How an address from this pool can be bought, per address. Null when the project has no billing account. */
3420
3424
  readonly pricing: components["schemas"]["Pricing"] | null;
3421
- /** @description How the bandwidth of an address from this pool is billed, per Mbit/s, with the same billing choice as the address. Null when the project has no billing account. */
3425
+ /** @description How the bandwidth of an address from this pool is billed, per Mbit/s. It is bought in the same purchase as the address, with the same billing choice. Null when the project has no billing account. */
3422
3426
  readonly bandwidth_pricing: components["schemas"]["Pricing"] | null;
3423
3427
  };
3424
3428
  IPv4PoolListResponseBody: {
@@ -3443,7 +3447,7 @@ export interface components {
3443
3447
  /** Format: date-time */
3444
3448
  released_at: string | null;
3445
3449
  };
3446
- /** @description One subscription of a release set and the resource it pays for. Multiple internal billing components may refer to the same floating IP; they do not create independent bandwidth resources. */
3450
+ /** @description One subscription of a release set and the resource it pays for. */
3447
3451
  ReleaseSetItem: {
3448
3452
  /** Format: uuid */
3449
3453
  subscription_id: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@leaflow/sdk",
3
- "version": "0.103.0",
3
+ "version": "0.104.0",
4
4
  "description": "Leaflow 平台 API 的 TypeScript SDK",
5
5
  "license": "MIT",
6
6
  "repository": {