stigg 0.1.0.pre.beta.41 → 0.1.0.pre.beta.42
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/CHANGELOG.md +13 -0
- data/README.md +1 -1
- data/lib/stigg/models/v1_beta/customer_retrieve_governance_params.rb +168 -0
- data/lib/stigg/models/v1_beta/customer_retrieve_governance_response.rb +161 -0
- data/lib/stigg/resources/v1/events.rb +0 -4
- data/lib/stigg/resources/v1_beta/customers.rb +78 -0
- data/lib/stigg/version.rb +1 -1
- data/lib/stigg.rb +2 -4
- data/rbi/stigg/models/v1_beta/customer_retrieve_governance_params.rbi +361 -0
- data/rbi/stigg/models/v1_beta/customer_retrieve_governance_response.rbi +247 -0
- data/rbi/stigg/resources/v1/events.rbi +0 -3
- data/rbi/stigg/resources/v1_beta/customers.rbi +69 -0
- data/sig/stigg/models/v1_beta/customer_retrieve_governance_params.rbs +162 -0
- data/sig/stigg/models/v1_beta/customer_retrieve_governance_response.rbs +113 -0
- data/sig/stigg/resources/v1/events.rbs +0 -2
- data/sig/stigg/resources/v1_beta/customers.rbs +17 -0
- metadata +8 -14
- data/lib/stigg/models/v1/events/beta/customer_retrieve_governance_params.rb +0 -173
- data/lib/stigg/models/v1/events/beta/customer_retrieve_governance_response.rb +0 -166
- data/lib/stigg/resources/v1/events/beta/customers.rb +0 -99
- data/lib/stigg/resources/v1/events/beta.rb +0 -22
- data/rbi/stigg/models/v1/events/beta/customer_retrieve_governance_params.rbi +0 -365
- data/rbi/stigg/models/v1/events/beta/customer_retrieve_governance_response.rbi +0 -251
- data/rbi/stigg/resources/v1/events/beta/customers.rbi +0 -89
- data/rbi/stigg/resources/v1/events/beta.rbi +0 -19
- data/sig/stigg/models/v1/events/beta/customer_retrieve_governance_params.rbs +0 -166
- data/sig/stigg/models/v1/events/beta/customer_retrieve_governance_response.rbs +0 -117
- data/sig/stigg/resources/v1/events/beta/customers.rbs +0 -30
- data/sig/stigg/resources/v1/events/beta.rbs +0 -13
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 2663ec08e29edc72d72ea83c36533df69635192cbc1b2ee51a515f1655eeff10
|
|
4
|
+
data.tar.gz: 5878ac0a46cf891fa542ef614c4ad256738c3d79aae0cf8c4767f4d364b0e5af
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: b70d57ef96bb56ffc8c69ce920f4ba6b011de6226c34c434cec10da555fcbdce53bb57a7a7174a1df12770781eff43512695c8e16154728106e013d27f8e0f67
|
|
7
|
+
data.tar.gz: 29f472a786a265a6f1c67307d58bdab85dc67d18d8b2a909ca8b12ee39c7934f9cc5732b3e97d38a7a8d1123aa267dcc934c200561a5afe27dffaf7c91ea9ec8
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,18 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 0.1.0-beta.42 (2026-07-18)
|
|
4
|
+
|
|
5
|
+
Full Changelog: [v0.1.0-beta.41...v0.1.0-beta.42](https://github.com/stiggio/stigg-ruby/compare/v0.1.0-beta.41...v0.1.0-beta.42)
|
|
6
|
+
|
|
7
|
+
### Features
|
|
8
|
+
|
|
9
|
+
* **stlc:** configurable CI runner and private-production-repo support in workflow templates ([e1adb97](https://github.com/stiggio/stigg-ruby/commit/e1adb97da2b2c6b4bbdcd5ab511bd53b4d6dcef7))
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
### Chores
|
|
13
|
+
|
|
14
|
+
* **api:** move governance endpoint from events/beta to v1_beta namespace ([c1ad229](https://github.com/stiggio/stigg-ruby/commit/c1ad229d3436f542857fddcd7e01eba6e51fd582))
|
|
15
|
+
|
|
3
16
|
## 0.1.0-beta.41 (2026-07-14)
|
|
4
17
|
|
|
5
18
|
Full Changelog: [v0.1.0-beta.40...v0.1.0-beta.41](https://github.com/stiggio/stigg-ruby/compare/v0.1.0-beta.40...v0.1.0-beta.41)
|
data/README.md
CHANGED
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Stigg
|
|
4
|
+
module Models
|
|
5
|
+
module V1Beta
|
|
6
|
+
# @see Stigg::Resources::V1Beta::Customers#retrieve_governance
|
|
7
|
+
class CustomerRetrieveGovernanceParams < Stigg::Internal::Type::BaseModel
|
|
8
|
+
extend Stigg::Internal::Type::RequestParameters::Converter
|
|
9
|
+
include Stigg::Internal::Type::RequestParameters
|
|
10
|
+
|
|
11
|
+
# @!attribute id
|
|
12
|
+
#
|
|
13
|
+
# @return [String]
|
|
14
|
+
required :id, String
|
|
15
|
+
|
|
16
|
+
# @!attribute after
|
|
17
|
+
# Return items that come after this cursor
|
|
18
|
+
#
|
|
19
|
+
# @return [String, nil]
|
|
20
|
+
optional :after, String
|
|
21
|
+
|
|
22
|
+
# @!attribute currency_ids
|
|
23
|
+
# Currency ids to include, repeated per value (e.g. `?currencyIds=credits`). Omit
|
|
24
|
+
# both featureIds and currencyIds for tree mode.
|
|
25
|
+
#
|
|
26
|
+
# @return [Array<String>, nil]
|
|
27
|
+
optional :currency_ids, Stigg::Internal::Type::ArrayOf[String]
|
|
28
|
+
|
|
29
|
+
# @!attribute entity_id_search
|
|
30
|
+
# Case-insensitive substring match on the entity id (`%`/`_` matched literally).
|
|
31
|
+
#
|
|
32
|
+
# @return [String, nil]
|
|
33
|
+
optional :entity_id_search, String
|
|
34
|
+
|
|
35
|
+
# @!attribute entity_type_ids
|
|
36
|
+
# Filter to one or more entity types, repeated per value (e.g.
|
|
37
|
+
# `?entityTypeIds=team&entityTypeIds=user`).
|
|
38
|
+
#
|
|
39
|
+
# @return [Array<String>, nil]
|
|
40
|
+
optional :entity_type_ids, Stigg::Internal::Type::ArrayOf[String]
|
|
41
|
+
|
|
42
|
+
# @!attribute feature_ids
|
|
43
|
+
# Feature ids to include, repeated per value (e.g.
|
|
44
|
+
# `?featureIds=ai-tokens&featureIds=seats`). Omit both featureIds and currencyIds
|
|
45
|
+
# for tree mode — every node in the hierarchy with no usage configuration
|
|
46
|
+
# attached.
|
|
47
|
+
#
|
|
48
|
+
# @return [Array<String>, nil]
|
|
49
|
+
optional :feature_ids, Stigg::Internal::Type::ArrayOf[String]
|
|
50
|
+
|
|
51
|
+
# @!attribute limit
|
|
52
|
+
# Maximum number of items to return
|
|
53
|
+
#
|
|
54
|
+
# @return [Integer, nil]
|
|
55
|
+
optional :limit, Integer
|
|
56
|
+
|
|
57
|
+
# @!attribute min_utilization
|
|
58
|
+
# Only nodes with utilization ≥ this value (e.g. 0.8 for ≥80%, 1 for at/over
|
|
59
|
+
# limit).
|
|
60
|
+
#
|
|
61
|
+
# @return [Float, nil]
|
|
62
|
+
optional :min_utilization, Float
|
|
63
|
+
|
|
64
|
+
# @!attribute order
|
|
65
|
+
# Sort direction: `asc` or `desc` (default `desc`).
|
|
66
|
+
#
|
|
67
|
+
# @return [Symbol, Stigg::Models::V1Beta::CustomerRetrieveGovernanceParams::Order, nil]
|
|
68
|
+
optional :order, enum: -> { Stigg::V1Beta::CustomerRetrieveGovernanceParams::Order }
|
|
69
|
+
|
|
70
|
+
# @!attribute scope
|
|
71
|
+
# Filter by configuration scope: `all` (default), `nodeWide` (`[]` only), or
|
|
72
|
+
# `scoped` (non-empty only).
|
|
73
|
+
#
|
|
74
|
+
# @return [Symbol, Stigg::Models::V1Beta::CustomerRetrieveGovernanceParams::Scope, nil]
|
|
75
|
+
optional :scope, enum: -> { Stigg::V1Beta::CustomerRetrieveGovernanceParams::Scope }
|
|
76
|
+
|
|
77
|
+
# @!attribute sort_by
|
|
78
|
+
# Sort key: `utilization` (default, cross-capability-safe), `currentUsage`,
|
|
79
|
+
# `usageLimit`, `scopeSize`, `id`, or `createdAt`.
|
|
80
|
+
#
|
|
81
|
+
# @return [Symbol, Stigg::Models::V1Beta::CustomerRetrieveGovernanceParams::SortBy, nil]
|
|
82
|
+
optional :sort_by, enum: -> { Stigg::V1Beta::CustomerRetrieveGovernanceParams::SortBy }
|
|
83
|
+
|
|
84
|
+
# @!attribute x_account_id
|
|
85
|
+
#
|
|
86
|
+
# @return [String, nil]
|
|
87
|
+
optional :x_account_id, String
|
|
88
|
+
|
|
89
|
+
# @!attribute x_environment_id
|
|
90
|
+
#
|
|
91
|
+
# @return [String, nil]
|
|
92
|
+
optional :x_environment_id, String
|
|
93
|
+
|
|
94
|
+
# @!method initialize(id:, after: nil, currency_ids: nil, entity_id_search: nil, entity_type_ids: nil, feature_ids: nil, limit: nil, min_utilization: nil, order: nil, scope: nil, sort_by: nil, x_account_id: nil, x_environment_id: nil, request_options: {})
|
|
95
|
+
# Some parameter documentations has been truncated, see
|
|
96
|
+
# {Stigg::Models::V1Beta::CustomerRetrieveGovernanceParams} for more details.
|
|
97
|
+
#
|
|
98
|
+
# @param id [String]
|
|
99
|
+
#
|
|
100
|
+
# @param after [String] Return items that come after this cursor
|
|
101
|
+
#
|
|
102
|
+
# @param currency_ids [Array<String>] Currency ids to include, repeated per value (e.g. `?currencyIds=credits`). Omit
|
|
103
|
+
#
|
|
104
|
+
# @param entity_id_search [String] Case-insensitive substring match on the entity id (`%`/`_` matched literally).
|
|
105
|
+
#
|
|
106
|
+
# @param entity_type_ids [Array<String>] Filter to one or more entity types, repeated per value (e.g. `?entityTypeIds=tea
|
|
107
|
+
#
|
|
108
|
+
# @param feature_ids [Array<String>] Feature ids to include, repeated per value (e.g. `?featureIds=ai-tokens&featureI
|
|
109
|
+
#
|
|
110
|
+
# @param limit [Integer] Maximum number of items to return
|
|
111
|
+
#
|
|
112
|
+
# @param min_utilization [Float] Only nodes with utilization ≥ this value (e.g. 0.8 for ≥80%, 1 for at/over limit
|
|
113
|
+
#
|
|
114
|
+
# @param order [Symbol, Stigg::Models::V1Beta::CustomerRetrieveGovernanceParams::Order] Sort direction: `asc` or `desc` (default `desc`).
|
|
115
|
+
#
|
|
116
|
+
# @param scope [Symbol, Stigg::Models::V1Beta::CustomerRetrieveGovernanceParams::Scope] Filter by configuration scope: `all` (default), `nodeWide` (`[]` only), or `scop
|
|
117
|
+
#
|
|
118
|
+
# @param sort_by [Symbol, Stigg::Models::V1Beta::CustomerRetrieveGovernanceParams::SortBy] Sort key: `utilization` (default, cross-capability-safe), `currentUsage`, `usage
|
|
119
|
+
#
|
|
120
|
+
# @param x_account_id [String]
|
|
121
|
+
#
|
|
122
|
+
# @param x_environment_id [String]
|
|
123
|
+
#
|
|
124
|
+
# @param request_options [Stigg::RequestOptions, Hash{Symbol=>Object}]
|
|
125
|
+
|
|
126
|
+
# Sort direction: `asc` or `desc` (default `desc`).
|
|
127
|
+
module Order
|
|
128
|
+
extend Stigg::Internal::Type::Enum
|
|
129
|
+
|
|
130
|
+
ASC = :asc
|
|
131
|
+
DESC = :desc
|
|
132
|
+
|
|
133
|
+
# @!method self.values
|
|
134
|
+
# @return [Array<Symbol>]
|
|
135
|
+
end
|
|
136
|
+
|
|
137
|
+
# Filter by configuration scope: `all` (default), `nodeWide` (`[]` only), or
|
|
138
|
+
# `scoped` (non-empty only).
|
|
139
|
+
module Scope
|
|
140
|
+
extend Stigg::Internal::Type::Enum
|
|
141
|
+
|
|
142
|
+
ALL = :all
|
|
143
|
+
NODE_WIDE = :nodeWide
|
|
144
|
+
SCOPED = :scoped
|
|
145
|
+
|
|
146
|
+
# @!method self.values
|
|
147
|
+
# @return [Array<Symbol>]
|
|
148
|
+
end
|
|
149
|
+
|
|
150
|
+
# Sort key: `utilization` (default, cross-capability-safe), `currentUsage`,
|
|
151
|
+
# `usageLimit`, `scopeSize`, `id`, or `createdAt`.
|
|
152
|
+
module SortBy
|
|
153
|
+
extend Stigg::Internal::Type::Enum
|
|
154
|
+
|
|
155
|
+
UTILIZATION = :utilization
|
|
156
|
+
CURRENT_USAGE = :currentUsage
|
|
157
|
+
USAGE_LIMIT = :usageLimit
|
|
158
|
+
SCOPE_SIZE = :scopeSize
|
|
159
|
+
ID = :id
|
|
160
|
+
CREATED_AT = :createdAt
|
|
161
|
+
|
|
162
|
+
# @!method self.values
|
|
163
|
+
# @return [Array<Symbol>]
|
|
164
|
+
end
|
|
165
|
+
end
|
|
166
|
+
end
|
|
167
|
+
end
|
|
168
|
+
end
|
|
@@ -0,0 +1,161 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
module Stigg
|
|
4
|
+
module Models
|
|
5
|
+
module V1Beta
|
|
6
|
+
# @see Stigg::Resources::V1Beta::Customers#retrieve_governance
|
|
7
|
+
class CustomerRetrieveGovernanceResponse < Stigg::Internal::Type::BaseModel
|
|
8
|
+
# @!attribute data
|
|
9
|
+
#
|
|
10
|
+
# @return [Array<Stigg::Models::V1Beta::CustomerRetrieveGovernanceResponse::Data>]
|
|
11
|
+
required :data,
|
|
12
|
+
-> { Stigg::Internal::Type::ArrayOf[Stigg::Models::V1Beta::CustomerRetrieveGovernanceResponse::Data] }
|
|
13
|
+
|
|
14
|
+
# @!attribute pagination
|
|
15
|
+
#
|
|
16
|
+
# @return [Stigg::Models::V1Beta::CustomerRetrieveGovernanceResponse::Pagination]
|
|
17
|
+
required :pagination, -> { Stigg::Models::V1Beta::CustomerRetrieveGovernanceResponse::Pagination }
|
|
18
|
+
|
|
19
|
+
# @!method initialize(data:, pagination:)
|
|
20
|
+
# Paginated list of governance tree nodes, each with its usage configuration and
|
|
21
|
+
# current usage.
|
|
22
|
+
#
|
|
23
|
+
# @param data [Array<Stigg::Models::V1Beta::CustomerRetrieveGovernanceResponse::Data>]
|
|
24
|
+
# @param pagination [Stigg::Models::V1Beta::CustomerRetrieveGovernanceResponse::Pagination]
|
|
25
|
+
|
|
26
|
+
class Data < Stigg::Internal::Type::BaseModel
|
|
27
|
+
# @!attribute cadence
|
|
28
|
+
# Usage-reset cadence as an ISO-8601 single-unit duration, e.g. `P1M`, `P30D`,
|
|
29
|
+
# `PT1M`; `null` when the node has no usage configuration.
|
|
30
|
+
#
|
|
31
|
+
# @return [String, nil]
|
|
32
|
+
required :cadence, String, nil?: true
|
|
33
|
+
|
|
34
|
+
# @!attribute current_usage
|
|
35
|
+
# Usage consumed in the current cadence period (may lag the live counter by a
|
|
36
|
+
# short interval).
|
|
37
|
+
#
|
|
38
|
+
# @return [Float, nil]
|
|
39
|
+
required :current_usage, Float, api_name: :currentUsage, nil?: true
|
|
40
|
+
|
|
41
|
+
# @!attribute entity_id
|
|
42
|
+
# External id of the entity at this node.
|
|
43
|
+
#
|
|
44
|
+
# @return [String]
|
|
45
|
+
required :entity_id, String, api_name: :entityId
|
|
46
|
+
|
|
47
|
+
# @!attribute entity_type_id
|
|
48
|
+
# External id of the entity type (e.g. `team`, `user`).
|
|
49
|
+
#
|
|
50
|
+
# @return [String]
|
|
51
|
+
required :entity_type_id, String, api_name: :entityTypeId
|
|
52
|
+
|
|
53
|
+
# @!attribute parent_id
|
|
54
|
+
# External id of the parent entity in the tree; `null` for a root. Use it to
|
|
55
|
+
# rebuild the tree.
|
|
56
|
+
#
|
|
57
|
+
# @return [String, nil]
|
|
58
|
+
required :parent_id, String, api_name: :parentId, nil?: true
|
|
59
|
+
|
|
60
|
+
# @!attribute scope_entity_ids
|
|
61
|
+
# The configuration scope (entity ids). Empty is the node-wide configuration; a
|
|
62
|
+
# non-empty set is a dimension-scoped sub-configuration.
|
|
63
|
+
#
|
|
64
|
+
# @return [Array<String>]
|
|
65
|
+
required :scope_entity_ids, Stigg::Internal::Type::ArrayOf[String], api_name: :scopeEntityIds
|
|
66
|
+
|
|
67
|
+
# @!attribute usage_limit
|
|
68
|
+
# Hard usage limit for this node per cadence period.
|
|
69
|
+
#
|
|
70
|
+
# @return [Float, nil]
|
|
71
|
+
required :usage_limit, Float, api_name: :usageLimit, nil?: true
|
|
72
|
+
|
|
73
|
+
# @!attribute usage_period_end
|
|
74
|
+
# Exclusive end of the cadence period — when usage resets; `null` once the period
|
|
75
|
+
# has rolled over.
|
|
76
|
+
#
|
|
77
|
+
# @return [Time, nil]
|
|
78
|
+
required :usage_period_end, Time, api_name: :usagePeriodEnd, nil?: true
|
|
79
|
+
|
|
80
|
+
# @!attribute usage_period_start
|
|
81
|
+
# Start of the cadence period the usage snapshot belongs to; `null` once the
|
|
82
|
+
# period has rolled over.
|
|
83
|
+
#
|
|
84
|
+
# @return [Time, nil]
|
|
85
|
+
required :usage_period_start, Time, api_name: :usagePeriodStart, nil?: true
|
|
86
|
+
|
|
87
|
+
# @!attribute utilization
|
|
88
|
+
# `currentUsage / usageLimit` (1 when usageLimit is 0 — always at limit). The
|
|
89
|
+
# cross-capability-safe sort key.
|
|
90
|
+
#
|
|
91
|
+
# @return [Float, nil]
|
|
92
|
+
required :utilization, Float, nil?: true
|
|
93
|
+
|
|
94
|
+
# @!attribute currency_id
|
|
95
|
+
# The metered currency ID (present when the configured capability is a credit
|
|
96
|
+
# currency).
|
|
97
|
+
#
|
|
98
|
+
# @return [String, nil]
|
|
99
|
+
optional :currency_id, String, api_name: :currencyId
|
|
100
|
+
|
|
101
|
+
# @!attribute feature_id
|
|
102
|
+
# The metered feature ID (present when the configured capability is a feature).
|
|
103
|
+
#
|
|
104
|
+
# @return [String, nil]
|
|
105
|
+
optional :feature_id, String, api_name: :featureId
|
|
106
|
+
|
|
107
|
+
# @!method initialize(cadence:, current_usage:, entity_id:, entity_type_id:, parent_id:, scope_entity_ids:, usage_limit:, usage_period_end:, usage_period_start:, utilization:, currency_id: nil, feature_id: nil)
|
|
108
|
+
# Some parameter documentations has been truncated, see
|
|
109
|
+
# {Stigg::Models::V1Beta::CustomerRetrieveGovernanceResponse::Data} for more
|
|
110
|
+
# details.
|
|
111
|
+
#
|
|
112
|
+
# A node of the governance hierarchy tree with its usage configuration (limit,
|
|
113
|
+
# cadence, scope) and current usage. Usage is read from a periodically-refreshed
|
|
114
|
+
# read model and may lag the live counter by a short interval; it never gates
|
|
115
|
+
# access.
|
|
116
|
+
#
|
|
117
|
+
# @param cadence [String, nil] Usage-reset cadence as an ISO-8601 single-unit duration, e.g. `P1M`, `P30D`, `PT
|
|
118
|
+
#
|
|
119
|
+
# @param current_usage [Float, nil] Usage consumed in the current cadence period (may lag the live counter by a shor
|
|
120
|
+
#
|
|
121
|
+
# @param entity_id [String] External id of the entity at this node.
|
|
122
|
+
#
|
|
123
|
+
# @param entity_type_id [String] External id of the entity type (e.g. `team`, `user`).
|
|
124
|
+
#
|
|
125
|
+
# @param parent_id [String, nil] External id of the parent entity in the tree; `null` for a root. Use it to rebui
|
|
126
|
+
#
|
|
127
|
+
# @param scope_entity_ids [Array<String>] The configuration scope (entity ids). Empty is the node-wide configuration; a no
|
|
128
|
+
#
|
|
129
|
+
# @param usage_limit [Float, nil] Hard usage limit for this node per cadence period.
|
|
130
|
+
#
|
|
131
|
+
# @param usage_period_end [Time, nil] Exclusive end of the cadence period — when usage resets; `null` once the period
|
|
132
|
+
#
|
|
133
|
+
# @param usage_period_start [Time, nil] Start of the cadence period the usage snapshot belongs to; `null` once the perio
|
|
134
|
+
#
|
|
135
|
+
# @param utilization [Float, nil] `currentUsage / usageLimit` (1 when usageLimit is 0 — always at limit). The cros
|
|
136
|
+
#
|
|
137
|
+
# @param currency_id [String] The metered currency ID (present when the configured capability is a credit curr
|
|
138
|
+
#
|
|
139
|
+
# @param feature_id [String] The metered feature ID (present when the configured capability is a feature).
|
|
140
|
+
end
|
|
141
|
+
|
|
142
|
+
# @see Stigg::Models::V1Beta::CustomerRetrieveGovernanceResponse#pagination
|
|
143
|
+
class Pagination < Stigg::Internal::Type::BaseModel
|
|
144
|
+
# @!attribute next_
|
|
145
|
+
# Cursor for fetching the next page of results, or null if no additional pages
|
|
146
|
+
# exist
|
|
147
|
+
#
|
|
148
|
+
# @return [String, nil]
|
|
149
|
+
required :next_, String, api_name: :next, nil?: true
|
|
150
|
+
|
|
151
|
+
# @!method initialize(next_:)
|
|
152
|
+
# Some parameter documentations has been truncated, see
|
|
153
|
+
# {Stigg::Models::V1Beta::CustomerRetrieveGovernanceResponse::Pagination} for more
|
|
154
|
+
# details.
|
|
155
|
+
#
|
|
156
|
+
# @param next_ [String, nil] Cursor for fetching the next page of results, or null if no additional pages exi
|
|
157
|
+
end
|
|
158
|
+
end
|
|
159
|
+
end
|
|
160
|
+
end
|
|
161
|
+
end
|
|
@@ -8,9 +8,6 @@ module Stigg
|
|
|
8
8
|
# @return [Stigg::Resources::V1::Events::DataExport]
|
|
9
9
|
attr_reader :data_export
|
|
10
10
|
|
|
11
|
-
# @return [Stigg::Resources::V1::Events::Beta]
|
|
12
|
-
attr_reader :beta
|
|
13
|
-
|
|
14
11
|
# Some parameter documentations has been truncated, see
|
|
15
12
|
# {Stigg::Models::V1::EventEstimateCostParams} for more details.
|
|
16
13
|
#
|
|
@@ -88,7 +85,6 @@ module Stigg
|
|
|
88
85
|
def initialize(client:)
|
|
89
86
|
@client = client
|
|
90
87
|
@data_export = Stigg::Resources::V1::Events::DataExport.new(client: client)
|
|
91
|
-
@beta = Stigg::Resources::V1::Events::Beta.new(client: client)
|
|
92
88
|
end
|
|
93
89
|
end
|
|
94
90
|
end
|
|
@@ -13,6 +13,84 @@ module Stigg
|
|
|
13
13
|
# @return [Stigg::Resources::V1Beta::Customers::Assignments]
|
|
14
14
|
attr_reader :assignments
|
|
15
15
|
|
|
16
|
+
# Some parameter documentations has been truncated, see
|
|
17
|
+
# {Stigg::Models::V1Beta::CustomerRetrieveGovernanceParams} for more details.
|
|
18
|
+
#
|
|
19
|
+
# Queries the customer's governance hierarchy tree, returning a cursor-paginated
|
|
20
|
+
# list of nodes with their usage configuration (limit, cadence, scope) and current
|
|
21
|
+
# usage, sortable and filterable by usage. Each node carries `parentId` so the
|
|
22
|
+
# tree can be rebuilt client-side. Usage is read from a periodically-refreshed
|
|
23
|
+
# read model and never gates access.
|
|
24
|
+
#
|
|
25
|
+
# @overload retrieve_governance(id, after: nil, currency_ids: nil, entity_id_search: nil, entity_type_ids: nil, feature_ids: nil, limit: nil, min_utilization: nil, order: nil, scope: nil, sort_by: nil, x_account_id: nil, x_environment_id: nil, request_options: {})
|
|
26
|
+
#
|
|
27
|
+
# @param id [String] Path param: The customer ID.
|
|
28
|
+
#
|
|
29
|
+
# @param after [String] Query param: Return items that come after this cursor
|
|
30
|
+
#
|
|
31
|
+
# @param currency_ids [Array<String>] Query param: Currency ids to include, repeated per value (e.g. `?currencyIds=cre
|
|
32
|
+
#
|
|
33
|
+
# @param entity_id_search [String] Query param: Case-insensitive substring match on the entity id (`%`/`_` matched
|
|
34
|
+
#
|
|
35
|
+
# @param entity_type_ids [Array<String>] Query param: Filter to one or more entity types, repeated per value (e.g. `?enti
|
|
36
|
+
#
|
|
37
|
+
# @param feature_ids [Array<String>] Query param: Feature ids to include, repeated per value (e.g. `?featureIds=ai-to
|
|
38
|
+
#
|
|
39
|
+
# @param limit [Integer] Query param: Maximum number of items to return
|
|
40
|
+
#
|
|
41
|
+
# @param min_utilization [Float] Query param: Only nodes with utilization ≥ this value (e.g. 0.8 for ≥80%, 1 for
|
|
42
|
+
#
|
|
43
|
+
# @param order [Symbol, Stigg::Models::V1Beta::CustomerRetrieveGovernanceParams::Order] Query param: Sort direction: `asc` or `desc` (default `desc`).
|
|
44
|
+
#
|
|
45
|
+
# @param scope [Symbol, Stigg::Models::V1Beta::CustomerRetrieveGovernanceParams::Scope] Query param: Filter by configuration scope: `all` (default), `nodeWide` (`[]` on
|
|
46
|
+
#
|
|
47
|
+
# @param sort_by [Symbol, Stigg::Models::V1Beta::CustomerRetrieveGovernanceParams::SortBy] Query param: Sort key: `utilization` (default, cross-capability-safe), `currentU
|
|
48
|
+
#
|
|
49
|
+
# @param x_account_id [String] Header param: Account ID — optional when authenticating with a user JWT (Bearer
|
|
50
|
+
#
|
|
51
|
+
# @param x_environment_id [String] Header param: Environment ID — required when authenticating with a user JWT (Bea
|
|
52
|
+
#
|
|
53
|
+
# @param request_options [Stigg::RequestOptions, Hash{Symbol=>Object}, nil]
|
|
54
|
+
#
|
|
55
|
+
# @return [Stigg::Models::V1Beta::CustomerRetrieveGovernanceResponse]
|
|
56
|
+
#
|
|
57
|
+
# @see Stigg::Models::V1Beta::CustomerRetrieveGovernanceParams
|
|
58
|
+
def retrieve_governance(id, params = {})
|
|
59
|
+
query_params =
|
|
60
|
+
[
|
|
61
|
+
:after,
|
|
62
|
+
:currency_ids,
|
|
63
|
+
:entity_id_search,
|
|
64
|
+
:entity_type_ids,
|
|
65
|
+
:feature_ids,
|
|
66
|
+
:limit,
|
|
67
|
+
:min_utilization,
|
|
68
|
+
:order,
|
|
69
|
+
:scope,
|
|
70
|
+
:sort_by
|
|
71
|
+
]
|
|
72
|
+
parsed, options = Stigg::V1Beta::CustomerRetrieveGovernanceParams.dump_request(params)
|
|
73
|
+
query = Stigg::Internal::Util.encode_query_params(parsed.slice(*query_params))
|
|
74
|
+
@client.request(
|
|
75
|
+
method: :get,
|
|
76
|
+
path: ["api/v1-beta/customers/%1$s/governance", id],
|
|
77
|
+
query: query.transform_keys(
|
|
78
|
+
currency_ids: "currencyIds",
|
|
79
|
+
entity_id_search: "entityIdSearch",
|
|
80
|
+
entity_type_ids: "entityTypeIds",
|
|
81
|
+
feature_ids: "featureIds",
|
|
82
|
+
min_utilization: "minUtilization",
|
|
83
|
+
sort_by: "sortBy"
|
|
84
|
+
),
|
|
85
|
+
headers: parsed.except(*query_params).transform_keys(
|
|
86
|
+
x_account_id: "x-account-id",
|
|
87
|
+
x_environment_id: "x-environment-id"
|
|
88
|
+
),
|
|
89
|
+
model: Stigg::Models::V1Beta::CustomerRetrieveGovernanceResponse,
|
|
90
|
+
options: options
|
|
91
|
+
)
|
|
92
|
+
end
|
|
93
|
+
|
|
16
94
|
# @api private
|
|
17
95
|
#
|
|
18
96
|
# @param client [Stigg::Client]
|
data/lib/stigg/version.rb
CHANGED
data/lib/stigg.rb
CHANGED
|
@@ -140,8 +140,6 @@ require_relative "stigg/models/v1/event_estimate_cost_params"
|
|
|
140
140
|
require_relative "stigg/models/v1/event_estimate_cost_response"
|
|
141
141
|
require_relative "stigg/models/v1/event_report_params"
|
|
142
142
|
require_relative "stigg/models/v1/event_report_response"
|
|
143
|
-
require_relative "stigg/models/v1/events/beta/customer_retrieve_governance_params"
|
|
144
|
-
require_relative "stigg/models/v1/events/beta/customer_retrieve_governance_response"
|
|
145
143
|
require_relative "stigg/models/v1/events/data_export/destination_create_params"
|
|
146
144
|
require_relative "stigg/models/v1/events/data_export/destination_create_response"
|
|
147
145
|
require_relative "stigg/models/v1/events/data_export/destination_delete_params"
|
|
@@ -223,6 +221,8 @@ require_relative "stigg/models/v1/usage_history_params"
|
|
|
223
221
|
require_relative "stigg/models/v1/usage_history_response"
|
|
224
222
|
require_relative "stigg/models/v1/usage_report_params"
|
|
225
223
|
require_relative "stigg/models/v1/usage_report_response"
|
|
224
|
+
require_relative "stigg/models/v1_beta/customer_retrieve_governance_params"
|
|
225
|
+
require_relative "stigg/models/v1_beta/customer_retrieve_governance_response"
|
|
226
226
|
require_relative "stigg/models/v1_beta/customers/assignment_list_params"
|
|
227
227
|
require_relative "stigg/models/v1_beta/customers/assignment_list_response"
|
|
228
228
|
require_relative "stigg/models/v1_beta/customers/assignment_upsert_params"
|
|
@@ -257,8 +257,6 @@ require_relative "stigg/resources/v1/customers/integrations"
|
|
|
257
257
|
require_relative "stigg/resources/v1/customers/payment_method"
|
|
258
258
|
require_relative "stigg/resources/v1/customers/promotional_entitlements"
|
|
259
259
|
require_relative "stigg/resources/v1/events"
|
|
260
|
-
require_relative "stigg/resources/v1/events/beta"
|
|
261
|
-
require_relative "stigg/resources/v1/events/beta/customers"
|
|
262
260
|
require_relative "stigg/resources/v1/events/data_export"
|
|
263
261
|
require_relative "stigg/resources/v1/events/data_export/destinations"
|
|
264
262
|
require_relative "stigg/resources/v1/features"
|