akeyless 3.2.5 → 3.2.7

Sign up to get free protection for your applications and to get access to all the features.
Files changed (168) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +12 -1
  3. data/docs/CertAccessRules.md +2 -0
  4. data/docs/CreateAuthMethodCert.md +2 -0
  5. data/docs/CreateCertificate.md +1 -1
  6. data/docs/CreateClassicKey.md +1 -1
  7. data/docs/CreateDynamicSecret.md +1 -1
  8. data/docs/CreateLinkedTarget.md +1 -3
  9. data/docs/CreateRotatedSecret.md +1 -1
  10. data/docs/CreateSecret.md +1 -1
  11. data/docs/CreateWindowsTarget.md +2 -4
  12. data/docs/DecryptFile.md +6 -0
  13. data/docs/DescribeAssoc.md +24 -0
  14. data/docs/DescribeItem.md +2 -0
  15. data/docs/DynamicSecretProducerInfo.md +4 -0
  16. data/docs/EncryptFile.md +0 -2
  17. data/docs/GatewayBasicInfo.md +24 -0
  18. data/docs/GatewayCreateProducerArtifactory.md +1 -1
  19. data/docs/GatewayCreateProducerAws.md +1 -1
  20. data/docs/GatewayCreateProducerAzure.md +1 -1
  21. data/docs/GatewayCreateProducerCassandra.md +1 -1
  22. data/docs/GatewayCreateProducerCertificateAutomation.md +1 -1
  23. data/docs/GatewayCreateProducerChef.md +1 -1
  24. data/docs/GatewayCreateProducerCustom.md +1 -1
  25. data/docs/GatewayCreateProducerDockerhub.md +1 -1
  26. data/docs/GatewayCreateProducerEks.md +1 -1
  27. data/docs/GatewayCreateProducerGcp.md +1 -1
  28. data/docs/GatewayCreateProducerGke.md +1 -1
  29. data/docs/GatewayCreateProducerHanaDb.md +1 -1
  30. data/docs/GatewayCreateProducerLdap.md +1 -1
  31. data/docs/GatewayCreateProducerMSSQL.md +1 -1
  32. data/docs/GatewayCreateProducerMongo.md +1 -1
  33. data/docs/GatewayCreateProducerMySQL.md +1 -1
  34. data/docs/GatewayCreateProducerNativeK8S.md +11 -1
  35. data/docs/GatewayCreateProducerOracleDb.md +1 -1
  36. data/docs/GatewayCreateProducerPing.md +1 -1
  37. data/docs/GatewayCreateProducerPostgreSQL.md +1 -1
  38. data/docs/GatewayCreateProducerRabbitMQ.md +1 -1
  39. data/docs/GatewayCreateProducerRdp.md +1 -1
  40. data/docs/GatewayCreateProducerRedshift.md +1 -1
  41. data/docs/GatewayCreateProducerSnowflake.md +1 -1
  42. data/docs/GatewayDownloadCustomerFragments.md +22 -0
  43. data/docs/GatewayDownloadCustomerFragmentsOutput.md +18 -0
  44. data/docs/GatewayMessageQueueInfo.md +2 -0
  45. data/docs/GatewayUpdateProducerArtifactory.md +1 -1
  46. data/docs/GatewayUpdateProducerAws.md +1 -1
  47. data/docs/GatewayUpdateProducerAzure.md +1 -1
  48. data/docs/GatewayUpdateProducerCassandra.md +1 -1
  49. data/docs/GatewayUpdateProducerCertificateAutomation.md +1 -1
  50. data/docs/GatewayUpdateProducerChef.md +1 -1
  51. data/docs/GatewayUpdateProducerCustom.md +1 -1
  52. data/docs/GatewayUpdateProducerDockerhub.md +1 -1
  53. data/docs/GatewayUpdateProducerEks.md +1 -1
  54. data/docs/GatewayUpdateProducerGcp.md +1 -1
  55. data/docs/GatewayUpdateProducerGke.md +1 -1
  56. data/docs/GatewayUpdateProducerHanaDb.md +1 -1
  57. data/docs/GatewayUpdateProducerLdap.md +1 -1
  58. data/docs/GatewayUpdateProducerMSSQL.md +1 -1
  59. data/docs/GatewayUpdateProducerMongo.md +1 -1
  60. data/docs/GatewayUpdateProducerMySQL.md +1 -1
  61. data/docs/GatewayUpdateProducerNativeK8S.md +11 -1
  62. data/docs/GatewayUpdateProducerOracleDb.md +1 -1
  63. data/docs/GatewayUpdateProducerPing.md +1 -1
  64. data/docs/GatewayUpdateProducerPostgreSQL.md +1 -1
  65. data/docs/GatewayUpdateProducerRabbitMQ.md +1 -1
  66. data/docs/GatewayUpdateProducerRdp.md +1 -1
  67. data/docs/GatewayUpdateProducerRedshift.md +1 -1
  68. data/docs/GatewayUpdateProducerSnowflake.md +1 -1
  69. data/docs/GeneralConfigPart.md +2 -0
  70. data/docs/ImportPasswords.md +32 -0
  71. data/docs/ImportPasswordsOutput.md +22 -0
  72. data/docs/Item.md +4 -0
  73. data/docs/LinkedDetails.md +18 -0
  74. data/docs/RoleAssociationDetails.md +26 -0
  75. data/docs/TargetTypeDetailsInput.md +1 -3
  76. data/docs/UpdateAuthMethodCert.md +2 -0
  77. data/docs/UpdateLinkedTarget.md +2 -4
  78. data/docs/UpdateWindowsTarget.md +2 -4
  79. data/docs/V2Api.md +191 -2
  80. data/lib/akeyless/api/v2_api.rb +192 -0
  81. data/lib/akeyless/configuration.rb +5 -0
  82. data/lib/akeyless/models/cert_access_rules.rb +13 -1
  83. data/lib/akeyless/models/create_auth_method_cert.rb +11 -1
  84. data/lib/akeyless/models/create_certificate.rb +1 -1
  85. data/lib/akeyless/models/create_classic_key.rb +1 -1
  86. data/lib/akeyless/models/create_dynamic_secret.rb +1 -1
  87. data/lib/akeyless/models/create_linked_target.rb +2 -17
  88. data/lib/akeyless/models/create_rotated_secret.rb +1 -1
  89. data/lib/akeyless/models/create_secret.rb +1 -1
  90. data/lib/akeyless/models/create_windows_target.rb +9 -19
  91. data/lib/akeyless/models/decrypt_file.rb +35 -1
  92. data/lib/akeyless/models/describe_assoc.rb +257 -0
  93. data/lib/akeyless/models/describe_item.rb +13 -1
  94. data/lib/akeyless/models/dynamic_secret_producer_info.rb +21 -1
  95. data/lib/akeyless/models/encrypt_file.rb +1 -13
  96. data/lib/akeyless/models/gateway_basic_info.rb +246 -0
  97. data/lib/akeyless/models/gateway_create_producer_artifactory.rb +1 -1
  98. data/lib/akeyless/models/gateway_create_producer_aws.rb +1 -1
  99. data/lib/akeyless/models/gateway_create_producer_azure.rb +1 -1
  100. data/lib/akeyless/models/gateway_create_producer_cassandra.rb +1 -1
  101. data/lib/akeyless/models/gateway_create_producer_certificate_automation.rb +1 -1
  102. data/lib/akeyless/models/gateway_create_producer_chef.rb +1 -1
  103. data/lib/akeyless/models/gateway_create_producer_custom.rb +1 -1
  104. data/lib/akeyless/models/gateway_create_producer_dockerhub.rb +1 -1
  105. data/lib/akeyless/models/gateway_create_producer_eks.rb +1 -1
  106. data/lib/akeyless/models/gateway_create_producer_gcp.rb +1 -1
  107. data/lib/akeyless/models/gateway_create_producer_gke.rb +1 -1
  108. data/lib/akeyless/models/gateway_create_producer_hana_db.rb +1 -1
  109. data/lib/akeyless/models/gateway_create_producer_ldap.rb +1 -1
  110. data/lib/akeyless/models/gateway_create_producer_mongo.rb +1 -1
  111. data/lib/akeyless/models/gateway_create_producer_mssql.rb +1 -1
  112. data/lib/akeyless/models/gateway_create_producer_my_sql.rb +1 -1
  113. data/lib/akeyless/models/gateway_create_producer_native_k8_s.rb +52 -2
  114. data/lib/akeyless/models/gateway_create_producer_oracle_db.rb +1 -1
  115. data/lib/akeyless/models/gateway_create_producer_ping.rb +1 -1
  116. data/lib/akeyless/models/gateway_create_producer_postgre_sql.rb +1 -1
  117. data/lib/akeyless/models/gateway_create_producer_rabbit_mq.rb +1 -1
  118. data/lib/akeyless/models/gateway_create_producer_rdp.rb +1 -1
  119. data/lib/akeyless/models/gateway_create_producer_redshift.rb +1 -1
  120. data/lib/akeyless/models/gateway_create_producer_snowflake.rb +1 -1
  121. data/lib/akeyless/models/gateway_download_customer_fragments.rb +243 -0
  122. data/lib/akeyless/models/gateway_download_customer_fragments_output.rb +221 -0
  123. data/lib/akeyless/models/gateway_message_queue_info.rb +10 -1
  124. data/lib/akeyless/models/gateway_update_producer_artifactory.rb +1 -1
  125. data/lib/akeyless/models/gateway_update_producer_aws.rb +1 -1
  126. data/lib/akeyless/models/gateway_update_producer_azure.rb +1 -1
  127. data/lib/akeyless/models/gateway_update_producer_cassandra.rb +1 -1
  128. data/lib/akeyless/models/gateway_update_producer_certificate_automation.rb +1 -1
  129. data/lib/akeyless/models/gateway_update_producer_chef.rb +1 -1
  130. data/lib/akeyless/models/gateway_update_producer_custom.rb +1 -1
  131. data/lib/akeyless/models/gateway_update_producer_dockerhub.rb +1 -1
  132. data/lib/akeyless/models/gateway_update_producer_eks.rb +1 -1
  133. data/lib/akeyless/models/gateway_update_producer_gcp.rb +1 -1
  134. data/lib/akeyless/models/gateway_update_producer_gke.rb +1 -1
  135. data/lib/akeyless/models/gateway_update_producer_hana_db.rb +1 -1
  136. data/lib/akeyless/models/gateway_update_producer_ldap.rb +1 -1
  137. data/lib/akeyless/models/gateway_update_producer_mongo.rb +1 -1
  138. data/lib/akeyless/models/gateway_update_producer_mssql.rb +1 -1
  139. data/lib/akeyless/models/gateway_update_producer_my_sql.rb +1 -1
  140. data/lib/akeyless/models/gateway_update_producer_native_k8_s.rb +52 -2
  141. data/lib/akeyless/models/gateway_update_producer_oracle_db.rb +1 -1
  142. data/lib/akeyless/models/gateway_update_producer_ping.rb +1 -1
  143. data/lib/akeyless/models/gateway_update_producer_postgre_sql.rb +1 -1
  144. data/lib/akeyless/models/gateway_update_producer_rabbit_mq.rb +1 -1
  145. data/lib/akeyless/models/gateway_update_producer_rdp.rb +1 -1
  146. data/lib/akeyless/models/gateway_update_producer_redshift.rb +1 -1
  147. data/lib/akeyless/models/gateway_update_producer_snowflake.rb +1 -1
  148. data/lib/akeyless/models/general_config_part.rb +10 -1
  149. data/lib/akeyless/models/import_passwords.rb +304 -0
  150. data/lib/akeyless/models/import_passwords_output.rb +237 -0
  151. data/lib/akeyless/models/item.rb +21 -1
  152. data/lib/akeyless/models/linked_details.rb +221 -0
  153. data/lib/akeyless/models/role_association_details.rb +258 -0
  154. data/lib/akeyless/models/target_type_details_input.rb +3 -12
  155. data/lib/akeyless/models/update_auth_method_cert.rb +11 -1
  156. data/lib/akeyless/models/update_linked_target.rb +3 -18
  157. data/lib/akeyless/models/update_windows_target.rb +9 -19
  158. data/lib/akeyless/version.rb +1 -1
  159. data/lib/akeyless.rb +8 -0
  160. data/spec/models/describe_assoc_spec.rb +52 -0
  161. data/spec/models/gateway_basic_info_spec.rb +52 -0
  162. data/spec/models/gateway_download_customer_fragments_output_spec.rb +34 -0
  163. data/spec/models/gateway_download_customer_fragments_spec.rb +46 -0
  164. data/spec/models/import_passwords_output_spec.rb +46 -0
  165. data/spec/models/import_passwords_spec.rb +76 -0
  166. data/spec/models/linked_details_spec.rb +34 -0
  167. data/spec/models/role_association_details_spec.rb +58 -0
  168. metadata +34 -2
@@ -0,0 +1,243 @@
1
+ =begin
2
+ #Akeyless API
3
+
4
+ #The purpose of this application is to provide access to Akeyless API.
5
+
6
+ The version of the OpenAPI document: 2.0
7
+ Contact: support@akeyless.io
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 6.5.0-SNAPSHOT
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Akeyless
17
+ # gatewayDownloadCustomerFragments is a command that downloads customer fragments
18
+ class GatewayDownloadCustomerFragments
19
+ # Set output format to JSON
20
+ attr_accessor :json
21
+
22
+ # Authentication token (see `/auth` and `/configure`)
23
+ attr_accessor :token
24
+
25
+ # The universal identity token, Required only for universal_identity authentication
26
+ attr_accessor :uid_token
27
+
28
+ # Attribute mapping from ruby-style variable name to JSON key.
29
+ def self.attribute_map
30
+ {
31
+ :'json' => :'json',
32
+ :'token' => :'token',
33
+ :'uid_token' => :'uid-token'
34
+ }
35
+ end
36
+
37
+ # Returns all the JSON keys this model knows about
38
+ def self.acceptable_attributes
39
+ attribute_map.values
40
+ end
41
+
42
+ # Attribute type mapping.
43
+ def self.openapi_types
44
+ {
45
+ :'json' => :'Boolean',
46
+ :'token' => :'String',
47
+ :'uid_token' => :'String'
48
+ }
49
+ end
50
+
51
+ # List of attributes with nullable: true
52
+ def self.openapi_nullable
53
+ Set.new([
54
+ ])
55
+ end
56
+
57
+ # Initializes the object
58
+ # @param [Hash] attributes Model attributes in the form of hash
59
+ def initialize(attributes = {})
60
+ if (!attributes.is_a?(Hash))
61
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Akeyless::GatewayDownloadCustomerFragments` initialize method"
62
+ end
63
+
64
+ # check to see if the attribute exists and convert string to symbol for hash key
65
+ attributes = attributes.each_with_object({}) { |(k, v), h|
66
+ if (!self.class.attribute_map.key?(k.to_sym))
67
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Akeyless::GatewayDownloadCustomerFragments`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
68
+ end
69
+ h[k.to_sym] = v
70
+ }
71
+
72
+ if attributes.key?(:'json')
73
+ self.json = attributes[:'json']
74
+ else
75
+ self.json = false
76
+ end
77
+
78
+ if attributes.key?(:'token')
79
+ self.token = attributes[:'token']
80
+ end
81
+
82
+ if attributes.key?(:'uid_token')
83
+ self.uid_token = attributes[:'uid_token']
84
+ end
85
+ end
86
+
87
+ # Show invalid properties with the reasons. Usually used together with valid?
88
+ # @return Array for valid properties with the reasons
89
+ def list_invalid_properties
90
+ invalid_properties = Array.new
91
+ invalid_properties
92
+ end
93
+
94
+ # Check to see if the all the properties in the model are valid
95
+ # @return true if the model is valid
96
+ def valid?
97
+ true
98
+ end
99
+
100
+ # Checks equality by comparing each attribute.
101
+ # @param [Object] Object to be compared
102
+ def ==(o)
103
+ return true if self.equal?(o)
104
+ self.class == o.class &&
105
+ json == o.json &&
106
+ token == o.token &&
107
+ uid_token == o.uid_token
108
+ end
109
+
110
+ # @see the `==` method
111
+ # @param [Object] Object to be compared
112
+ def eql?(o)
113
+ self == o
114
+ end
115
+
116
+ # Calculates hash code according to all attributes.
117
+ # @return [Integer] Hash code
118
+ def hash
119
+ [json, token, uid_token].hash
120
+ end
121
+
122
+ # Builds the object from hash
123
+ # @param [Hash] attributes Model attributes in the form of hash
124
+ # @return [Object] Returns the model itself
125
+ def self.build_from_hash(attributes)
126
+ new.build_from_hash(attributes)
127
+ end
128
+
129
+ # Builds the object from hash
130
+ # @param [Hash] attributes Model attributes in the form of hash
131
+ # @return [Object] Returns the model itself
132
+ def build_from_hash(attributes)
133
+ return nil unless attributes.is_a?(Hash)
134
+ attributes = attributes.transform_keys(&:to_sym)
135
+ self.class.openapi_types.each_pair do |key, type|
136
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
137
+ self.send("#{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[self.class.attribute_map[key]].is_a?(Array)
142
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
143
+ end
144
+ elsif !attributes[self.class.attribute_map[key]].nil?
145
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
146
+ end
147
+ end
148
+
149
+ self
150
+ end
151
+
152
+ # Deserializes the data based on type
153
+ # @param string type Data type
154
+ # @param string value Value to be deserialized
155
+ # @return [Object] Deserialized data
156
+ def _deserialize(type, value)
157
+ case type.to_sym
158
+ when :Time
159
+ Time.parse(value)
160
+ when :Date
161
+ Date.parse(value)
162
+ when :String
163
+ value.to_s
164
+ when :Integer
165
+ value.to_i
166
+ when :Float
167
+ value.to_f
168
+ when :Boolean
169
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
170
+ true
171
+ else
172
+ false
173
+ end
174
+ when :Object
175
+ # generic object (usually a Hash), return directly
176
+ value
177
+ when /\AArray<(?<inner_type>.+)>\z/
178
+ inner_type = Regexp.last_match[:inner_type]
179
+ value.map { |v| _deserialize(inner_type, v) }
180
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
181
+ k_type = Regexp.last_match[:k_type]
182
+ v_type = Regexp.last_match[:v_type]
183
+ {}.tap do |hash|
184
+ value.each do |k, v|
185
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
186
+ end
187
+ end
188
+ else # model
189
+ # models (e.g. Pet) or oneOf
190
+ klass = Akeyless.const_get(type)
191
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
192
+ end
193
+ end
194
+
195
+ # Returns the string representation of the object
196
+ # @return [String] String presentation of the object
197
+ def to_s
198
+ to_hash.to_s
199
+ end
200
+
201
+ # to_body is an alias to to_hash (backward compatibility)
202
+ # @return [Hash] Returns the object in the form of hash
203
+ def to_body
204
+ to_hash
205
+ end
206
+
207
+ # Returns the object in the form of hash
208
+ # @return [Hash] Returns the object in the form of hash
209
+ def to_hash
210
+ hash = {}
211
+ self.class.attribute_map.each_pair do |attr, param|
212
+ value = self.send(attr)
213
+ if value.nil?
214
+ is_nullable = self.class.openapi_nullable.include?(attr)
215
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
216
+ end
217
+
218
+ hash[param] = _to_hash(value)
219
+ end
220
+ hash
221
+ end
222
+
223
+ # Outputs non-array value in the form of hash
224
+ # For object, use to_hash. Otherwise, just return the value
225
+ # @param [Object] value Any valid value
226
+ # @return [Hash] Returns the value in the form of hash
227
+ def _to_hash(value)
228
+ if value.is_a?(Array)
229
+ value.compact.map { |v| _to_hash(v) }
230
+ elsif value.is_a?(Hash)
231
+ {}.tap do |hash|
232
+ value.each { |k, v| hash[k] = _to_hash(v) }
233
+ end
234
+ elsif value.respond_to? :to_hash
235
+ value.to_hash
236
+ else
237
+ value
238
+ end
239
+ end
240
+
241
+ end
242
+
243
+ end
@@ -0,0 +1,221 @@
1
+ =begin
2
+ #Akeyless API
3
+
4
+ #The purpose of this application is to provide access to Akeyless API.
5
+
6
+ The version of the OpenAPI document: 2.0
7
+ Contact: support@akeyless.io
8
+ Generated by: https://openapi-generator.tech
9
+ OpenAPI Generator version: 6.5.0-SNAPSHOT
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module Akeyless
17
+ class GatewayDownloadCustomerFragmentsOutput
18
+ attr_accessor :cf_json
19
+
20
+ # Attribute mapping from ruby-style variable name to JSON key.
21
+ def self.attribute_map
22
+ {
23
+ :'cf_json' => :'cf_json'
24
+ }
25
+ end
26
+
27
+ # Returns all the JSON keys this model knows about
28
+ def self.acceptable_attributes
29
+ attribute_map.values
30
+ end
31
+
32
+ # Attribute type mapping.
33
+ def self.openapi_types
34
+ {
35
+ :'cf_json' => :'Hash<String, Object>'
36
+ }
37
+ end
38
+
39
+ # List of attributes with nullable: true
40
+ def self.openapi_nullable
41
+ Set.new([
42
+ ])
43
+ end
44
+
45
+ # Initializes the object
46
+ # @param [Hash] attributes Model attributes in the form of hash
47
+ def initialize(attributes = {})
48
+ if (!attributes.is_a?(Hash))
49
+ fail ArgumentError, "The input argument (attributes) must be a hash in `Akeyless::GatewayDownloadCustomerFragmentsOutput` initialize method"
50
+ end
51
+
52
+ # check to see if the attribute exists and convert string to symbol for hash key
53
+ attributes = attributes.each_with_object({}) { |(k, v), h|
54
+ if (!self.class.attribute_map.key?(k.to_sym))
55
+ fail ArgumentError, "`#{k}` is not a valid attribute in `Akeyless::GatewayDownloadCustomerFragmentsOutput`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
56
+ end
57
+ h[k.to_sym] = v
58
+ }
59
+
60
+ if attributes.key?(:'cf_json')
61
+ if (value = attributes[:'cf_json']).is_a?(Hash)
62
+ self.cf_json = value
63
+ end
64
+ end
65
+ end
66
+
67
+ # Show invalid properties with the reasons. Usually used together with valid?
68
+ # @return Array for valid properties with the reasons
69
+ def list_invalid_properties
70
+ invalid_properties = Array.new
71
+ invalid_properties
72
+ end
73
+
74
+ # Check to see if the all the properties in the model are valid
75
+ # @return true if the model is valid
76
+ def valid?
77
+ true
78
+ end
79
+
80
+ # Checks equality by comparing each attribute.
81
+ # @param [Object] Object to be compared
82
+ def ==(o)
83
+ return true if self.equal?(o)
84
+ self.class == o.class &&
85
+ cf_json == o.cf_json
86
+ end
87
+
88
+ # @see the `==` method
89
+ # @param [Object] Object to be compared
90
+ def eql?(o)
91
+ self == o
92
+ end
93
+
94
+ # Calculates hash code according to all attributes.
95
+ # @return [Integer] Hash code
96
+ def hash
97
+ [cf_json].hash
98
+ end
99
+
100
+ # Builds the object from hash
101
+ # @param [Hash] attributes Model attributes in the form of hash
102
+ # @return [Object] Returns the model itself
103
+ def self.build_from_hash(attributes)
104
+ new.build_from_hash(attributes)
105
+ end
106
+
107
+ # Builds the object from hash
108
+ # @param [Hash] attributes Model attributes in the form of hash
109
+ # @return [Object] Returns the model itself
110
+ def build_from_hash(attributes)
111
+ return nil unless attributes.is_a?(Hash)
112
+ attributes = attributes.transform_keys(&:to_sym)
113
+ self.class.openapi_types.each_pair do |key, type|
114
+ if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
115
+ self.send("#{key}=", nil)
116
+ elsif type =~ /\AArray<(.*)>/i
117
+ # check to ensure the input is an array given that the attribute
118
+ # is documented as an array but the input is not
119
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
120
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
121
+ end
122
+ elsif !attributes[self.class.attribute_map[key]].nil?
123
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
124
+ end
125
+ end
126
+
127
+ self
128
+ end
129
+
130
+ # Deserializes the data based on type
131
+ # @param string type Data type
132
+ # @param string value Value to be deserialized
133
+ # @return [Object] Deserialized data
134
+ def _deserialize(type, value)
135
+ case type.to_sym
136
+ when :Time
137
+ Time.parse(value)
138
+ when :Date
139
+ Date.parse(value)
140
+ when :String
141
+ value.to_s
142
+ when :Integer
143
+ value.to_i
144
+ when :Float
145
+ value.to_f
146
+ when :Boolean
147
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
148
+ true
149
+ else
150
+ false
151
+ end
152
+ when :Object
153
+ # generic object (usually a Hash), return directly
154
+ value
155
+ when /\AArray<(?<inner_type>.+)>\z/
156
+ inner_type = Regexp.last_match[:inner_type]
157
+ value.map { |v| _deserialize(inner_type, v) }
158
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
159
+ k_type = Regexp.last_match[:k_type]
160
+ v_type = Regexp.last_match[:v_type]
161
+ {}.tap do |hash|
162
+ value.each do |k, v|
163
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
164
+ end
165
+ end
166
+ else # model
167
+ # models (e.g. Pet) or oneOf
168
+ klass = Akeyless.const_get(type)
169
+ klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
170
+ end
171
+ end
172
+
173
+ # Returns the string representation of the object
174
+ # @return [String] String presentation of the object
175
+ def to_s
176
+ to_hash.to_s
177
+ end
178
+
179
+ # to_body is an alias to to_hash (backward compatibility)
180
+ # @return [Hash] Returns the object in the form of hash
181
+ def to_body
182
+ to_hash
183
+ end
184
+
185
+ # Returns the object in the form of hash
186
+ # @return [Hash] Returns the object in the form of hash
187
+ def to_hash
188
+ hash = {}
189
+ self.class.attribute_map.each_pair do |attr, param|
190
+ value = self.send(attr)
191
+ if value.nil?
192
+ is_nullable = self.class.openapi_nullable.include?(attr)
193
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
194
+ end
195
+
196
+ hash[param] = _to_hash(value)
197
+ end
198
+ hash
199
+ end
200
+
201
+ # Outputs non-array value in the form of hash
202
+ # For object, use to_hash. Otherwise, just return the value
203
+ # @param [Object] value Any valid value
204
+ # @return [Hash] Returns the value in the form of hash
205
+ def _to_hash(value)
206
+ if value.is_a?(Array)
207
+ value.compact.map { |v| _to_hash(v) }
208
+ elsif value.is_a?(Hash)
209
+ {}.tap do |hash|
210
+ value.each { |k, v| hash[k] = _to_hash(v) }
211
+ end
212
+ elsif value.respond_to? :to_hash
213
+ value.to_hash
214
+ else
215
+ value
216
+ end
217
+ end
218
+
219
+ end
220
+
221
+ end
@@ -15,6 +15,8 @@ require 'time'
15
15
 
16
16
  module Akeyless
17
17
  class GatewayMessageQueueInfo
18
+ attr_accessor :broadcast_queue_name
19
+
18
20
  attr_accessor :mq_type
19
21
 
20
22
  attr_accessor :queue_name
@@ -24,6 +26,7 @@ module Akeyless
24
26
  # Attribute mapping from ruby-style variable name to JSON key.
25
27
  def self.attribute_map
26
28
  {
29
+ :'broadcast_queue_name' => :'broadcast_queue_name',
27
30
  :'mq_type' => :'mq_type',
28
31
  :'queue_name' => :'queue_name',
29
32
  :'queue_url' => :'queue_url'
@@ -38,6 +41,7 @@ module Akeyless
38
41
  # Attribute type mapping.
39
42
  def self.openapi_types
40
43
  {
44
+ :'broadcast_queue_name' => :'String',
41
45
  :'mq_type' => :'String',
42
46
  :'queue_name' => :'String',
43
47
  :'queue_url' => :'String'
@@ -65,6 +69,10 @@ module Akeyless
65
69
  h[k.to_sym] = v
66
70
  }
67
71
 
72
+ if attributes.key?(:'broadcast_queue_name')
73
+ self.broadcast_queue_name = attributes[:'broadcast_queue_name']
74
+ end
75
+
68
76
  if attributes.key?(:'mq_type')
69
77
  self.mq_type = attributes[:'mq_type']
70
78
  end
@@ -96,6 +104,7 @@ module Akeyless
96
104
  def ==(o)
97
105
  return true if self.equal?(o)
98
106
  self.class == o.class &&
107
+ broadcast_queue_name == o.broadcast_queue_name &&
99
108
  mq_type == o.mq_type &&
100
109
  queue_name == o.queue_name &&
101
110
  queue_url == o.queue_url
@@ -110,7 +119,7 @@ module Akeyless
110
119
  # Calculates hash code according to all attributes.
111
120
  # @return [Integer] Hash code
112
121
  def hash
113
- [mq_type, queue_name, queue_url].hash
122
+ [broadcast_queue_name, mq_type, queue_name, queue_url].hash
114
123
  end
115
124
 
116
125
  # Builds the object from hash
@@ -46,7 +46,7 @@ module Akeyless
46
46
  # Dynamic producer encryption key
47
47
  attr_accessor :producer_encryption_key_name
48
48
 
49
- # List of the tags attached to this secret
49
+ # Add tags attached to this object
50
50
  attr_accessor :tags
51
51
 
52
52
  # Target name
@@ -84,7 +84,7 @@ module Akeyless
84
84
  # Web-Proxy via Akeyless Web Access Bastion
85
85
  attr_accessor :secure_access_web_proxy
86
86
 
87
- # List of the tags attached to this secret
87
+ # Add tags attached to this object
88
88
  attr_accessor :tags
89
89
 
90
90
  # Target name
@@ -61,7 +61,7 @@ module Akeyless
61
61
  # Web-Proxy via Akeyless Web Access Bastion
62
62
  attr_accessor :secure_access_web_proxy
63
63
 
64
- # List of the tags attached to this secret
64
+ # Add tags attached to this object
65
65
  attr_accessor :tags
66
66
 
67
67
  # Target name
@@ -46,7 +46,7 @@ module Akeyless
46
46
  # Dynamic producer encryption key
47
47
  attr_accessor :producer_encryption_key_name
48
48
 
49
- # List of the tags attached to this secret
49
+ # Add tags attached to this object
50
50
  attr_accessor :tags
51
51
 
52
52
  # Target name
@@ -58,7 +58,7 @@ module Akeyless
58
58
  # Store private key
59
59
  attr_accessor :store_private_key
60
60
 
61
- # List of the tags attached to this secret
61
+ # Add tags attached to this object
62
62
  attr_accessor :tags
63
63
 
64
64
  # Target name
@@ -46,7 +46,7 @@ module Akeyless
46
46
  # Skip SSL
47
47
  attr_accessor :skip_ssl
48
48
 
49
- # List of the tags attached to this secret
49
+ # Add tags attached to this object
50
50
  attr_accessor :tags
51
51
 
52
52
  # Target name
@@ -48,7 +48,7 @@ module Akeyless
48
48
  # URL of an endpoint that implements /sync/rotate method, for example https://webhook.example.com/sync/rotate
49
49
  attr_accessor :rotate_sync_url
50
50
 
51
- # List of the tags attached to this secret
51
+ # Add tags attached to this object
52
52
  attr_accessor :tags
53
53
 
54
54
  # Maximum allowed time in seconds for the webhook to return the results
@@ -40,7 +40,7 @@ module Akeyless
40
40
  # Dynamic producer encryption key
41
41
  attr_accessor :producer_encryption_key_name
42
42
 
43
- # List of the tags attached to this secret
43
+ # Add tags attached to this object
44
44
  attr_accessor :tags
45
45
 
46
46
  # Target name
@@ -67,7 +67,7 @@ module Akeyless
67
67
  # Enable Web Secure Remote Access
68
68
  attr_accessor :secure_access_web
69
69
 
70
- # List of the tags attached to this secret
70
+ # Add tags attached to this object
71
71
  attr_accessor :tags
72
72
 
73
73
  # Target name
@@ -51,7 +51,7 @@ module Akeyless
51
51
  # The type of the gcp dynamic secret. Options[fixed, dynamic]
52
52
  attr_accessor :service_account_type
53
53
 
54
- # List of the tags attached to this secret
54
+ # Add tags attached to this object
55
55
  attr_accessor :tags
56
56
 
57
57
  # Target name
@@ -61,7 +61,7 @@ module Akeyless
61
61
  # Enable Web Secure Remote Access
62
62
  attr_accessor :secure_access_web
63
63
 
64
- # List of the tags attached to this secret
64
+ # Add tags attached to this object
65
65
  attr_accessor :tags
66
66
 
67
67
  # Target name
@@ -67,7 +67,7 @@ module Akeyless
67
67
  # Enable Web Secure Remote Access
68
68
  attr_accessor :secure_access_web
69
69
 
70
- # List of the tags attached to this secret
70
+ # Add tags attached to this object
71
71
  attr_accessor :tags
72
72
 
73
73
  # Target name
@@ -46,7 +46,7 @@ module Akeyless
46
46
  # Dynamic producer encryption key
47
47
  attr_accessor :producer_encryption_key_name
48
48
 
49
- # List of the tags attached to this secret
49
+ # Add tags attached to this object
50
50
  attr_accessor :tags
51
51
 
52
52
  # Target name
@@ -79,7 +79,7 @@ module Akeyless
79
79
  # Enable Web Secure Remote Access
80
80
  attr_accessor :secure_access_web
81
81
 
82
- # List of the tags attached to this secret
82
+ # Add tags attached to this object
83
83
  attr_accessor :tags
84
84
 
85
85
  # Target name
@@ -67,7 +67,7 @@ module Akeyless
67
67
  # Enable Web Secure Remote Access
68
68
  attr_accessor :secure_access_web
69
69
 
70
- # List of the tags attached to this secret
70
+ # Add tags attached to this object
71
71
  attr_accessor :tags
72
72
 
73
73
  # Target name
@@ -76,7 +76,7 @@ module Akeyless
76
76
  # SSL connection certificate
77
77
  attr_accessor :ssl_certificate
78
78
 
79
- # List of the tags attached to this secret
79
+ # Add tags attached to this object
80
80
  attr_accessor :tags
81
81
 
82
82
  # Target name