zitadel-client 1.5.1 → 1.6.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.
Files changed (56) hide show
  1. checksums.yaml +4 -4
  2. data/lib/zitadel/client/api/action_service_api.rb +670 -0
  3. data/lib/zitadel/client/api/settings_service_api.rb +125 -0
  4. data/lib/zitadel/client/api/web_key_service_api.rb +273 -0
  5. data/lib/zitadel/client/models/action_service_beta_condition.rb +257 -0
  6. data/lib/zitadel/client/models/action_service_beta_create_target_response.rb +251 -0
  7. data/lib/zitadel/client/models/action_service_beta_delete_target_response.rb +231 -0
  8. data/lib/zitadel/client/models/action_service_beta_event_execution.rb +307 -0
  9. data/lib/zitadel/client/models/action_service_beta_execution.rb +262 -0
  10. data/lib/zitadel/client/models/action_service_beta_execution_target_type.rb +240 -0
  11. data/lib/zitadel/client/models/action_service_beta_function_execution.rb +230 -0
  12. data/lib/zitadel/client/models/action_service_beta_get_target_response.rb +230 -0
  13. data/lib/zitadel/client/models/action_service_beta_in_target_i_ds_filter.rb +233 -0
  14. data/lib/zitadel/client/models/action_service_beta_list_execution_functions_response.rb +232 -0
  15. data/lib/zitadel/client/models/action_service_beta_list_execution_methods_response.rb +232 -0
  16. data/lib/zitadel/client/models/action_service_beta_list_execution_services_response.rb +232 -0
  17. data/lib/zitadel/client/models/action_service_beta_list_executions_response.rb +241 -0
  18. data/lib/zitadel/client/models/action_service_beta_list_targets_response.rb +241 -0
  19. data/lib/zitadel/client/models/action_service_beta_pagination_request.rb +251 -0
  20. data/lib/zitadel/client/models/action_service_beta_pagination_response.rb +241 -0
  21. data/lib/zitadel/client/models/action_service_beta_r_e_s_t_call.rb +231 -0
  22. data/lib/zitadel/client/models/action_service_beta_r_e_s_t_webhook.rb +231 -0
  23. data/lib/zitadel/client/models/action_service_beta_request_execution.rb +307 -0
  24. data/lib/zitadel/client/models/action_service_beta_response_execution.rb +307 -0
  25. data/lib/zitadel/client/models/action_service_beta_set_execution_response.rb +231 -0
  26. data/lib/zitadel/client/models/action_service_beta_target.rb +315 -0
  27. data/lib/zitadel/client/models/action_service_beta_target_field_name.rb +48 -0
  28. data/lib/zitadel/client/models/action_service_beta_target_name_filter.rb +283 -0
  29. data/lib/zitadel/client/models/action_service_beta_target_search_filter.rb +239 -0
  30. data/lib/zitadel/client/models/action_service_beta_text_filter_method.rb +47 -0
  31. data/lib/zitadel/client/models/action_service_beta_update_target_response.rb +241 -0
  32. data/lib/zitadel/client/models/action_service_create_target_request.rb +332 -0
  33. data/lib/zitadel/client/models/action_service_list_targets_request.rb +275 -0
  34. data/lib/zitadel/client/models/action_service_protobuf_any.rb +230 -0
  35. data/lib/zitadel/client/models/action_service_rpc_status.rb +250 -0
  36. data/lib/zitadel/client/models/action_service_set_execution_request.rb +242 -0
  37. data/lib/zitadel/client/models/action_service_update_target_request.rb +342 -0
  38. data/lib/zitadel/client/models/web_key_service_beta_activate_web_key_response.rb +231 -0
  39. data/lib/zitadel/client/models/web_key_service_beta_create_web_key_response.rb +241 -0
  40. data/lib/zitadel/client/models/web_key_service_beta_delete_web_key_response.rb +231 -0
  41. data/lib/zitadel/client/models/web_key_service_beta_e_c_d_s_a.rb +254 -0
  42. data/lib/zitadel/client/models/web_key_service_beta_e_c_d_s_a_curve.rb +43 -0
  43. data/lib/zitadel/client/models/web_key_service_beta_list_web_keys_response.rb +232 -0
  44. data/lib/zitadel/client/models/web_key_service_beta_r_s_a.rb +265 -0
  45. data/lib/zitadel/client/models/web_key_service_beta_r_s_a_bits.rb +43 -0
  46. data/lib/zitadel/client/models/web_key_service_beta_r_s_a_hasher.rb +43 -0
  47. data/lib/zitadel/client/models/web_key_service_beta_state.rb +44 -0
  48. data/lib/zitadel/client/models/web_key_service_beta_web_key.rb +289 -0
  49. data/lib/zitadel/client/models/web_key_service_create_web_key_request.rb +248 -0
  50. data/lib/zitadel/client/models/web_key_service_protobuf_any.rb +230 -0
  51. data/lib/zitadel/client/models/web_key_service_rpc_status.rb +250 -0
  52. data/lib/zitadel/client/version.rb +1 -1
  53. data/lib/zitadel/client/zitadel.rb +9 -5
  54. data/sig/lib.rbs +2 -0
  55. metadata +50 -2
  56. data/lib/zitadel/client/api/settings_api.rb +0 -147
@@ -0,0 +1,250 @@
1
+ =begin
2
+ #Zitadel SDK
3
+
4
+ #The Zitadel SDK is a convenience wrapper around the Zitadel APIs to assist you in integrating with your Zitadel environment. This SDK enables you to handle resources, settings, and configurations within the Zitadel platform.
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.12.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Zitadel::Client::Models
17
+ class WebKeyServiceRpcStatus
18
+ attr_accessor :code
19
+
20
+ attr_accessor :message
21
+
22
+ attr_accessor :details
23
+
24
+ # Attribute mapping from ruby-style variable name to JSON key.
25
+ def self.attribute_map
26
+ {
27
+ :'code' => :'code',
28
+ :'message' => :'message',
29
+ :'details' => :'details'
30
+ }
31
+ end
32
+
33
+ # Returns attribute mapping this model knows about
34
+ def self.acceptable_attribute_map
35
+ attribute_map
36
+ end
37
+
38
+ # Returns all the JSON keys this model knows about
39
+ def self.acceptable_attributes
40
+ acceptable_attribute_map.values
41
+ end
42
+
43
+ # Attribute type mapping.
44
+ def self.openapi_types
45
+ {
46
+ :'code' => :'Integer',
47
+ :'message' => :'String',
48
+ :'details' => :'Array<WebKeyServiceProtobufAny>'
49
+ }
50
+ end
51
+
52
+ # List of attributes with nullable: true
53
+ def self.openapi_nullable
54
+ Set.new([
55
+ ])
56
+ end
57
+
58
+ # Initializes the object
59
+ # @param [Hash] attributes Models attributes in the form of hash
60
+ def initialize(attributes = {})
61
+ if (!attributes.is_a?(Hash))
62
+ # MODIFIED: Updated class name in error message
63
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Zitadel::Client::Models::WebKeyServiceRpcStatus` initialize method"
64
+ end
65
+
66
+ # check to see if the attribute exists and convert string to symbol for hash key
67
+ acceptable_attribute_map = self.class.acceptable_attribute_map
68
+ attributes = attributes.each_with_object({}) { |(k, v), h|
69
+ if (!acceptable_attribute_map.key?(k.to_sym))
70
+ # MODIFIED: Updated class name in error message
71
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Zitadel::Client::Models::WebKeyServiceRpcStatus`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
72
+ end
73
+ h[k.to_sym] = v
74
+ }
75
+
76
+ if attributes.key?(:'code')
77
+ self.code = attributes[:'code']
78
+ end
79
+
80
+ if attributes.key?(:'message')
81
+ self.message = attributes[:'message']
82
+ end
83
+
84
+ if attributes.key?(:'details')
85
+ if (value = attributes[:'details']).is_a?(Array)
86
+ self.details = value
87
+ end
88
+ end
89
+ end
90
+
91
+ # Show invalid properties with the reasons. Usually used together with valid?
92
+ # @return Array for valid properties with the reasons
93
+ def list_invalid_properties
94
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
95
+ invalid_properties = Array.new
96
+ invalid_properties
97
+ end
98
+
99
+ # Check to see if the all the properties in the model are valid
100
+ # @return true if the model is valid
101
+ def valid?
102
+ warn '[DEPRECATED] the `valid?` method is obsolete'
103
+ true
104
+ end
105
+
106
+ # Checks equality by comparing each attribute.
107
+ # @param [Object] Object to be compared
108
+ def ==(o)
109
+ return true if self.equal?(o)
110
+ self.class == o.class &&
111
+ code == o.code &&
112
+ message == o.message &&
113
+ details == o.details
114
+ end
115
+
116
+ # @see the `==` method
117
+ # @param [Object] Object to be compared
118
+ def eql?(o)
119
+ self == o
120
+ end
121
+
122
+ # Calculates hash code according to all attributes.
123
+ # @return [Integer] Hash code
124
+ def hash
125
+ [code, message, details].hash
126
+ end
127
+
128
+ # Builds the object from hash
129
+ # @param [Hash] attributes Models attributes in the form of hash
130
+ # @return [Object] Returns the model itself
131
+ def self.build_from_hash(attributes)
132
+ return nil unless attributes.is_a?(Hash)
133
+ attributes = attributes.transform_keys(&:to_sym)
134
+ transformed_hash = {}
135
+ openapi_types.each_pair do |key, type|
136
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
137
+ transformed_hash["#{key}"] = nil
138
+ elsif type =~ /\AArray<(.*)>/i
139
+ # check to ensure the input is an array given that the attribute
140
+ # is documented as an array but the input is not
141
+ if attributes[attribute_map[key]].is_a?(Array)
142
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
143
+ end
144
+ elsif !attributes[attribute_map[key]].nil?
145
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
146
+ end
147
+ end
148
+ new(transformed_hash) # `new` will call the initialize method of the specific model class.
149
+ end
150
+
151
+ # Deserializes the data based on type
152
+ # @param string type Data type
153
+ # @param string value Value to be deserialized
154
+ # @return [Object] Deserialized data
155
+ def self._deserialize(type, value)
156
+ case type.to_sym
157
+ when :Time
158
+ Time.parse(value)
159
+ when :Date
160
+ Date.parse(value)
161
+ when :String
162
+ value.to_s
163
+ when :Integer
164
+ value.to_i
165
+ when :Float
166
+ value.to_f
167
+ when :Boolean
168
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
169
+ true
170
+ else
171
+ false
172
+ end
173
+ when :Object
174
+ # generic object (usually a Hash), return directly
175
+ value
176
+ when /\AArray<(?<inner_type>.+)>\z/
177
+ inner_type = Regexp.last_match[:inner_type]
178
+ value.map { |v| _deserialize(inner_type, v) }
179
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
180
+ k_type = Regexp.last_match[:k_type]
181
+ v_type = Regexp.last_match[:v_type]
182
+ {}.tap do |hash|
183
+ value.each do |k, v|
184
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
185
+ end
186
+ end
187
+ else # model
188
+ # models (e.g. Pet) or oneOf/anyOf constructs that resolve to a model name
189
+ # MODIFIED: Ensure model is looked up in the Models namespace
190
+ # 'type' here is expected to be the simple class name (e.g., "User", "OrderDetails")
191
+ klass = Zitadel::Client::Models.const_get(type)
192
+ # The `klass.build` method is for oneOf/anyOf types (defined in partial_oneof_module.mustache / partial_anyof_module.mustache)
193
+ # The `klass.build_from_hash` is for regular model types (defined in this base_object.mustache itself)
194
+ if klass.respond_to?(:openapi_one_of) || klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_allOf)
195
+ klass.build(value) # For oneOf/anyOf/allOf, delegate to their specific build method
196
+ else
197
+ klass.build_from_hash(value) # For regular models
198
+ end
199
+ end
200
+ end
201
+
202
+ # Returns the string representation of the object
203
+ # @return [String] String presentation of the object
204
+ def to_s
205
+ to_hash.to_s
206
+ end
207
+
208
+ # to_body is an alias to to_hash (backward compatibility)
209
+ # @return [Hash] Returns the object in the form of hash
210
+ def to_body
211
+ to_hash
212
+ end
213
+
214
+ # Returns the object in the form of hash
215
+ # @return [Hash] Returns the object in the form of hash
216
+ def to_hash
217
+ hash = {} # Calls super.to_hash if parent exists
218
+ self.class.attribute_map.each_pair do |attr, param|
219
+ value = self.send(attr)
220
+ if value.nil?
221
+ is_nullable = self.class.openapi_nullable.include?(attr)
222
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
223
+ end
224
+
225
+ hash[param] = _to_hash(value)
226
+ end
227
+ hash
228
+ end
229
+
230
+ # Outputs non-array value in the form of hash
231
+ # For object, use to_hash. Otherwise, just return the value
232
+ # @param [Object] value Any valid value
233
+ # @return [Hash] Returns the value in the form of hash
234
+ def _to_hash(value)
235
+ if value.is_a?(Array)
236
+ value.compact.map { |v| _to_hash(v) }
237
+ elsif value.is_a?(Hash)
238
+ {}.tap do |hash|
239
+ value.each { |k, v| hash[k] = _to_hash(v) }
240
+ end
241
+ elsif value.respond_to? :to_hash
242
+ value.to_hash
243
+ else
244
+ value
245
+ end
246
+ end
247
+
248
+ end
249
+
250
+ end
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Zitadel
4
4
  module Client
5
- VERSION = '1.5.1'
5
+ VERSION = '1.6.0'
6
6
  end
7
7
  end
@@ -7,19 +7,21 @@ module Zitadel
7
7
  # Initializes and configures the SDK with the provided authentication strategy.
8
8
  # Sets up service APIs for interacting with various Zitadel features.
9
9
  class Zitadel
10
- attr_reader :features,
10
+ attr_reader :actions,
11
+ :features,
11
12
  :idps,
12
13
  :oidc,
13
14
  :organizations,
15
+ :saml,
14
16
  :sessions,
15
17
  :settings,
16
18
  :users,
17
- :saml
19
+ :webkeys
18
20
 
19
21
  # Initialize the Zitadel SDK.
20
22
  #
21
23
  # @param authenticator [Authenticator] the authentication strategy to use
22
- # rubocop:disable Metrics/MethodLength
24
+ # rubocop:disable Metrics/MethodLength, Metrics/AbcSize
23
25
  def initialize(authenticator)
24
26
  # noinspection RubyArgCount
25
27
  @configuration = Configuration.new(authenticator)
@@ -27,17 +29,19 @@ module Zitadel
27
29
 
28
30
  client = ApiClient.new(@configuration)
29
31
 
32
+ @actions = Api::ActionServiceApi.new(client)
30
33
  @features = Api::FeatureServiceApi.new(client)
31
34
  @idps = Api::IdentityProviderServiceApi.new(client)
32
35
  @oidc = Api::OIDCServiceApi.new(client)
33
36
  @organizations = Api::OrganizationServiceApi.new(client)
37
+ @saml = Api::SAMLServiceApi.new(client)
34
38
  @sessions = Api::SessionServiceApi.new(client)
35
39
  @settings = Api::SettingsServiceApi.new(client)
36
40
  @users = Api::UserServiceApi.new(client)
37
- @saml = Api::SAMLServiceApi.new(client)
41
+ @webkeys = Api::WebKeyServiceApi.new(client)
38
42
  end
39
43
 
40
- # rubocop:enable Metrics/MethodLength
44
+ # rubocop:enable Metrics/MethodLength, Metrics/AbcSize
41
45
 
42
46
  class << self
43
47
  # @!group Authentication Entry Points
data/sig/lib.rbs CHANGED
@@ -276,6 +276,7 @@ module Zitadel
276
276
 
277
277
  def self.with_private_key: (String, String) -> Zitadel
278
278
 
279
+ attr_reader actions: untyped
279
280
  attr_reader configuration: Configuration
280
281
  attr_reader features: untyped
281
282
  attr_reader idps: untyped
@@ -285,6 +286,7 @@ module Zitadel
285
286
  attr_reader sessions: untyped
286
287
  attr_reader settings: untyped
287
288
  attr_reader users: untyped
289
+ attr_reader webkeys: untyped
288
290
 
289
291
  def initialize: (Auth::Authenticator) ?{ (Configuration) -> void } -> void
290
292
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: zitadel-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.1
4
+ version: 1.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Zitadel
@@ -84,15 +84,16 @@ files:
84
84
  - README.md
85
85
  - lib/patch.rb
86
86
  - lib/zitadel/client/api/.openapi
87
+ - lib/zitadel/client/api/action_service_api.rb
87
88
  - lib/zitadel/client/api/feature_service_api.rb
88
89
  - lib/zitadel/client/api/identity_provider_service_api.rb
89
90
  - lib/zitadel/client/api/o_i_d_c_service_api.rb
90
91
  - lib/zitadel/client/api/organization_service_api.rb
91
92
  - lib/zitadel/client/api/s_a_m_l_service_api.rb
92
93
  - lib/zitadel/client/api/session_service_api.rb
93
- - lib/zitadel/client/api/settings_api.rb
94
94
  - lib/zitadel/client/api/settings_service_api.rb
95
95
  - lib/zitadel/client/api/user_service_api.rb
96
+ - lib/zitadel/client/api/web_key_service_api.rb
96
97
  - lib/zitadel/client/api_client.rb
97
98
  - lib/zitadel/client/api_error.rb
98
99
  - lib/zitadel/client/auth/authenticator.rb
@@ -104,6 +105,39 @@ files:
104
105
  - lib/zitadel/client/auth/web_token_authenticator.rb
105
106
  - lib/zitadel/client/configuration.rb
106
107
  - lib/zitadel/client/models/.openapi
108
+ - lib/zitadel/client/models/action_service_beta_condition.rb
109
+ - lib/zitadel/client/models/action_service_beta_create_target_response.rb
110
+ - lib/zitadel/client/models/action_service_beta_delete_target_response.rb
111
+ - lib/zitadel/client/models/action_service_beta_event_execution.rb
112
+ - lib/zitadel/client/models/action_service_beta_execution.rb
113
+ - lib/zitadel/client/models/action_service_beta_execution_target_type.rb
114
+ - lib/zitadel/client/models/action_service_beta_function_execution.rb
115
+ - lib/zitadel/client/models/action_service_beta_get_target_response.rb
116
+ - lib/zitadel/client/models/action_service_beta_in_target_i_ds_filter.rb
117
+ - lib/zitadel/client/models/action_service_beta_list_execution_functions_response.rb
118
+ - lib/zitadel/client/models/action_service_beta_list_execution_methods_response.rb
119
+ - lib/zitadel/client/models/action_service_beta_list_execution_services_response.rb
120
+ - lib/zitadel/client/models/action_service_beta_list_executions_response.rb
121
+ - lib/zitadel/client/models/action_service_beta_list_targets_response.rb
122
+ - lib/zitadel/client/models/action_service_beta_pagination_request.rb
123
+ - lib/zitadel/client/models/action_service_beta_pagination_response.rb
124
+ - lib/zitadel/client/models/action_service_beta_r_e_s_t_call.rb
125
+ - lib/zitadel/client/models/action_service_beta_r_e_s_t_webhook.rb
126
+ - lib/zitadel/client/models/action_service_beta_request_execution.rb
127
+ - lib/zitadel/client/models/action_service_beta_response_execution.rb
128
+ - lib/zitadel/client/models/action_service_beta_set_execution_response.rb
129
+ - lib/zitadel/client/models/action_service_beta_target.rb
130
+ - lib/zitadel/client/models/action_service_beta_target_field_name.rb
131
+ - lib/zitadel/client/models/action_service_beta_target_name_filter.rb
132
+ - lib/zitadel/client/models/action_service_beta_target_search_filter.rb
133
+ - lib/zitadel/client/models/action_service_beta_text_filter_method.rb
134
+ - lib/zitadel/client/models/action_service_beta_update_target_response.rb
135
+ - lib/zitadel/client/models/action_service_create_target_request.rb
136
+ - lib/zitadel/client/models/action_service_list_targets_request.rb
137
+ - lib/zitadel/client/models/action_service_protobuf_any.rb
138
+ - lib/zitadel/client/models/action_service_rpc_status.rb
139
+ - lib/zitadel/client/models/action_service_set_execution_request.rb
140
+ - lib/zitadel/client/models/action_service_update_target_request.rb
107
141
  - lib/zitadel/client/models/feature_service_details.rb
108
142
  - lib/zitadel/client/models/feature_service_feature_flag.rb
109
143
  - lib/zitadel/client/models/feature_service_get_instance_features_response.rb
@@ -421,6 +455,20 @@ files:
421
455
  - lib/zitadel/client/models/user_service_verify_t_o_t_p_registration_response.rb
422
456
  - lib/zitadel/client/models/user_service_verify_u2_f_registration_request.rb
423
457
  - lib/zitadel/client/models/user_service_verify_u2_f_registration_response.rb
458
+ - lib/zitadel/client/models/web_key_service_beta_activate_web_key_response.rb
459
+ - lib/zitadel/client/models/web_key_service_beta_create_web_key_response.rb
460
+ - lib/zitadel/client/models/web_key_service_beta_delete_web_key_response.rb
461
+ - lib/zitadel/client/models/web_key_service_beta_e_c_d_s_a.rb
462
+ - lib/zitadel/client/models/web_key_service_beta_e_c_d_s_a_curve.rb
463
+ - lib/zitadel/client/models/web_key_service_beta_list_web_keys_response.rb
464
+ - lib/zitadel/client/models/web_key_service_beta_r_s_a.rb
465
+ - lib/zitadel/client/models/web_key_service_beta_r_s_a_bits.rb
466
+ - lib/zitadel/client/models/web_key_service_beta_r_s_a_hasher.rb
467
+ - lib/zitadel/client/models/web_key_service_beta_state.rb
468
+ - lib/zitadel/client/models/web_key_service_beta_web_key.rb
469
+ - lib/zitadel/client/models/web_key_service_create_web_key_request.rb
470
+ - lib/zitadel/client/models/web_key_service_protobuf_any.rb
471
+ - lib/zitadel/client/models/web_key_service_rpc_status.rb
424
472
  - lib/zitadel/client/models/zitadelobjectv2_organization.rb
425
473
  - lib/zitadel/client/models/zitadelorgv2_organization.rb
426
474
  - lib/zitadel/client/utils/url_util.rb
@@ -1,147 +0,0 @@
1
- =begin
2
- #Zitadel SDK
3
-
4
- #The Zitadel SDK is a convenience wrapper around the Zitadel APIs to assist you in integrating with your Zitadel environment. This SDK enables you to handle resources, settings, and configurations within the Zitadel platform.
5
-
6
- The version of the OpenAPI document: 1.0.0
7
-
8
- Generated by: https://openapi-generator.tech
9
- Generator version: 7.12.0
10
-
11
- =end
12
-
13
- require 'cgi'
14
-
15
- module Zitadel::Client::Api
16
- class SettingsApi
17
- attr_accessor :api_client
18
-
19
- def initialize(api_client = ApiClient.default)
20
- @api_client = api_client
21
- end
22
- # Get Security Settings
23
- # Returns the security settings of the ZITADEL instance.
24
- # @param [Hash] opts the optional parameters
25
- # @return [SettingsServiceGetSecuritySettingsResponse]
26
- def settings_service_get_security_settings(opts = {})
27
- data, _status_code, _headers = settings_service_get_security_settings_with_http_info(opts)
28
- data
29
- end
30
-
31
- # Get Security Settings
32
- # Returns the security settings of the ZITADEL instance.
33
- # @param [Hash] opts the optional parameters
34
- # @return [Array<(SettingsServiceGetSecuritySettingsResponse, Integer, Hash)>] SettingsServiceGetSecuritySettingsResponse data, response status code and response headers
35
- def settings_service_get_security_settings_with_http_info(opts = {})
36
- if @api_client.config.debugging
37
- @api_client.config.logger.debug 'Calling API: Api::SettingsApi.settings_service_get_security_settings ...' # MODIFIED
38
- end
39
- # resource path
40
- local_var_path = '/v2/settings/security'
41
-
42
- # query parameters
43
- query_params = opts[:query_params] || {}
44
-
45
- # header parameters
46
- header_params = opts[:header_params] || {}
47
- # HTTP header 'Accept' (if needed)
48
- header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
49
-
50
- # form parameters
51
- form_params = opts[:form_params] || {}
52
-
53
- # http body (model)
54
- post_body = opts[:debug_body]
55
-
56
- # return_type
57
- return_type = opts[:debug_return_type] || 'SettingsServiceGetSecuritySettingsResponse'
58
-
59
- # auth_names
60
- auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
61
-
62
- new_options = opts.merge(
63
- :operation => :"Api::SettingsApi.settings_service_get_security_settings", # MODIFIED
64
- :header_params => header_params,
65
- :query_params => query_params,
66
- :form_params => form_params,
67
- :body => post_body,
68
- :auth_names => auth_names,
69
- :return_type => return_type
70
- )
71
-
72
- data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
73
- if @api_client.config.debugging
74
- @api_client.config.logger.debug "API called: Api::SettingsApi#settings_service_get_security_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" # MODIFIED
75
- end
76
- return data, status_code, headers
77
- end
78
-
79
- # Set Security Settings
80
- # Set the security settings of the ZITADEL instance.
81
- # @param settings_service_set_security_settings_request [SettingsServiceSetSecuritySettingsRequest]
82
- # @param [Hash] opts the optional parameters
83
- # @return [SettingsServiceSetSecuritySettingsResponse]
84
- def settings_service_set_security_settings(settings_service_set_security_settings_request, opts = {})
85
- data, _status_code, _headers = settings_service_set_security_settings_with_http_info(settings_service_set_security_settings_request, opts)
86
- data
87
- end
88
-
89
- # Set Security Settings
90
- # Set the security settings of the ZITADEL instance.
91
- # @param settings_service_set_security_settings_request [SettingsServiceSetSecuritySettingsRequest]
92
- # @param [Hash] opts the optional parameters
93
- # @return [Array<(SettingsServiceSetSecuritySettingsResponse, Integer, Hash)>] SettingsServiceSetSecuritySettingsResponse data, response status code and response headers
94
- def settings_service_set_security_settings_with_http_info(settings_service_set_security_settings_request, opts = {})
95
- if @api_client.config.debugging
96
- @api_client.config.logger.debug 'Calling API: Api::SettingsApi.settings_service_set_security_settings ...' # MODIFIED
97
- end
98
- # verify the required parameter 'settings_service_set_security_settings_request' is set
99
- if @api_client.config.client_side_validation && settings_service_set_security_settings_request.nil?
100
- fail ArgumentError, "Missing the required parameter 'settings_service_set_security_settings_request' when calling Api::SettingsApi.settings_service_set_security_settings" # MODIFIED
101
- end
102
- # resource path
103
- local_var_path = '/v2/policies/security'
104
-
105
- # query parameters
106
- query_params = opts[:query_params] || {}
107
-
108
- # header parameters
109
- header_params = opts[:header_params] || {}
110
- # HTTP header 'Accept' (if needed)
111
- header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
112
- # HTTP header 'Content-Type'
113
- content_type = @api_client.select_header_content_type(['application/json'])
114
- if !content_type.nil?
115
- header_params['Content-Type'] = content_type
116
- end
117
-
118
- # form parameters
119
- form_params = opts[:form_params] || {}
120
-
121
- # http body (model)
122
- post_body = opts[:debug_body] || @api_client.object_to_http_body(settings_service_set_security_settings_request)
123
-
124
- # return_type
125
- return_type = opts[:debug_return_type] || 'SettingsServiceSetSecuritySettingsResponse'
126
-
127
- # auth_names
128
- auth_names = opts[:debug_auth_names] || ['zitadelAccessToken']
129
-
130
- new_options = opts.merge(
131
- :operation => :"Api::SettingsApi.settings_service_set_security_settings", # MODIFIED
132
- :header_params => header_params,
133
- :query_params => query_params,
134
- :form_params => form_params,
135
- :body => post_body,
136
- :auth_names => auth_names,
137
- :return_type => return_type
138
- )
139
-
140
- data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
141
- if @api_client.config.debugging
142
- @api_client.config.logger.debug "API called: Api::SettingsApi#settings_service_set_security_settings\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}" # MODIFIED
143
- end
144
- return data, status_code, headers
145
- end
146
- end
147
- end