zitadel-client 1.5.0 → 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 +51 -3
  56. data/lib/zitadel/client/api/settings_api.rb +0 -147
@@ -0,0 +1,275 @@
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 ActionServiceListTargetsRequest
18
+ attr_accessor :pagination
19
+
20
+ attr_accessor :sorting_column
21
+
22
+ # Define the criteria to query for.
23
+ attr_accessor :filters
24
+
25
+ class EnumAttributeValidator
26
+ attr_reader :datatype
27
+ attr_reader :allowable_values
28
+
29
+ def initialize(datatype, allowable_values)
30
+ @allowable_values = allowable_values.map do |value|
31
+ case datatype.to_s
32
+ when /Integer/i
33
+ value.to_i
34
+ when /Float/i
35
+ value.to_f
36
+ else
37
+ value
38
+ end
39
+ end
40
+ end
41
+
42
+ def valid?(value)
43
+ !value || allowable_values.include?(value)
44
+ end
45
+ end
46
+
47
+ # Attribute mapping from ruby-style variable name to JSON key.
48
+ def self.attribute_map
49
+ {
50
+ :'pagination' => :'pagination',
51
+ :'sorting_column' => :'sortingColumn',
52
+ :'filters' => :'filters'
53
+ }
54
+ end
55
+
56
+ # Returns attribute mapping this model knows about
57
+ def self.acceptable_attribute_map
58
+ attribute_map
59
+ end
60
+
61
+ # Returns all the JSON keys this model knows about
62
+ def self.acceptable_attributes
63
+ acceptable_attribute_map.values
64
+ end
65
+
66
+ # Attribute type mapping.
67
+ def self.openapi_types
68
+ {
69
+ :'pagination' => :'ActionServiceBetaPaginationRequest',
70
+ :'sorting_column' => :'ActionServiceBetaTargetFieldName',
71
+ :'filters' => :'Array<ActionServiceBetaTargetSearchFilter>'
72
+ }
73
+ end
74
+
75
+ # List of attributes with nullable: true
76
+ def self.openapi_nullable
77
+ Set.new([
78
+ ])
79
+ end
80
+
81
+ # Initializes the object
82
+ # @param [Hash] attributes Models attributes in the form of hash
83
+ def initialize(attributes = {})
84
+ if (!attributes.is_a?(Hash))
85
+ # MODIFIED: Updated class name in error message
86
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Zitadel::Client::Models::ActionServiceListTargetsRequest` initialize method"
87
+ end
88
+
89
+ # check to see if the attribute exists and convert string to symbol for hash key
90
+ acceptable_attribute_map = self.class.acceptable_attribute_map
91
+ attributes = attributes.each_with_object({}) { |(k, v), h|
92
+ if (!acceptable_attribute_map.key?(k.to_sym))
93
+ # MODIFIED: Updated class name in error message
94
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Zitadel::Client::Models::ActionServiceListTargetsRequest`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
95
+ end
96
+ h[k.to_sym] = v
97
+ }
98
+
99
+ if attributes.key?(:'pagination')
100
+ self.pagination = attributes[:'pagination']
101
+ end
102
+
103
+ if attributes.key?(:'sorting_column')
104
+ self.sorting_column = attributes[:'sorting_column']
105
+ else
106
+ self.sorting_column = 'TARGET_FIELD_NAME_UNSPECIFIED'
107
+ end
108
+
109
+ if attributes.key?(:'filters')
110
+ if (value = attributes[:'filters']).is_a?(Array)
111
+ self.filters = value
112
+ end
113
+ end
114
+ end
115
+
116
+ # Show invalid properties with the reasons. Usually used together with valid?
117
+ # @return Array for valid properties with the reasons
118
+ def list_invalid_properties
119
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
120
+ invalid_properties = Array.new
121
+ invalid_properties
122
+ end
123
+
124
+ # Check to see if the all the properties in the model are valid
125
+ # @return true if the model is valid
126
+ def valid?
127
+ warn '[DEPRECATED] the `valid?` method is obsolete'
128
+ true
129
+ end
130
+
131
+ # Checks equality by comparing each attribute.
132
+ # @param [Object] Object to be compared
133
+ def ==(o)
134
+ return true if self.equal?(o)
135
+ self.class == o.class &&
136
+ pagination == o.pagination &&
137
+ sorting_column == o.sorting_column &&
138
+ filters == o.filters
139
+ end
140
+
141
+ # @see the `==` method
142
+ # @param [Object] Object to be compared
143
+ def eql?(o)
144
+ self == o
145
+ end
146
+
147
+ # Calculates hash code according to all attributes.
148
+ # @return [Integer] Hash code
149
+ def hash
150
+ [pagination, sorting_column, filters].hash
151
+ end
152
+
153
+ # Builds the object from hash
154
+ # @param [Hash] attributes Models attributes in the form of hash
155
+ # @return [Object] Returns the model itself
156
+ def self.build_from_hash(attributes)
157
+ return nil unless attributes.is_a?(Hash)
158
+ attributes = attributes.transform_keys(&:to_sym)
159
+ transformed_hash = {}
160
+ openapi_types.each_pair do |key, type|
161
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
162
+ transformed_hash["#{key}"] = nil
163
+ elsif type =~ /\AArray<(.*)>/i
164
+ # check to ensure the input is an array given that the attribute
165
+ # is documented as an array but the input is not
166
+ if attributes[attribute_map[key]].is_a?(Array)
167
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
168
+ end
169
+ elsif !attributes[attribute_map[key]].nil?
170
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
171
+ end
172
+ end
173
+ new(transformed_hash) # `new` will call the initialize method of the specific model class.
174
+ end
175
+
176
+ # Deserializes the data based on type
177
+ # @param string type Data type
178
+ # @param string value Value to be deserialized
179
+ # @return [Object] Deserialized data
180
+ def self._deserialize(type, value)
181
+ case type.to_sym
182
+ when :Time
183
+ Time.parse(value)
184
+ when :Date
185
+ Date.parse(value)
186
+ when :String
187
+ value.to_s
188
+ when :Integer
189
+ value.to_i
190
+ when :Float
191
+ value.to_f
192
+ when :Boolean
193
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
194
+ true
195
+ else
196
+ false
197
+ end
198
+ when :Object
199
+ # generic object (usually a Hash), return directly
200
+ value
201
+ when /\AArray<(?<inner_type>.+)>\z/
202
+ inner_type = Regexp.last_match[:inner_type]
203
+ value.map { |v| _deserialize(inner_type, v) }
204
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
205
+ k_type = Regexp.last_match[:k_type]
206
+ v_type = Regexp.last_match[:v_type]
207
+ {}.tap do |hash|
208
+ value.each do |k, v|
209
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
210
+ end
211
+ end
212
+ else # model
213
+ # models (e.g. Pet) or oneOf/anyOf constructs that resolve to a model name
214
+ # MODIFIED: Ensure model is looked up in the Models namespace
215
+ # 'type' here is expected to be the simple class name (e.g., "User", "OrderDetails")
216
+ klass = Zitadel::Client::Models.const_get(type)
217
+ # The `klass.build` method is for oneOf/anyOf types (defined in partial_oneof_module.mustache / partial_anyof_module.mustache)
218
+ # The `klass.build_from_hash` is for regular model types (defined in this base_object.mustache itself)
219
+ if klass.respond_to?(:openapi_one_of) || klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_allOf)
220
+ klass.build(value) # For oneOf/anyOf/allOf, delegate to their specific build method
221
+ else
222
+ klass.build_from_hash(value) # For regular models
223
+ end
224
+ end
225
+ end
226
+
227
+ # Returns the string representation of the object
228
+ # @return [String] String presentation of the object
229
+ def to_s
230
+ to_hash.to_s
231
+ end
232
+
233
+ # to_body is an alias to to_hash (backward compatibility)
234
+ # @return [Hash] Returns the object in the form of hash
235
+ def to_body
236
+ to_hash
237
+ end
238
+
239
+ # Returns the object in the form of hash
240
+ # @return [Hash] Returns the object in the form of hash
241
+ def to_hash
242
+ hash = {} # Calls super.to_hash if parent exists
243
+ self.class.attribute_map.each_pair do |attr, param|
244
+ value = self.send(attr)
245
+ if value.nil?
246
+ is_nullable = self.class.openapi_nullable.include?(attr)
247
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
248
+ end
249
+
250
+ hash[param] = _to_hash(value)
251
+ end
252
+ hash
253
+ end
254
+
255
+ # Outputs non-array value in the form of hash
256
+ # For object, use to_hash. Otherwise, just return the value
257
+ # @param [Object] value Any valid value
258
+ # @return [Hash] Returns the value in the form of hash
259
+ def _to_hash(value)
260
+ if value.is_a?(Array)
261
+ value.compact.map { |v| _to_hash(v) }
262
+ elsif value.is_a?(Hash)
263
+ {}.tap do |hash|
264
+ value.each { |k, v| hash[k] = _to_hash(v) }
265
+ end
266
+ elsif value.respond_to? :to_hash
267
+ value.to_hash
268
+ else
269
+ value
270
+ end
271
+ end
272
+
273
+ end
274
+
275
+ end
@@ -0,0 +1,230 @@
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 ActionServiceProtobufAny
18
+ attr_accessor :type
19
+
20
+ # Attribute mapping from ruby-style variable name to JSON key.
21
+ def self.attribute_map
22
+ {
23
+ :'type' => :'@type'
24
+ }
25
+ end
26
+
27
+ # Returns attribute mapping this model knows about
28
+ def self.acceptable_attribute_map
29
+ attribute_map
30
+ end
31
+
32
+ # Returns all the JSON keys this model knows about
33
+ def self.acceptable_attributes
34
+ acceptable_attribute_map.values
35
+ end
36
+
37
+ # Attribute type mapping.
38
+ def self.openapi_types
39
+ {
40
+ :'type' => :'String'
41
+ }
42
+ end
43
+
44
+ # List of attributes with nullable: true
45
+ def self.openapi_nullable
46
+ Set.new([
47
+ ])
48
+ end
49
+
50
+ # Initializes the object
51
+ # @param [Hash] attributes Models attributes in the form of hash
52
+ def initialize(attributes = {})
53
+ if (!attributes.is_a?(Hash))
54
+ # MODIFIED: Updated class name in error message
55
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Zitadel::Client::Models::ActionServiceProtobufAny` initialize method"
56
+ end
57
+
58
+ # check to see if the attribute exists and convert string to symbol for hash key
59
+ acceptable_attribute_map = self.class.acceptable_attribute_map
60
+ attributes = attributes.each_with_object({}) { |(k, v), h|
61
+ if (!acceptable_attribute_map.key?(k.to_sym))
62
+ # MODIFIED: Updated class name in error message
63
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Zitadel::Client::Models::ActionServiceProtobufAny`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
64
+ end
65
+ h[k.to_sym] = v
66
+ }
67
+
68
+ if attributes.key?(:'type')
69
+ self.type = attributes[:'type']
70
+ end
71
+ end
72
+
73
+ # Show invalid properties with the reasons. Usually used together with valid?
74
+ # @return Array for valid properties with the reasons
75
+ def list_invalid_properties
76
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
77
+ invalid_properties = Array.new
78
+ invalid_properties
79
+ end
80
+
81
+ # Check to see if the all the properties in the model are valid
82
+ # @return true if the model is valid
83
+ def valid?
84
+ warn '[DEPRECATED] the `valid?` method is obsolete'
85
+ true
86
+ end
87
+
88
+ # Checks equality by comparing each attribute.
89
+ # @param [Object] Object to be compared
90
+ def ==(o)
91
+ return true if self.equal?(o)
92
+ self.class == o.class &&
93
+ type == o.type
94
+ end
95
+
96
+ # @see the `==` method
97
+ # @param [Object] Object to be compared
98
+ def eql?(o)
99
+ self == o
100
+ end
101
+
102
+ # Calculates hash code according to all attributes.
103
+ # @return [Integer] Hash code
104
+ def hash
105
+ [type].hash
106
+ end
107
+
108
+ # Builds the object from hash
109
+ # @param [Hash] attributes Models attributes in the form of hash
110
+ # @return [Object] Returns the model itself
111
+ def self.build_from_hash(attributes)
112
+ return nil unless attributes.is_a?(Hash)
113
+ attributes = attributes.transform_keys(&:to_sym)
114
+ transformed_hash = {}
115
+ openapi_types.each_pair do |key, type|
116
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
117
+ transformed_hash["#{key}"] = nil
118
+ elsif type =~ /\AArray<(.*)>/i
119
+ # check to ensure the input is an array given that the attribute
120
+ # is documented as an array but the input is not
121
+ if attributes[attribute_map[key]].is_a?(Array)
122
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
123
+ end
124
+ elsif !attributes[attribute_map[key]].nil?
125
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
126
+ end
127
+ end
128
+ new(transformed_hash) # `new` will call the initialize method of the specific model class.
129
+ end
130
+
131
+ # Deserializes the data based on type
132
+ # @param string type Data type
133
+ # @param string value Value to be deserialized
134
+ # @return [Object] Deserialized data
135
+ def self._deserialize(type, value)
136
+ case type.to_sym
137
+ when :Time
138
+ Time.parse(value)
139
+ when :Date
140
+ Date.parse(value)
141
+ when :String
142
+ value.to_s
143
+ when :Integer
144
+ value.to_i
145
+ when :Float
146
+ value.to_f
147
+ when :Boolean
148
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
149
+ true
150
+ else
151
+ false
152
+ end
153
+ when :Object
154
+ # generic object (usually a Hash), return directly
155
+ value
156
+ when /\AArray<(?<inner_type>.+)>\z/
157
+ inner_type = Regexp.last_match[:inner_type]
158
+ value.map { |v| _deserialize(inner_type, v) }
159
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
160
+ k_type = Regexp.last_match[:k_type]
161
+ v_type = Regexp.last_match[:v_type]
162
+ {}.tap do |hash|
163
+ value.each do |k, v|
164
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
165
+ end
166
+ end
167
+ else # model
168
+ # models (e.g. Pet) or oneOf/anyOf constructs that resolve to a model name
169
+ # MODIFIED: Ensure model is looked up in the Models namespace
170
+ # 'type' here is expected to be the simple class name (e.g., "User", "OrderDetails")
171
+ klass = Zitadel::Client::Models.const_get(type)
172
+ # The `klass.build` method is for oneOf/anyOf types (defined in partial_oneof_module.mustache / partial_anyof_module.mustache)
173
+ # The `klass.build_from_hash` is for regular model types (defined in this base_object.mustache itself)
174
+ if klass.respond_to?(:openapi_one_of) || klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_allOf)
175
+ klass.build(value) # For oneOf/anyOf/allOf, delegate to their specific build method
176
+ else
177
+ klass.build_from_hash(value) # For regular models
178
+ end
179
+ end
180
+ end
181
+
182
+ # Returns the string representation of the object
183
+ # @return [String] String presentation of the object
184
+ def to_s
185
+ to_hash.to_s
186
+ end
187
+
188
+ # to_body is an alias to to_hash (backward compatibility)
189
+ # @return [Hash] Returns the object in the form of hash
190
+ def to_body
191
+ to_hash
192
+ end
193
+
194
+ # Returns the object in the form of hash
195
+ # @return [Hash] Returns the object in the form of hash
196
+ def to_hash
197
+ hash = {} # Calls super.to_hash if parent exists
198
+ self.class.attribute_map.each_pair do |attr, param|
199
+ value = self.send(attr)
200
+ if value.nil?
201
+ is_nullable = self.class.openapi_nullable.include?(attr)
202
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
203
+ end
204
+
205
+ hash[param] = _to_hash(value)
206
+ end
207
+ hash
208
+ end
209
+
210
+ # Outputs non-array value in the form of hash
211
+ # For object, use to_hash. Otherwise, just return the value
212
+ # @param [Object] value Any valid value
213
+ # @return [Hash] Returns the value in the form of hash
214
+ def _to_hash(value)
215
+ if value.is_a?(Array)
216
+ value.compact.map { |v| _to_hash(v) }
217
+ elsif value.is_a?(Hash)
218
+ {}.tap do |hash|
219
+ value.each { |k, v| hash[k] = _to_hash(v) }
220
+ end
221
+ elsif value.respond_to? :to_hash
222
+ value.to_hash
223
+ else
224
+ value
225
+ end
226
+ end
227
+
228
+ end
229
+
230
+ end