akeyless 3.2.5 → 3.2.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +12 -1
- data/docs/CertAccessRules.md +2 -0
- data/docs/CreateAuthMethodCert.md +2 -0
- data/docs/CreateCertificate.md +1 -1
- data/docs/CreateClassicKey.md +1 -1
- data/docs/CreateDynamicSecret.md +1 -1
- data/docs/CreateLinkedTarget.md +1 -3
- data/docs/CreateRotatedSecret.md +1 -1
- data/docs/CreateSecret.md +1 -1
- data/docs/CreateWindowsTarget.md +2 -4
- data/docs/DecryptFile.md +6 -0
- data/docs/DescribeAssoc.md +24 -0
- data/docs/DescribeItem.md +2 -0
- data/docs/DynamicSecretProducerInfo.md +4 -0
- data/docs/EncryptFile.md +0 -2
- data/docs/GatewayBasicInfo.md +24 -0
- data/docs/GatewayCreateProducerArtifactory.md +1 -1
- data/docs/GatewayCreateProducerAws.md +1 -1
- data/docs/GatewayCreateProducerAzure.md +1 -1
- data/docs/GatewayCreateProducerCassandra.md +1 -1
- data/docs/GatewayCreateProducerCertificateAutomation.md +1 -1
- data/docs/GatewayCreateProducerChef.md +1 -1
- data/docs/GatewayCreateProducerCustom.md +1 -1
- data/docs/GatewayCreateProducerDockerhub.md +1 -1
- data/docs/GatewayCreateProducerEks.md +1 -1
- data/docs/GatewayCreateProducerGcp.md +1 -1
- data/docs/GatewayCreateProducerGke.md +1 -1
- data/docs/GatewayCreateProducerHanaDb.md +1 -1
- data/docs/GatewayCreateProducerLdap.md +1 -1
- data/docs/GatewayCreateProducerMSSQL.md +1 -1
- data/docs/GatewayCreateProducerMongo.md +1 -1
- data/docs/GatewayCreateProducerMySQL.md +1 -1
- data/docs/GatewayCreateProducerNativeK8S.md +11 -1
- data/docs/GatewayCreateProducerOracleDb.md +1 -1
- data/docs/GatewayCreateProducerPing.md +1 -1
- data/docs/GatewayCreateProducerPostgreSQL.md +1 -1
- data/docs/GatewayCreateProducerRabbitMQ.md +1 -1
- data/docs/GatewayCreateProducerRdp.md +1 -1
- data/docs/GatewayCreateProducerRedshift.md +1 -1
- data/docs/GatewayCreateProducerSnowflake.md +1 -1
- data/docs/GatewayDownloadCustomerFragments.md +22 -0
- data/docs/GatewayDownloadCustomerFragmentsOutput.md +18 -0
- data/docs/GatewayMessageQueueInfo.md +2 -0
- data/docs/GatewayUpdateProducerArtifactory.md +1 -1
- data/docs/GatewayUpdateProducerAws.md +1 -1
- data/docs/GatewayUpdateProducerAzure.md +1 -1
- data/docs/GatewayUpdateProducerCassandra.md +1 -1
- data/docs/GatewayUpdateProducerCertificateAutomation.md +1 -1
- data/docs/GatewayUpdateProducerChef.md +1 -1
- data/docs/GatewayUpdateProducerCustom.md +1 -1
- data/docs/GatewayUpdateProducerDockerhub.md +1 -1
- data/docs/GatewayUpdateProducerEks.md +1 -1
- data/docs/GatewayUpdateProducerGcp.md +1 -1
- data/docs/GatewayUpdateProducerGke.md +1 -1
- data/docs/GatewayUpdateProducerHanaDb.md +1 -1
- data/docs/GatewayUpdateProducerLdap.md +1 -1
- data/docs/GatewayUpdateProducerMSSQL.md +1 -1
- data/docs/GatewayUpdateProducerMongo.md +1 -1
- data/docs/GatewayUpdateProducerMySQL.md +1 -1
- data/docs/GatewayUpdateProducerNativeK8S.md +11 -1
- data/docs/GatewayUpdateProducerOracleDb.md +1 -1
- data/docs/GatewayUpdateProducerPing.md +1 -1
- data/docs/GatewayUpdateProducerPostgreSQL.md +1 -1
- data/docs/GatewayUpdateProducerRabbitMQ.md +1 -1
- data/docs/GatewayUpdateProducerRdp.md +1 -1
- data/docs/GatewayUpdateProducerRedshift.md +1 -1
- data/docs/GatewayUpdateProducerSnowflake.md +1 -1
- data/docs/GeneralConfigPart.md +2 -0
- data/docs/ImportPasswords.md +32 -0
- data/docs/ImportPasswordsOutput.md +22 -0
- data/docs/Item.md +4 -0
- data/docs/LinkedDetails.md +18 -0
- data/docs/RoleAssociationDetails.md +26 -0
- data/docs/TargetTypeDetailsInput.md +1 -3
- data/docs/UpdateAuthMethodCert.md +2 -0
- data/docs/UpdateLinkedTarget.md +2 -4
- data/docs/UpdateWindowsTarget.md +2 -4
- data/docs/V2Api.md +191 -2
- data/lib/akeyless/api/v2_api.rb +192 -0
- data/lib/akeyless/configuration.rb +5 -0
- data/lib/akeyless/models/cert_access_rules.rb +13 -1
- data/lib/akeyless/models/create_auth_method_cert.rb +11 -1
- data/lib/akeyless/models/create_certificate.rb +1 -1
- data/lib/akeyless/models/create_classic_key.rb +1 -1
- data/lib/akeyless/models/create_dynamic_secret.rb +1 -1
- data/lib/akeyless/models/create_linked_target.rb +2 -17
- data/lib/akeyless/models/create_rotated_secret.rb +1 -1
- data/lib/akeyless/models/create_secret.rb +1 -1
- data/lib/akeyless/models/create_windows_target.rb +9 -19
- data/lib/akeyless/models/decrypt_file.rb +35 -1
- data/lib/akeyless/models/describe_assoc.rb +257 -0
- data/lib/akeyless/models/describe_item.rb +13 -1
- data/lib/akeyless/models/dynamic_secret_producer_info.rb +21 -1
- data/lib/akeyless/models/encrypt_file.rb +1 -13
- data/lib/akeyless/models/gateway_basic_info.rb +246 -0
- data/lib/akeyless/models/gateway_create_producer_artifactory.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_aws.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_azure.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_cassandra.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_certificate_automation.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_chef.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_custom.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_dockerhub.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_eks.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_gcp.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_gke.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_hana_db.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_ldap.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_mongo.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_mssql.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_my_sql.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_native_k8_s.rb +52 -2
- data/lib/akeyless/models/gateway_create_producer_oracle_db.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_ping.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_postgre_sql.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_rabbit_mq.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_rdp.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_redshift.rb +1 -1
- data/lib/akeyless/models/gateway_create_producer_snowflake.rb +1 -1
- data/lib/akeyless/models/gateway_download_customer_fragments.rb +243 -0
- data/lib/akeyless/models/gateway_download_customer_fragments_output.rb +221 -0
- data/lib/akeyless/models/gateway_message_queue_info.rb +10 -1
- data/lib/akeyless/models/gateway_update_producer_artifactory.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_aws.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_azure.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_cassandra.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_certificate_automation.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_chef.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_custom.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_dockerhub.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_eks.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_gcp.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_gke.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_hana_db.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_ldap.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_mongo.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_mssql.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_my_sql.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_native_k8_s.rb +52 -2
- data/lib/akeyless/models/gateway_update_producer_oracle_db.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_ping.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_postgre_sql.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_rabbit_mq.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_rdp.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_redshift.rb +1 -1
- data/lib/akeyless/models/gateway_update_producer_snowflake.rb +1 -1
- data/lib/akeyless/models/general_config_part.rb +10 -1
- data/lib/akeyless/models/import_passwords.rb +304 -0
- data/lib/akeyless/models/import_passwords_output.rb +237 -0
- data/lib/akeyless/models/item.rb +21 -1
- data/lib/akeyless/models/linked_details.rb +221 -0
- data/lib/akeyless/models/role_association_details.rb +258 -0
- data/lib/akeyless/models/target_type_details_input.rb +3 -12
- data/lib/akeyless/models/update_auth_method_cert.rb +11 -1
- data/lib/akeyless/models/update_linked_target.rb +3 -18
- data/lib/akeyless/models/update_windows_target.rb +9 -19
- data/lib/akeyless/version.rb +1 -1
- data/lib/akeyless.rb +8 -0
- data/spec/models/describe_assoc_spec.rb +52 -0
- data/spec/models/gateway_basic_info_spec.rb +52 -0
- data/spec/models/gateway_download_customer_fragments_output_spec.rb +34 -0
- data/spec/models/gateway_download_customer_fragments_spec.rb +46 -0
- data/spec/models/import_passwords_output_spec.rb +46 -0
- data/spec/models/import_passwords_spec.rb +76 -0
- data/spec/models/linked_details_spec.rb +34 -0
- data/spec/models/role_association_details_spec.rb +58 -0
- metadata +34 -2
@@ -0,0 +1,237 @@
|
|
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 ImportPasswordsOutput
|
18
|
+
attr_accessor :imported
|
19
|
+
|
20
|
+
attr_accessor :passwords_in_file
|
21
|
+
|
22
|
+
attr_accessor :successfully_parsed
|
23
|
+
|
24
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
25
|
+
def self.attribute_map
|
26
|
+
{
|
27
|
+
:'imported' => :'imported',
|
28
|
+
:'passwords_in_file' => :'passwords_in_file',
|
29
|
+
:'successfully_parsed' => :'successfully_parsed'
|
30
|
+
}
|
31
|
+
end
|
32
|
+
|
33
|
+
# Returns all the JSON keys this model knows about
|
34
|
+
def self.acceptable_attributes
|
35
|
+
attribute_map.values
|
36
|
+
end
|
37
|
+
|
38
|
+
# Attribute type mapping.
|
39
|
+
def self.openapi_types
|
40
|
+
{
|
41
|
+
:'imported' => :'Integer',
|
42
|
+
:'passwords_in_file' => :'Integer',
|
43
|
+
:'successfully_parsed' => :'Integer'
|
44
|
+
}
|
45
|
+
end
|
46
|
+
|
47
|
+
# List of attributes with nullable: true
|
48
|
+
def self.openapi_nullable
|
49
|
+
Set.new([
|
50
|
+
])
|
51
|
+
end
|
52
|
+
|
53
|
+
# Initializes the object
|
54
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
55
|
+
def initialize(attributes = {})
|
56
|
+
if (!attributes.is_a?(Hash))
|
57
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `Akeyless::ImportPasswordsOutput` initialize method"
|
58
|
+
end
|
59
|
+
|
60
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
61
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
62
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
63
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `Akeyless::ImportPasswordsOutput`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
64
|
+
end
|
65
|
+
h[k.to_sym] = v
|
66
|
+
}
|
67
|
+
|
68
|
+
if attributes.key?(:'imported')
|
69
|
+
self.imported = attributes[:'imported']
|
70
|
+
end
|
71
|
+
|
72
|
+
if attributes.key?(:'passwords_in_file')
|
73
|
+
self.passwords_in_file = attributes[:'passwords_in_file']
|
74
|
+
end
|
75
|
+
|
76
|
+
if attributes.key?(:'successfully_parsed')
|
77
|
+
self.successfully_parsed = attributes[:'successfully_parsed']
|
78
|
+
end
|
79
|
+
end
|
80
|
+
|
81
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
82
|
+
# @return Array for valid properties with the reasons
|
83
|
+
def list_invalid_properties
|
84
|
+
invalid_properties = Array.new
|
85
|
+
invalid_properties
|
86
|
+
end
|
87
|
+
|
88
|
+
# Check to see if the all the properties in the model are valid
|
89
|
+
# @return true if the model is valid
|
90
|
+
def valid?
|
91
|
+
true
|
92
|
+
end
|
93
|
+
|
94
|
+
# Checks equality by comparing each attribute.
|
95
|
+
# @param [Object] Object to be compared
|
96
|
+
def ==(o)
|
97
|
+
return true if self.equal?(o)
|
98
|
+
self.class == o.class &&
|
99
|
+
imported == o.imported &&
|
100
|
+
passwords_in_file == o.passwords_in_file &&
|
101
|
+
successfully_parsed == o.successfully_parsed
|
102
|
+
end
|
103
|
+
|
104
|
+
# @see the `==` method
|
105
|
+
# @param [Object] Object to be compared
|
106
|
+
def eql?(o)
|
107
|
+
self == o
|
108
|
+
end
|
109
|
+
|
110
|
+
# Calculates hash code according to all attributes.
|
111
|
+
# @return [Integer] Hash code
|
112
|
+
def hash
|
113
|
+
[imported, passwords_in_file, successfully_parsed].hash
|
114
|
+
end
|
115
|
+
|
116
|
+
# Builds the object from hash
|
117
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
118
|
+
# @return [Object] Returns the model itself
|
119
|
+
def self.build_from_hash(attributes)
|
120
|
+
new.build_from_hash(attributes)
|
121
|
+
end
|
122
|
+
|
123
|
+
# Builds the object from hash
|
124
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
125
|
+
# @return [Object] Returns the model itself
|
126
|
+
def build_from_hash(attributes)
|
127
|
+
return nil unless attributes.is_a?(Hash)
|
128
|
+
attributes = attributes.transform_keys(&:to_sym)
|
129
|
+
self.class.openapi_types.each_pair do |key, type|
|
130
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
131
|
+
self.send("#{key}=", nil)
|
132
|
+
elsif type =~ /\AArray<(.*)>/i
|
133
|
+
# check to ensure the input is an array given that the attribute
|
134
|
+
# is documented as an array but the input is not
|
135
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
136
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
137
|
+
end
|
138
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
139
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
140
|
+
end
|
141
|
+
end
|
142
|
+
|
143
|
+
self
|
144
|
+
end
|
145
|
+
|
146
|
+
# Deserializes the data based on type
|
147
|
+
# @param string type Data type
|
148
|
+
# @param string value Value to be deserialized
|
149
|
+
# @return [Object] Deserialized data
|
150
|
+
def _deserialize(type, value)
|
151
|
+
case type.to_sym
|
152
|
+
when :Time
|
153
|
+
Time.parse(value)
|
154
|
+
when :Date
|
155
|
+
Date.parse(value)
|
156
|
+
when :String
|
157
|
+
value.to_s
|
158
|
+
when :Integer
|
159
|
+
value.to_i
|
160
|
+
when :Float
|
161
|
+
value.to_f
|
162
|
+
when :Boolean
|
163
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
164
|
+
true
|
165
|
+
else
|
166
|
+
false
|
167
|
+
end
|
168
|
+
when :Object
|
169
|
+
# generic object (usually a Hash), return directly
|
170
|
+
value
|
171
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
172
|
+
inner_type = Regexp.last_match[:inner_type]
|
173
|
+
value.map { |v| _deserialize(inner_type, v) }
|
174
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
175
|
+
k_type = Regexp.last_match[:k_type]
|
176
|
+
v_type = Regexp.last_match[:v_type]
|
177
|
+
{}.tap do |hash|
|
178
|
+
value.each do |k, v|
|
179
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
180
|
+
end
|
181
|
+
end
|
182
|
+
else # model
|
183
|
+
# models (e.g. Pet) or oneOf
|
184
|
+
klass = Akeyless.const_get(type)
|
185
|
+
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
186
|
+
end
|
187
|
+
end
|
188
|
+
|
189
|
+
# Returns the string representation of the object
|
190
|
+
# @return [String] String presentation of the object
|
191
|
+
def to_s
|
192
|
+
to_hash.to_s
|
193
|
+
end
|
194
|
+
|
195
|
+
# to_body is an alias to to_hash (backward compatibility)
|
196
|
+
# @return [Hash] Returns the object in the form of hash
|
197
|
+
def to_body
|
198
|
+
to_hash
|
199
|
+
end
|
200
|
+
|
201
|
+
# Returns the object in the form of hash
|
202
|
+
# @return [Hash] Returns the object in the form of hash
|
203
|
+
def to_hash
|
204
|
+
hash = {}
|
205
|
+
self.class.attribute_map.each_pair do |attr, param|
|
206
|
+
value = self.send(attr)
|
207
|
+
if value.nil?
|
208
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
209
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
210
|
+
end
|
211
|
+
|
212
|
+
hash[param] = _to_hash(value)
|
213
|
+
end
|
214
|
+
hash
|
215
|
+
end
|
216
|
+
|
217
|
+
# Outputs non-array value in the form of hash
|
218
|
+
# For object, use to_hash. Otherwise, just return the value
|
219
|
+
# @param [Object] value Any valid value
|
220
|
+
# @return [Hash] Returns the value in the form of hash
|
221
|
+
def _to_hash(value)
|
222
|
+
if value.is_a?(Array)
|
223
|
+
value.compact.map { |v| _to_hash(v) }
|
224
|
+
elsif value.is_a?(Hash)
|
225
|
+
{}.tap do |hash|
|
226
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
227
|
+
end
|
228
|
+
elsif value.respond_to? :to_hash
|
229
|
+
value.to_hash
|
230
|
+
else
|
231
|
+
value
|
232
|
+
end
|
233
|
+
end
|
234
|
+
|
235
|
+
end
|
236
|
+
|
237
|
+
end
|
data/lib/akeyless/models/item.rb
CHANGED
@@ -39,6 +39,8 @@ module Akeyless
|
|
39
39
|
|
40
40
|
attr_accessor :display_id
|
41
41
|
|
42
|
+
attr_accessor :gateway_details
|
43
|
+
|
42
44
|
attr_accessor :is_access_request_enabled
|
43
45
|
|
44
46
|
attr_accessor :is_enabled
|
@@ -70,6 +72,8 @@ module Akeyless
|
|
70
72
|
|
71
73
|
attr_accessor :last_version
|
72
74
|
|
75
|
+
attr_accessor :linked_details
|
76
|
+
|
73
77
|
attr_accessor :modification_date
|
74
78
|
|
75
79
|
attr_accessor :next_rotation_date
|
@@ -103,6 +107,7 @@ module Akeyless
|
|
103
107
|
:'delete_protection' => :'delete_protection',
|
104
108
|
:'deletion_date' => :'deletion_date',
|
105
109
|
:'display_id' => :'display_id',
|
110
|
+
:'gateway_details' => :'gateway_details',
|
106
111
|
:'is_access_request_enabled' => :'is_access_request_enabled',
|
107
112
|
:'is_enabled' => :'is_enabled',
|
108
113
|
:'item_accessibility' => :'item_accessibility',
|
@@ -118,6 +123,7 @@ module Akeyless
|
|
118
123
|
:'item_type' => :'item_type',
|
119
124
|
:'item_versions' => :'item_versions',
|
120
125
|
:'last_version' => :'last_version',
|
126
|
+
:'linked_details' => :'linked_details',
|
121
127
|
:'modification_date' => :'modification_date',
|
122
128
|
:'next_rotation_date' => :'next_rotation_date',
|
123
129
|
:'protection_key_name' => :'protection_key_name',
|
@@ -150,6 +156,7 @@ module Akeyless
|
|
150
156
|
:'delete_protection' => :'Boolean',
|
151
157
|
:'deletion_date' => :'Time',
|
152
158
|
:'display_id' => :'String',
|
159
|
+
:'gateway_details' => :'Array<GatewayBasicInfo>',
|
153
160
|
:'is_access_request_enabled' => :'Boolean',
|
154
161
|
:'is_enabled' => :'Boolean',
|
155
162
|
:'item_accessibility' => :'Integer',
|
@@ -165,6 +172,7 @@ module Akeyless
|
|
165
172
|
:'item_type' => :'String',
|
166
173
|
:'item_versions' => :'Array<ItemVersion>',
|
167
174
|
:'last_version' => :'Integer',
|
175
|
+
:'linked_details' => :'LinkedDetails',
|
168
176
|
:'modification_date' => :'Time',
|
169
177
|
:'next_rotation_date' => :'Time',
|
170
178
|
:'protection_key_name' => :'String',
|
@@ -248,6 +256,12 @@ module Akeyless
|
|
248
256
|
self.display_id = attributes[:'display_id']
|
249
257
|
end
|
250
258
|
|
259
|
+
if attributes.key?(:'gateway_details')
|
260
|
+
if (value = attributes[:'gateway_details']).is_a?(Array)
|
261
|
+
self.gateway_details = value
|
262
|
+
end
|
263
|
+
end
|
264
|
+
|
251
265
|
if attributes.key?(:'is_access_request_enabled')
|
252
266
|
self.is_access_request_enabled = attributes[:'is_access_request_enabled']
|
253
267
|
end
|
@@ -314,6 +328,10 @@ module Akeyless
|
|
314
328
|
self.last_version = attributes[:'last_version']
|
315
329
|
end
|
316
330
|
|
331
|
+
if attributes.key?(:'linked_details')
|
332
|
+
self.linked_details = attributes[:'linked_details']
|
333
|
+
end
|
334
|
+
|
317
335
|
if attributes.key?(:'modification_date')
|
318
336
|
self.modification_date = attributes[:'modification_date']
|
319
337
|
end
|
@@ -383,6 +401,7 @@ module Akeyless
|
|
383
401
|
delete_protection == o.delete_protection &&
|
384
402
|
deletion_date == o.deletion_date &&
|
385
403
|
display_id == o.display_id &&
|
404
|
+
gateway_details == o.gateway_details &&
|
386
405
|
is_access_request_enabled == o.is_access_request_enabled &&
|
387
406
|
is_enabled == o.is_enabled &&
|
388
407
|
item_accessibility == o.item_accessibility &&
|
@@ -398,6 +417,7 @@ module Akeyless
|
|
398
417
|
item_type == o.item_type &&
|
399
418
|
item_versions == o.item_versions &&
|
400
419
|
last_version == o.last_version &&
|
420
|
+
linked_details == o.linked_details &&
|
401
421
|
modification_date == o.modification_date &&
|
402
422
|
next_rotation_date == o.next_rotation_date &&
|
403
423
|
protection_key_name == o.protection_key_name &&
|
@@ -418,7 +438,7 @@ module Akeyless
|
|
418
438
|
# Calculates hash code according to all attributes.
|
419
439
|
# @return [Integer] Hash code
|
420
440
|
def hash
|
421
|
-
[access_date, access_request_status, auto_rotate, cert_issuer_signer_key_name, certificate_issue_details, certificates, client_permissions, creation_date, customer_fragment_id, delete_protection, deletion_date, display_id, is_access_request_enabled, is_enabled, item_accessibility, item_general_info, item_id, item_metadata, item_name, item_size, item_state, item_sub_type, item_tags, item_targets_assoc, item_type, item_versions, last_version, modification_date, next_rotation_date, protection_key_name, protection_key_type, public_value, rotation_interval, shared_by, target_versions, with_customer_fragment].hash
|
441
|
+
[access_date, access_request_status, auto_rotate, cert_issuer_signer_key_name, certificate_issue_details, certificates, client_permissions, creation_date, customer_fragment_id, delete_protection, deletion_date, display_id, gateway_details, is_access_request_enabled, is_enabled, item_accessibility, item_general_info, item_id, item_metadata, item_name, item_size, item_state, item_sub_type, item_tags, item_targets_assoc, item_type, item_versions, last_version, linked_details, modification_date, next_rotation_date, protection_key_name, protection_key_type, public_value, rotation_interval, shared_by, target_versions, with_customer_fragment].hash
|
422
442
|
end
|
423
443
|
|
424
444
|
# Builds the object from hash
|
@@ -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 LinkedDetails
|
18
|
+
attr_accessor :hosts
|
19
|
+
|
20
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
21
|
+
def self.attribute_map
|
22
|
+
{
|
23
|
+
:'hosts' => :'hosts'
|
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
|
+
:'hosts' => :'Hash<String, String>'
|
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::LinkedDetails` 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::LinkedDetails`. 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?(:'hosts')
|
61
|
+
if (value = attributes[:'hosts']).is_a?(Hash)
|
62
|
+
self.hosts = 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
|
+
hosts == o.hosts
|
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
|
+
[hosts].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
|