infrawrench-sdk 1.16.0 → 1.18.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.
- checksums.yaml +4 -4
- data/README.md +2 -2
- data/infrawrench-sdk.gemspec +4 -4
- data/lib/infrawrench/client.rb +263 -2
- data/lib/infrawrench/sdk.rb +2 -2
- data/lib/infrawrench/transport.rb +2 -2
- data/lib/infrawrench/version.rb +3 -3
- data/lib/infrawrench-sdk.rb +2 -2
- data/sig/infrawrench/sdk.rbs +177 -3
- metadata +3 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 88e054d8ab5e5f760e83695779f5d6fb4fd8630779b87d76c7268df6458a4368
|
|
4
|
+
data.tar.gz: 05cf568abc46f27c6488f536dba00e43f6b2905df806ac012a2bb1b8db33112c
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 3a594eda98b0d94712d89d36a7898bb521d1efd0d68edc137841ee3bf237aa787fa10a15463b01f2a80386ec275671270d33936c00eae59b23803099426a7f95
|
|
7
|
+
data.tar.gz: 90bf6a53e80839579db54dff18b4f9ea3e2c8e7ee1685ba1041d8346ba33e31e8c112f6b223fea188ffc5703b6d3de40690401bf2687a1b1d983edbabddbd819
|
data/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# infrawrench-sdk
|
|
2
2
|
|
|
3
|
-
Generated Ruby client for the Infrawrench API (API version `1.
|
|
3
|
+
Generated Ruby client for the Infrawrench API (API version `1.18.0`).
|
|
4
4
|
|
|
5
5
|
**Do not edit this gem by hand** — it is regenerated from `openapi.json` and is
|
|
6
6
|
not checked into the repository. Run
|
|
@@ -41,7 +41,7 @@ Every method takes an optional trailing `request_options:` hash (`:headers`,
|
|
|
41
41
|
Responses are the plain `Hash`/`Array` that `JSON.parse` returns, with String
|
|
42
42
|
keys spelled exactly as the wire spells them. There are no model classes — see
|
|
43
43
|
[`sig/infrawrench/sdk.rbs`](./sig/infrawrench/sdk.rbs) for the shape of every one of the
|
|
44
|
-
|
|
44
|
+
615 schemas, as RBS type aliases that steep and TypeProf can read.
|
|
45
45
|
|
|
46
46
|
Non-2xx responses raise `Infrawrench::ApiError`, which carries `#status`,
|
|
47
47
|
the parsed `#body`, and the machine-readable `#code` when the API sends one —
|
data/infrawrench-sdk.gemspec
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
# infrawrench-sdk v1.
|
|
3
|
+
# infrawrench-sdk v1.18.0 | MIT | Copyright (c) 2026 Infrawrench LLC
|
|
4
4
|
# https://github.com/Infrawrench/Infrawrench
|
|
5
5
|
#
|
|
6
|
-
# Generated from the Infrawrench API OpenAPI 3.1 spec (API version 1.
|
|
6
|
+
# Generated from the Infrawrench API OpenAPI 3.1 spec (API version 1.18.0).
|
|
7
7
|
#
|
|
8
8
|
# DO NOT EDIT. Regenerate with:
|
|
9
9
|
# pnpm --filter @infrawrench/web generate:sdk
|
|
@@ -17,8 +17,8 @@ require_relative "lib/infrawrench/version"
|
|
|
17
17
|
Gem::Specification.new do |spec|
|
|
18
18
|
spec.name = "infrawrench-sdk"
|
|
19
19
|
spec.version = Infrawrench::VERSION
|
|
20
|
-
spec.summary = "Generated Ruby client for the Infrawrench API (v1.
|
|
21
|
-
spec.description = "Generated Ruby client for the Infrawrench API (v1.
|
|
20
|
+
spec.summary = "Generated Ruby client for the Infrawrench API (v1.18.0)."
|
|
21
|
+
spec.description = "Generated Ruby client for the Infrawrench API (v1.18.0). Covers the published API surface only — operations marked x-internal in the spec are not generated. No runtime dependencies."
|
|
22
22
|
spec.authors = ["Infrawrench LLC", "Astrid Gealer"]
|
|
23
23
|
spec.email = ["astrid@infrawrench.com"]
|
|
24
24
|
spec.homepage = "https://infrawrench.com/docs/team-and-billing/client-sdks"
|
data/lib/infrawrench/client.rb
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
# infrawrench-sdk v1.
|
|
3
|
+
# infrawrench-sdk v1.18.0 | MIT | Copyright (c) 2026 Infrawrench LLC
|
|
4
4
|
# https://github.com/Infrawrench/Infrawrench
|
|
5
5
|
#
|
|
6
|
-
# Generated from the Infrawrench API OpenAPI 3.1 spec (API version 1.
|
|
6
|
+
# Generated from the Infrawrench API OpenAPI 3.1 spec (API version 1.18.0).
|
|
7
7
|
#
|
|
8
8
|
# DO NOT EDIT. Regenerate with:
|
|
9
9
|
# pnpm --filter @infrawrench/web generate:sdk
|
|
@@ -2571,16 +2571,203 @@ module Infrawrench
|
|
|
2571
2571
|
end
|
|
2572
2572
|
end
|
|
2573
2573
|
|
|
2574
|
+
# `client.changes.revert`
|
|
2575
|
+
class ChangesRevertNamespace
|
|
2576
|
+
# @api private
|
|
2577
|
+
# @param transport [Transport]
|
|
2578
|
+
def initialize(transport)
|
|
2579
|
+
@transport = transport
|
|
2580
|
+
end
|
|
2581
|
+
|
|
2582
|
+
# Revert one change event
|
|
2583
|
+
#
|
|
2584
|
+
# Applies the inverse patch through the plugin's ordinary `updateResource`
|
|
2585
|
+
# path — the same call the Edit form makes — and only for the fields the dry
|
|
2586
|
+
# run marked `revertible`.
|
|
2587
|
+
#
|
|
2588
|
+
# The plan is rebuilt against a fresh live read immediately before the
|
|
2589
|
+
# write, so a field that moved between the preview and the apply becomes a
|
|
2590
|
+
# conflict and drops out of the patch.
|
|
2591
|
+
#
|
|
2592
|
+
# **This is a last-moment re-read, not an atomic compare-and-swap.** The gap
|
|
2593
|
+
# between reading a field and writing it is one provider round-trip wide,
|
|
2594
|
+
# and a third party writing inside that gap will be overwritten without
|
|
2595
|
+
# warning. It cannot be closed generically: the plugin update contract
|
|
2596
|
+
# carries no expected value, ETag or version token, so no conditional write
|
|
2597
|
+
# can be expressed for a provider that supports one. Treat the conflict
|
|
2598
|
+
# detection as a strong guard against stale plans, not as a mutual-exclusion
|
|
2599
|
+
# guarantee against other writers.
|
|
2600
|
+
#
|
|
2601
|
+
# Reverts of the *same event* are mutually exclusive: the event is claimed
|
|
2602
|
+
# with a conditional update under a five-minute lease, so two concurrent
|
|
2603
|
+
# reverts cannot both reach the provider and the loser gets `409`. A
|
|
2604
|
+
# provider failure releases the claim immediately; a process that dies
|
|
2605
|
+
# mid-write leaves a claim that expires, so an interrupted revert is
|
|
2606
|
+
# retryable rather than permanently stuck. `revertedAt` is only set once the
|
|
2607
|
+
# provider accepted the write.
|
|
2608
|
+
#
|
|
2609
|
+
# The claim carries an owner token, and every write that ends a revert is
|
|
2610
|
+
# fenced on it. An attempt whose provider call outlives the lease can
|
|
2611
|
+
# therefore neither release nor complete the claim that replaced it — it
|
|
2612
|
+
# gets `409` with `appliedFields` naming what it did write, so the caller
|
|
2613
|
+
# can reconcile rather than assume. Two attempts can overlap in that case,
|
|
2614
|
+
# but they cannot disagree: both invert the same recorded event to the same
|
|
2615
|
+
# values, so the second one's patch is a subset of the first's.
|
|
2616
|
+
#
|
|
2617
|
+
# If a write reaches the provider but recording it fails, the response is
|
|
2618
|
+
# `500` with `appliedFields` — the resource moved and the timeline has not
|
|
2619
|
+
# caught up. The claim is deliberately held in that case, and the next
|
|
2620
|
+
# attempt after the lease expires finds every field already back and records
|
|
2621
|
+
# the revert without touching the provider again, answering `200` with
|
|
2622
|
+
# `reconciled: true` and an empty `appliedFields`. A resource put back by
|
|
2623
|
+
# hand is not mistaken for this: reconciliation only happens on an event
|
|
2624
|
+
# whose claim was still outstanding, which is the only state in which an
|
|
2625
|
+
# unrecorded write is possible.
|
|
2626
|
+
#
|
|
2627
|
+
# Blocked with `423` while an org change freeze is in effect. Every attempt
|
|
2628
|
+
# whose write reached the provider is audit-logged as
|
|
2629
|
+
# `resource.change_revert`, including one that lost its claim or could not
|
|
2630
|
+
# record — the entry's `outcome` is `recorded`, `superseded`, `unrecorded`
|
|
2631
|
+
# or `reconciled`, so a contested outcome reads as one mutation rather than
|
|
2632
|
+
# as several reverts. An attempt that neither wrote nor recorded anything
|
|
2633
|
+
# logs nothing. Attribution is best-effort: no transaction spans a
|
|
2634
|
+
# third-party cloud API and Infrawrench's database, so if the audit insert
|
|
2635
|
+
# itself fails the response carries `auditRecorded: false` and the details
|
|
2636
|
+
# go to the server log rather than being silently dropped.
|
|
2637
|
+
#
|
|
2638
|
+
# The stored resource snapshot is deliberately left untouched, so the next
|
|
2639
|
+
# poll observes the reverted state and records it as an ordinary change
|
|
2640
|
+
# event.
|
|
2641
|
+
#
|
|
2642
|
+
# POST /api/org/{orgId}/changes/{changeId}/revert
|
|
2643
|
+
#
|
|
2644
|
+
# Raises on 400: Bad request
|
|
2645
|
+
#
|
|
2646
|
+
# Raises on 404: Not found
|
|
2647
|
+
#
|
|
2648
|
+
# Raises on 409: Already reverted, another revert holds the event, nothing
|
|
2649
|
+
# in the plan is writable, or this attempt was superseded mid-write (its
|
|
2650
|
+
# lease lapsed). The body carries `code: change_revert_conflict` for all but
|
|
2651
|
+
# the writability case, and `appliedFields` when the provider write had
|
|
2652
|
+
# already landed.
|
|
2653
|
+
#
|
|
2654
|
+
# Raises on 423: Blocked by an active change freeze. Retry with the
|
|
2655
|
+
# `x-change-freeze-override: true` header if you hold `freezes:override`;
|
|
2656
|
+
# both blocks and overrides are audit-logged.
|
|
2657
|
+
#
|
|
2658
|
+
# Raises on 500: The provider accepted the write but it could not be
|
|
2659
|
+
# recorded against the event. The resource *has* been put back;
|
|
2660
|
+
# `appliedFields` names what changed. A later retry reconciles the timeline.
|
|
2661
|
+
#
|
|
2662
|
+
# Raises on 502: The provider couldn't be read. Nothing was written.
|
|
2663
|
+
#
|
|
2664
|
+
# @param org_id [String, nil] Organization id. Defaults to the `org_id` the client was
|
|
2665
|
+
# constructed with.
|
|
2666
|
+
# @param change_id [String]
|
|
2667
|
+
# @param request_options [Hash, nil] Per-call `:headers`, `:timeout` and `:open_timeout`.
|
|
2668
|
+
# @return [Hash] Parsed JSON, shaped as `RevertApplyResponse` — see
|
|
2669
|
+
# `sig/infrawrench/sdk.rbs`.
|
|
2670
|
+
# @raise [Infrawrench::ApiError] On any non-2xx response.
|
|
2671
|
+
def create(change_id:, org_id: nil, request_options: nil)
|
|
2672
|
+
@transport.request(
|
|
2673
|
+
http_method: "POST",
|
|
2674
|
+
path: "/api/org/{orgId}/changes/{changeId}/revert",
|
|
2675
|
+
path_params: { "orgId" => org_id, "changeId" => change_id },
|
|
2676
|
+
request_options: request_options
|
|
2677
|
+
)
|
|
2678
|
+
end
|
|
2679
|
+
|
|
2680
|
+
# Dry-run a revert of one change event
|
|
2681
|
+
#
|
|
2682
|
+
# Inverts the recorded diff and reconciles it against the resource's
|
|
2683
|
+
# *current* live fields, which is the whole point: the poller may have
|
|
2684
|
+
# recorded this hours ago and the world may have moved on. Read-only — it
|
|
2685
|
+
# reads from the provider and writes nothing.
|
|
2686
|
+
#
|
|
2687
|
+
# Only `updated` events with a field diff can be reverted. `outputs.*`
|
|
2688
|
+
# entries are provider-derived and are never written back, and whether a
|
|
2689
|
+
# field is writable at all is the plugin's own edit-form rule (`editable`,
|
|
2690
|
+
# minus `secret` and `association` kinds), so a revert can never issue a
|
|
2691
|
+
# provider call an edit could not.
|
|
2692
|
+
#
|
|
2693
|
+
# Gated on `resources:write` rather than `resources:read`: the plan names
|
|
2694
|
+
# the write it is offering to make.
|
|
2695
|
+
#
|
|
2696
|
+
# GET /api/org/{orgId}/changes/{changeId}/revert
|
|
2697
|
+
#
|
|
2698
|
+
# Raises on 404: Not found
|
|
2699
|
+
#
|
|
2700
|
+
# Raises on 502: The provider couldn't be read, so no plan can be made
|
|
2701
|
+
# safely. Nothing was written.
|
|
2702
|
+
#
|
|
2703
|
+
# @param org_id [String, nil] Organization id. Defaults to the `org_id` the client was
|
|
2704
|
+
# constructed with.
|
|
2705
|
+
# @param change_id [String]
|
|
2706
|
+
# @param request_options [Hash, nil] Per-call `:headers`, `:timeout` and `:open_timeout`.
|
|
2707
|
+
# @return [Hash] Parsed JSON, shaped as `RevertPreviewResponse` — see
|
|
2708
|
+
# `sig/infrawrench/sdk.rbs`.
|
|
2709
|
+
# @raise [Infrawrench::ApiError] On any non-2xx response.
|
|
2710
|
+
def get(change_id:, org_id: nil, request_options: nil)
|
|
2711
|
+
@transport.request(
|
|
2712
|
+
http_method: "GET",
|
|
2713
|
+
path: "/api/org/{orgId}/changes/{changeId}/revert",
|
|
2714
|
+
path_params: { "orgId" => org_id, "changeId" => change_id },
|
|
2715
|
+
request_options: request_options
|
|
2716
|
+
)
|
|
2717
|
+
end
|
|
2718
|
+
end
|
|
2719
|
+
|
|
2574
2720
|
# `client.changes`
|
|
2575
2721
|
class ChangesNamespace
|
|
2576
2722
|
# @return [ChangesAlertSettingsNamespace] `client.changes.alert_settings`
|
|
2577
2723
|
attr_reader :alert_settings
|
|
2724
|
+
# @return [ChangesRevertNamespace] `client.changes.revert`
|
|
2725
|
+
attr_reader :revert
|
|
2578
2726
|
|
|
2579
2727
|
# @api private
|
|
2580
2728
|
# @param transport [Transport]
|
|
2581
2729
|
def initialize(transport)
|
|
2582
2730
|
@transport = transport
|
|
2583
2731
|
@alert_settings = ChangesAlertSettingsNamespace.new(@transport)
|
|
2732
|
+
@revert = ChangesRevertNamespace.new(@transport)
|
|
2733
|
+
end
|
|
2734
|
+
|
|
2735
|
+
# Cost impact of a page of changes
|
|
2736
|
+
#
|
|
2737
|
+
# For each change, compares the resource's per-day spend over the window
|
|
2738
|
+
# before it against the window after, and reports the difference as a
|
|
2739
|
+
# run-rate delta.
|
|
2740
|
+
#
|
|
2741
|
+
# A POST because it takes a list of ids, not because it writes: nothing is
|
|
2742
|
+
# stored. The answer is recomputed on every call, deliberately — provider
|
|
2743
|
+
# cost arrives late and is then restated, so a stored number would be a
|
|
2744
|
+
# wrong number that never corrects itself.
|
|
2745
|
+
#
|
|
2746
|
+
# Both windows exclude the change's own day (spend on it is half old shape,
|
|
2747
|
+
# half new) and today (an accruing day always reads as a dip), and are
|
|
2748
|
+
# clamped symmetrically to the days cost collection actually covers.
|
|
2749
|
+
#
|
|
2750
|
+
# _Requires permission: `costs:read`._
|
|
2751
|
+
#
|
|
2752
|
+
# POST /api/org/{orgId}/changes/cost-impacts
|
|
2753
|
+
#
|
|
2754
|
+
# Raises on 400: Bad request
|
|
2755
|
+
#
|
|
2756
|
+
# @param org_id [String, nil] Organization id. Defaults to the `org_id` the client was
|
|
2757
|
+
# constructed with.
|
|
2758
|
+
# @param body [Hash, nil] Request body, shaped as `ChangeCostImpactsRequest`.
|
|
2759
|
+
# @param request_options [Hash, nil] Per-call `:headers`, `:timeout` and `:open_timeout`.
|
|
2760
|
+
# @return [Hash] Parsed JSON, shaped as `ChangeCostImpactsResponse` — see
|
|
2761
|
+
# `sig/infrawrench/sdk.rbs`.
|
|
2762
|
+
# @raise [Infrawrench::ApiError] On any non-2xx response.
|
|
2763
|
+
def cost_impacts(org_id: nil, body: nil, request_options: nil)
|
|
2764
|
+
@transport.request(
|
|
2765
|
+
http_method: "POST",
|
|
2766
|
+
path: "/api/org/{orgId}/changes/cost-impacts",
|
|
2767
|
+
path_params: { "orgId" => org_id },
|
|
2768
|
+
body: body,
|
|
2769
|
+
request_options: request_options
|
|
2770
|
+
)
|
|
2584
2771
|
end
|
|
2585
2772
|
|
|
2586
2773
|
# Org-wide change timeline (paginated, filterable)
|
|
@@ -3103,6 +3290,43 @@ module Infrawrench
|
|
|
3103
3290
|
@transport = transport
|
|
3104
3291
|
end
|
|
3105
3292
|
|
|
3293
|
+
# Pin a change's or deploy's cost impact onto the cost charts
|
|
3294
|
+
#
|
|
3295
|
+
# Writes the finding as a cost annotation, so the step in the run rate is
|
|
3296
|
+
# explained on the graph where it shows. Re-posting the same subject
|
|
3297
|
+
# **rewords the existing note** rather than adding a second — which is what
|
|
3298
|
+
# makes it safe to pin a finding again once the provider has finished
|
|
3299
|
+
# restating. The note's date and report scope are never rewritten: they may
|
|
3300
|
+
# have been edited deliberately.
|
|
3301
|
+
#
|
|
3302
|
+
# A subject with no measurable impact is a 400, not a note reading
|
|
3303
|
+
# `$0.00/day`.
|
|
3304
|
+
#
|
|
3305
|
+
# _Requires permission: `costs:write`._
|
|
3306
|
+
#
|
|
3307
|
+
# POST /api/org/{orgId}/cost-annotations/change-impact
|
|
3308
|
+
#
|
|
3309
|
+
# Raises on 400: Bad request
|
|
3310
|
+
#
|
|
3311
|
+
# Raises on 404: Not found
|
|
3312
|
+
#
|
|
3313
|
+
# @param org_id [String, nil] Organization id. Defaults to the `org_id` the client was
|
|
3314
|
+
# constructed with.
|
|
3315
|
+
# @param body [Hash, nil] Request body, shaped as `ChangeCostImpactAnnotationRequest`.
|
|
3316
|
+
# @param request_options [Hash, nil] Per-call `:headers`, `:timeout` and `:open_timeout`.
|
|
3317
|
+
# @return [Hash] Parsed JSON, shaped as `ChangeCostImpactAnnotationResponse` — see
|
|
3318
|
+
# `sig/infrawrench/sdk.rbs`.
|
|
3319
|
+
# @raise [Infrawrench::ApiError] On any non-2xx response.
|
|
3320
|
+
def change_impact(org_id: nil, body: nil, request_options: nil)
|
|
3321
|
+
@transport.request(
|
|
3322
|
+
http_method: "POST",
|
|
3323
|
+
path: "/api/org/{orgId}/cost-annotations/change-impact",
|
|
3324
|
+
path_params: { "orgId" => org_id },
|
|
3325
|
+
body: body,
|
|
3326
|
+
request_options: request_options
|
|
3327
|
+
)
|
|
3328
|
+
end
|
|
3329
|
+
|
|
3106
3330
|
# Create a cost annotation
|
|
3107
3331
|
#
|
|
3108
3332
|
# _Requires permission: `costs:write`._
|
|
@@ -5769,6 +5993,43 @@ module Infrawrench
|
|
|
5769
5993
|
@transport = transport
|
|
5770
5994
|
end
|
|
5771
5995
|
|
|
5996
|
+
# Cost impact of a deployment run
|
|
5997
|
+
#
|
|
5998
|
+
# The same comparison as `POST /changes/cost-impacts`, run over the
|
|
5999
|
+
# resources this deploy provisioned, with a per-resource breakdown that sums
|
|
6000
|
+
# to the total.
|
|
6001
|
+
#
|
|
6002
|
+
# _Requires permission: `costs:read`._
|
|
6003
|
+
#
|
|
6004
|
+
# GET /api/org/{orgId}/deployments/runs/{id}/cost-impact
|
|
6005
|
+
#
|
|
6006
|
+
# Raises on 400: Bad request
|
|
6007
|
+
#
|
|
6008
|
+
# Raises on 404: Not found
|
|
6009
|
+
#
|
|
6010
|
+
# @param org_id [String, nil] Organization id. Defaults to the `org_id` the client was
|
|
6011
|
+
# constructed with.
|
|
6012
|
+
# @param id [String]
|
|
6013
|
+
# @param window_days [Integer, nil]
|
|
6014
|
+
# @param cost_basis [String, nil] Which charge-type basis both windows are read on. `cash`
|
|
6015
|
+
# (the default) is what the provider charged on the day it charged it; `amortized` spreads a
|
|
6016
|
+
# commitment's up-front fee across the term it buys. It is echoed on every response because
|
|
6017
|
+
# a delta whose basis is unstated is unreadable — an amortized 'after' against a cash
|
|
6018
|
+
# 'before' looks exactly like a saving.
|
|
6019
|
+
# @param request_options [Hash, nil] Per-call `:headers`, `:timeout` and `:open_timeout`.
|
|
6020
|
+
# @return [Hash] Parsed JSON, shaped as `DeploymentCostImpact` — see
|
|
6021
|
+
# `sig/infrawrench/sdk.rbs`.
|
|
6022
|
+
# @raise [Infrawrench::ApiError] On any non-2xx response.
|
|
6023
|
+
def cost_impact(id:, org_id: nil, window_days: nil, cost_basis: nil, request_options: nil)
|
|
6024
|
+
@transport.request(
|
|
6025
|
+
http_method: "GET",
|
|
6026
|
+
path: "/api/org/{orgId}/deployments/runs/{id}/cost-impact",
|
|
6027
|
+
path_params: { "orgId" => org_id, "id" => id },
|
|
6028
|
+
query: { "windowDays" => window_days, "costBasis" => cost_basis },
|
|
6029
|
+
request_options: request_options
|
|
6030
|
+
)
|
|
6031
|
+
end
|
|
6032
|
+
|
|
5772
6033
|
# Record a deployment that ran elsewhere
|
|
5773
6034
|
#
|
|
5774
6035
|
# The CLI builds on the operator's own machine, so the server never sees
|
data/lib/infrawrench/sdk.rb
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
# infrawrench-sdk v1.
|
|
3
|
+
# infrawrench-sdk v1.18.0 | MIT | Copyright (c) 2026 Infrawrench LLC
|
|
4
4
|
# https://github.com/Infrawrench/Infrawrench
|
|
5
5
|
#
|
|
6
|
-
# Generated from the Infrawrench API OpenAPI 3.1 spec (API version 1.
|
|
6
|
+
# Generated from the Infrawrench API OpenAPI 3.1 spec (API version 1.18.0).
|
|
7
7
|
#
|
|
8
8
|
# DO NOT EDIT. Regenerate with:
|
|
9
9
|
# pnpm --filter @infrawrench/web generate:sdk
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
# infrawrench-sdk v1.
|
|
3
|
+
# infrawrench-sdk v1.18.0 | MIT | Copyright (c) 2026 Infrawrench LLC
|
|
4
4
|
# https://github.com/Infrawrench/Infrawrench
|
|
5
5
|
#
|
|
6
|
-
# Generated from the Infrawrench API OpenAPI 3.1 spec (API version 1.
|
|
6
|
+
# Generated from the Infrawrench API OpenAPI 3.1 spec (API version 1.18.0).
|
|
7
7
|
#
|
|
8
8
|
# DO NOT EDIT. Regenerate with:
|
|
9
9
|
# pnpm --filter @infrawrench/web generate:sdk
|
data/lib/infrawrench/version.rb
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
# infrawrench-sdk v1.
|
|
3
|
+
# infrawrench-sdk v1.18.0 | MIT | Copyright (c) 2026 Infrawrench LLC
|
|
4
4
|
# https://github.com/Infrawrench/Infrawrench
|
|
5
5
|
#
|
|
6
|
-
# Generated from the Infrawrench API OpenAPI 3.1 spec (API version 1.
|
|
6
|
+
# Generated from the Infrawrench API OpenAPI 3.1 spec (API version 1.18.0).
|
|
7
7
|
#
|
|
8
8
|
# DO NOT EDIT. Regenerate with:
|
|
9
9
|
# pnpm --filter @infrawrench/web generate:sdk
|
|
@@ -15,5 +15,5 @@
|
|
|
15
15
|
# Kept in its own file so the gemspec can read the version without loading the
|
|
16
16
|
# client — a gemspec that pulls in net/http is a gemspec that can fail to parse.
|
|
17
17
|
module Infrawrench
|
|
18
|
-
VERSION = "1.
|
|
18
|
+
VERSION = "1.18.0"
|
|
19
19
|
end
|
data/lib/infrawrench-sdk.rb
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
# infrawrench-sdk v1.
|
|
3
|
+
# infrawrench-sdk v1.18.0 | MIT | Copyright (c) 2026 Infrawrench LLC
|
|
4
4
|
# https://github.com/Infrawrench/Infrawrench
|
|
5
5
|
#
|
|
6
|
-
# Generated from the Infrawrench API OpenAPI 3.1 spec (API version 1.
|
|
6
|
+
# Generated from the Infrawrench API OpenAPI 3.1 spec (API version 1.18.0).
|
|
7
7
|
#
|
|
8
8
|
# DO NOT EDIT. Regenerate with:
|
|
9
9
|
# pnpm --filter @infrawrench/web generate:sdk
|
data/sig/infrawrench/sdk.rbs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
# infrawrench-sdk v1.
|
|
1
|
+
# infrawrench-sdk v1.18.0 | MIT | Copyright (c) 2026 Infrawrench LLC
|
|
2
2
|
# https://github.com/Infrawrench/Infrawrench
|
|
3
3
|
#
|
|
4
|
-
# Generated from the Infrawrench API OpenAPI 3.1 spec (API version 1.
|
|
4
|
+
# Generated from the Infrawrench API OpenAPI 3.1 spec (API version 1.18.0).
|
|
5
5
|
#
|
|
6
6
|
# DO NOT EDIT. Regenerate with:
|
|
7
7
|
# pnpm --filter @infrawrench/web generate:sdk
|
|
@@ -888,6 +888,96 @@ module Infrawrench
|
|
|
888
888
|
"slots" => Array[capacity_slot]
|
|
889
889
|
}
|
|
890
890
|
|
|
891
|
+
# Which charge-type basis both windows are read on. `cash` (the default) is
|
|
892
|
+
# what the provider charged on the day it charged it; `amortized` spreads a
|
|
893
|
+
# commitment's up-front fee across the term it buys. It is echoed on every
|
|
894
|
+
# response because a delta whose basis is unstated is unreadable — an
|
|
895
|
+
# amortized 'after' against a cash 'before' looks exactly like a saving.
|
|
896
|
+
#
|
|
897
|
+
# Spec schema: `ChangeCostBasis`.
|
|
898
|
+
type change_cost_basis = "cash" | "amortized"
|
|
899
|
+
|
|
900
|
+
# Spec schema: `ChangeCostImpact`.
|
|
901
|
+
type change_cost_impact = {
|
|
902
|
+
"status" => change_cost_impact_status,
|
|
903
|
+
"costBasis" => change_cost_basis,
|
|
904
|
+
"windowDays" => Integer,
|
|
905
|
+
"effectiveWindowDays" => Integer,
|
|
906
|
+
"eventDay" => String,
|
|
907
|
+
"before" => change_cost_impact_window,
|
|
908
|
+
"after" => change_cost_impact_window,
|
|
909
|
+
"series" => Array[change_cost_impact_series],
|
|
910
|
+
"confidence" => change_cost_impact_confidence,
|
|
911
|
+
"reasons" => Array[change_cost_impact_reason],
|
|
912
|
+
"overlappingChanges" => Integer
|
|
913
|
+
}
|
|
914
|
+
|
|
915
|
+
# Spec schema: `ChangeCostImpactAnnotationRequest`.
|
|
916
|
+
type change_cost_impact_annotation_request = {
|
|
917
|
+
"subjectKind" => "change" | "deployment",
|
|
918
|
+
"subjectId" => String,
|
|
919
|
+
?"windowDays" => Integer,
|
|
920
|
+
?"costBasis" => change_cost_basis
|
|
921
|
+
}
|
|
922
|
+
|
|
923
|
+
# Spec schema: `ChangeCostImpactAnnotationResponse`.
|
|
924
|
+
type change_cost_impact_annotation_response = { "annotationId" => String, "text" => String, "impact" => change_cost_impact }
|
|
925
|
+
|
|
926
|
+
# How much the delta is worth believing. Derived from the number of comparable
|
|
927
|
+
# days per side (7+ high, 4+ medium, otherwise low) and dropped one tier when
|
|
928
|
+
# other recorded changes touched the same resource inside the window.
|
|
929
|
+
#
|
|
930
|
+
# Spec schema: `ChangeCostImpactConfidence`.
|
|
931
|
+
type change_cost_impact_confidence = "high" | "medium" | "low" | "none"
|
|
932
|
+
|
|
933
|
+
# Spec schema: `ChangeCostImpactEntry`.
|
|
934
|
+
type change_cost_impact_entry = { "changeId" => String, "resourceId" => resource_id, "impact" => change_cost_impact }
|
|
935
|
+
|
|
936
|
+
# Why the result reads the way it does. Every non-`measured` status carries at
|
|
937
|
+
# least one, and `measured` carries whatever lowered its confidence.
|
|
938
|
+
# `period_native_provider` is the notable one: a provider that dates a whole
|
|
939
|
+
# invoice period to the period's start cannot be read by a day-window
|
|
940
|
+
# comparison at all.
|
|
941
|
+
#
|
|
942
|
+
# Spec schema: `ChangeCostImpactReason`.
|
|
943
|
+
type change_cost_impact_reason = "no_cost_identity"
|
|
944
|
+
| "period_native_provider"
|
|
945
|
+
| "no_cost_data"
|
|
946
|
+
| "no_coverage_before"
|
|
947
|
+
| "no_coverage_after"
|
|
948
|
+
| "short_window"
|
|
949
|
+
| "window_clamped"
|
|
950
|
+
| "overlapping_changes"
|
|
951
|
+
|
|
952
|
+
# Spec schema: `ChangeCostImpactSeries`.
|
|
953
|
+
type change_cost_impact_series = {
|
|
954
|
+
"currency" => String,
|
|
955
|
+
"beforePerDay" => Numeric,
|
|
956
|
+
"afterPerDay" => Numeric,
|
|
957
|
+
"deltaPerDay" => Numeric,
|
|
958
|
+
"deltaPercent" => Numeric | nil,
|
|
959
|
+
"beforeTotal" => Numeric,
|
|
960
|
+
"afterTotal" => Numeric
|
|
961
|
+
}
|
|
962
|
+
|
|
963
|
+
# `measured` — both windows had collected data and the delta is real.
|
|
964
|
+
# `insufficient_data` — the windows exist but are too short to compare.
|
|
965
|
+
# `unknown` — nothing here can answer the question. **`unknown` is never
|
|
966
|
+
# zero**: a resource with no cost data reports that we cannot say, not that
|
|
967
|
+
# the change was free.
|
|
968
|
+
#
|
|
969
|
+
# Spec schema: `ChangeCostImpactStatus`.
|
|
970
|
+
type change_cost_impact_status = "measured" | "insufficient_data" | "unknown"
|
|
971
|
+
|
|
972
|
+
# Spec schema: `ChangeCostImpactWindow`.
|
|
973
|
+
type change_cost_impact_window = { "from" => String, "to" => String } | nil
|
|
974
|
+
|
|
975
|
+
# Spec schema: `ChangeCostImpactsRequest`.
|
|
976
|
+
type change_cost_impacts_request = { "changeIds" => Array[String], ?"windowDays" => Integer, ?"costBasis" => change_cost_basis }
|
|
977
|
+
|
|
978
|
+
# Spec schema: `ChangeCostImpactsResponse`.
|
|
979
|
+
type change_cost_impacts_response = { "impacts" => Array[change_cost_impact_entry] }
|
|
980
|
+
|
|
891
981
|
# Spec schema: `ChangeFreeze`.
|
|
892
982
|
type change_freeze = {
|
|
893
983
|
"id" => String,
|
|
@@ -2197,6 +2287,27 @@ module Infrawrench
|
|
|
2197
2287
|
# Spec schema: `DeployTriggerInput`.
|
|
2198
2288
|
type deploy_trigger_input = { "repo" => String, "branch" => String, "env" => String, ?"answers" => Hash[String, String] }
|
|
2199
2289
|
|
|
2290
|
+
# Spec schema: `DeploymentCostImpact`.
|
|
2291
|
+
type deployment_cost_impact = {
|
|
2292
|
+
"runId" => String,
|
|
2293
|
+
"costBasis" => change_cost_basis,
|
|
2294
|
+
"windowDays" => Integer,
|
|
2295
|
+
"eventDay" => String,
|
|
2296
|
+
"resources" => Array[deployment_cost_impact_resource],
|
|
2297
|
+
"total" => Array[{ "currency" => String, "deltaPerDay" => Numeric }],
|
|
2298
|
+
"unknownResources" => Integer,
|
|
2299
|
+
"confidence" => change_cost_impact_confidence & untyped
|
|
2300
|
+
}
|
|
2301
|
+
|
|
2302
|
+
# Spec schema: `DeploymentCostImpactResource`.
|
|
2303
|
+
type deployment_cost_impact_resource = {
|
|
2304
|
+
"resourceId" => resource_id,
|
|
2305
|
+
"displayName" => String,
|
|
2306
|
+
"pluginId" => String,
|
|
2307
|
+
"resourceTypeId" => String,
|
|
2308
|
+
"impact" => change_cost_impact
|
|
2309
|
+
}
|
|
2310
|
+
|
|
2200
2311
|
# Spec schema: `DeploymentRun`.
|
|
2201
2312
|
type deployment_run = {
|
|
2202
2313
|
"id" => String,
|
|
@@ -4602,7 +4713,8 @@ module Infrawrench
|
|
|
4602
4713
|
"changeKind" => resource_change_kind,
|
|
4603
4714
|
"diff" => Array[resource_field_change],
|
|
4604
4715
|
?"origin" => "schedule" | nil,
|
|
4605
|
-
"createdAt" => String
|
|
4716
|
+
"createdAt" => String,
|
|
4717
|
+
?"revertedAt" => String | nil
|
|
4606
4718
|
}
|
|
4607
4719
|
|
|
4608
4720
|
# Spec schema: `ResourceChangeFeedEntry`.
|
|
@@ -5166,6 +5278,58 @@ module Infrawrench
|
|
|
5166
5278
|
?"schedulable" => bool
|
|
5167
5279
|
}
|
|
5168
5280
|
|
|
5281
|
+
# Spec schema: `RevertApplyResponse`.
|
|
5282
|
+
type revert_apply_response = {
|
|
5283
|
+
"changeId" => String,
|
|
5284
|
+
"resourceId" => resource_id,
|
|
5285
|
+
"appliedFields" => Array[String],
|
|
5286
|
+
"plan" => revert_plan,
|
|
5287
|
+
"revertedAt" => String,
|
|
5288
|
+
?"reconciled" => bool,
|
|
5289
|
+
?"auditRecorded" => bool
|
|
5290
|
+
}
|
|
5291
|
+
|
|
5292
|
+
# Spec schema: `RevertFieldPlan`.
|
|
5293
|
+
type revert_field_plan = {
|
|
5294
|
+
"field" => String,
|
|
5295
|
+
?"revertTo" => untyped,
|
|
5296
|
+
?"changedTo" => untyped,
|
|
5297
|
+
?"current" => untyped,
|
|
5298
|
+
"status" => revert_field_status,
|
|
5299
|
+
"reason" => String
|
|
5300
|
+
}
|
|
5301
|
+
|
|
5302
|
+
# What a revert would do to one field. `revertible` — the field still holds
|
|
5303
|
+
# the value the change set, and the plugin's edit form can write the old one
|
|
5304
|
+
# back. `already-reverted` — it is already at the old value; nothing to do.
|
|
5305
|
+
# `conflict` — it changed again since, so reverting would discard the newer
|
|
5306
|
+
# value. `not-writable` — outside the plugin's editable surface, or the old
|
|
5307
|
+
# value is not something the edit form can submit. `provider-derived` — an
|
|
5308
|
+
# `outputs.*` entry, which the provider computes rather than accepts.
|
|
5309
|
+
#
|
|
5310
|
+
# Spec schema: `RevertFieldStatus`.
|
|
5311
|
+
type revert_field_status = "revertible" | "already-reverted" | "conflict" | "not-writable" | "provider-derived"
|
|
5312
|
+
|
|
5313
|
+
# Spec schema: `RevertPlan`.
|
|
5314
|
+
type revert_plan = {
|
|
5315
|
+
"fields" => Array[revert_field_plan],
|
|
5316
|
+
"revertibleFields" => Array[String],
|
|
5317
|
+
"revertible" => bool,
|
|
5318
|
+
"blockedReason" => String | nil
|
|
5319
|
+
}
|
|
5320
|
+
|
|
5321
|
+
# Spec schema: `RevertPreviewResponse`.
|
|
5322
|
+
type revert_preview_response = {
|
|
5323
|
+
"changeId" => String,
|
|
5324
|
+
"resourceId" => resource_id,
|
|
5325
|
+
"displayName" => String,
|
|
5326
|
+
"pluginId" => String,
|
|
5327
|
+
"resourceTypeId" => String,
|
|
5328
|
+
"accountId" => String,
|
|
5329
|
+
"plan" => revert_plan,
|
|
5330
|
+
"revertedAt" => String | nil
|
|
5331
|
+
}
|
|
5332
|
+
|
|
5169
5333
|
# Spec schema: `RightsizingListResponse`.
|
|
5170
5334
|
type rightsizing_list_response = {
|
|
5171
5335
|
"accounts" => Array[oversized_account_group],
|
|
@@ -6363,9 +6527,17 @@ module Infrawrench
|
|
|
6363
6527
|
def update: (?org_id: String?, ?body: drift_alert_settings_update?, ?request_options: Hash[Symbol, untyped]?) -> drift_alert_settings
|
|
6364
6528
|
end
|
|
6365
6529
|
|
|
6530
|
+
class ChangesRevertNamespace
|
|
6531
|
+
def initialize: (Transport) -> void
|
|
6532
|
+
def create: (change_id: String, ?org_id: String?, ?request_options: Hash[Symbol, untyped]?) -> revert_apply_response
|
|
6533
|
+
def get: (change_id: String, ?org_id: String?, ?request_options: Hash[Symbol, untyped]?) -> revert_preview_response
|
|
6534
|
+
end
|
|
6535
|
+
|
|
6366
6536
|
class ChangesNamespace
|
|
6367
6537
|
attr_reader alert_settings: ChangesAlertSettingsNamespace
|
|
6538
|
+
attr_reader revert: ChangesRevertNamespace
|
|
6368
6539
|
def initialize: (Transport) -> void
|
|
6540
|
+
def cost_impacts: (?org_id: String?, ?body: change_cost_impacts_request?, ?request_options: Hash[Symbol, untyped]?) -> change_cost_impacts_response
|
|
6369
6541
|
def get: (?org_id: String?, ?page: Integer?, ?page_size: Integer?, ?account_id: String?, ?resource_id: String?, ?kind: resource_change_kind?, ?from: String?, ?to: String?, ?request_options: Hash[Symbol, untyped]?) -> resource_change_feed_response
|
|
6370
6542
|
def resource: (resource_id: String, ?org_id: String?, ?limit: Integer?, ?request_options: Hash[Symbol, untyped]?) -> resource_change_list_response
|
|
6371
6543
|
end
|
|
@@ -6406,6 +6578,7 @@ module Infrawrench
|
|
|
6406
6578
|
|
|
6407
6579
|
class CostAnnotationsNamespace
|
|
6408
6580
|
def initialize: (Transport) -> void
|
|
6581
|
+
def change_impact: (?org_id: String?, ?body: change_cost_impact_annotation_request?, ?request_options: Hash[Symbol, untyped]?) -> change_cost_impact_annotation_response
|
|
6409
6582
|
def create: (body: cost_annotation_input, ?org_id: String?, ?request_options: Hash[Symbol, untyped]?) -> cost_annotation
|
|
6410
6583
|
def delete: (id: String, ?org_id: String?, ?request_options: Hash[Symbol, untyped]?) -> ok
|
|
6411
6584
|
def get: (?org_id: String?, ?report_id: String?, ?request_options: Hash[Symbol, untyped]?) -> { "annotations" => Array[cost_annotation] }
|
|
@@ -6600,6 +6773,7 @@ module Infrawrench
|
|
|
6600
6773
|
|
|
6601
6774
|
class DeploymentsRunsNamespace
|
|
6602
6775
|
def initialize: (Transport) -> void
|
|
6776
|
+
def cost_impact: (id: String, ?org_id: String?, ?window_days: Integer?, ?cost_basis: change_cost_basis?, ?request_options: Hash[Symbol, untyped]?) -> deployment_cost_impact
|
|
6603
6777
|
def create: (?org_id: String?, ?body: deployment_run_input?, ?request_options: Hash[Symbol, untyped]?) -> { "id" => String }
|
|
6604
6778
|
def get: (id: String, ?org_id: String?, ?request_options: Hash[Symbol, untyped]?) -> deployment_run
|
|
6605
6779
|
def list: (?org_id: String?, ?env: String?, ?limit: Integer?, ?request_options: Hash[Symbol, untyped]?) -> Array[deployment_run]
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: infrawrench-sdk
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.
|
|
4
|
+
version: 1.18.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Infrawrench LLC
|
|
@@ -11,7 +11,7 @@ bindir: bin
|
|
|
11
11
|
cert_chain: []
|
|
12
12
|
date: 2026-08-12 00:00:00.000000000 Z
|
|
13
13
|
dependencies: []
|
|
14
|
-
description: Generated Ruby client for the Infrawrench API (v1.
|
|
14
|
+
description: Generated Ruby client for the Infrawrench API (v1.18.0). Covers the published
|
|
15
15
|
API surface only — operations marked x-internal in the spec are not generated. No
|
|
16
16
|
runtime dependencies.
|
|
17
17
|
email:
|
|
@@ -58,5 +58,5 @@ requirements: []
|
|
|
58
58
|
rubygems_version: 3.5.22
|
|
59
59
|
signing_key:
|
|
60
60
|
specification_version: 4
|
|
61
|
-
summary: Generated Ruby client for the Infrawrench API (v1.
|
|
61
|
+
summary: Generated Ruby client for the Infrawrench API (v1.18.0).
|
|
62
62
|
test_files: []
|