incident_io_api 2.63.0 → 2.65.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b7c49bf3e8e54517310b3469c189f30a6d682fa8db6945ee540995f1adecf12d
4
- data.tar.gz: 827ebb357c9551a855087e2ee51ad5df595d6a965af1dcf1e698bb7e9fa42d29
3
+ metadata.gz: df5eff1e62f0722d08d72da7921970c6a0122ec9cff3563ac20a2863dbfdb9a8
4
+ data.tar.gz: f4c5a7ef795fb712f201b9b49bbd9c565bcd06dc823b2c8797c8983fad8947a8
5
5
  SHA512:
6
- metadata.gz: a275d13b2c0d48f60da7037c9d154366c493d77b9b401c36c43d6d8a1b6fbababd8adfa98b7eb30cd7812f26b32033a8a2d84c738a89e1b6d9f75ebcda550f75
7
- data.tar.gz: 20f8aabce5ebd403eb50e7af6a7fafdff2202e1b23821bcb3dcad5e8e7d992169427d68160173bef36e9a3cf7db6d9df81ed554a681ff9958b4f248ea595f9e5
6
+ metadata.gz: f1b9fa2fa4a28081ef8cdd30b10353ce6813632436f280cbc0822cf2f302e00d4d8497861028ce9238679d2642eeaeaff6e0a9d1a9cdf2fa2cd9a39fd663aa53
7
+ data.tar.gz: 1261484f739c2a406ce3eefee4664c592bd2a686ade8bba64a4e12ee4accf1938ef38cbdcb834c5109d009271c6f865959adb4c5cb038680b5c84857813fe276
@@ -0,0 +1,148 @@
1
+ =begin
2
+ #incident.io
3
+
4
+ #Ruby client for the incident.io API.
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.25.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module IncidentIo
17
+ class AuditLogAPIKeyExpiryMetadataV2 < ApiModelBase
18
+ # When the key stops working. Absent when the key never expires.
19
+ attr_accessor :expires_at
20
+
21
+ # Attribute mapping from ruby-style variable name to JSON key.
22
+ def self.attribute_map
23
+ {
24
+ :'expires_at' => :'expires_at'
25
+ }
26
+ end
27
+
28
+ # Returns attribute mapping this model knows about
29
+ def self.acceptable_attribute_map
30
+ attribute_map
31
+ end
32
+
33
+ # Returns all the JSON keys this model knows about
34
+ def self.acceptable_attributes
35
+ acceptable_attribute_map.values
36
+ end
37
+
38
+ # Attribute type mapping.
39
+ def self.openapi_types
40
+ {
41
+ :'expires_at' => :'String'
42
+ }
43
+ end
44
+
45
+ # List of attributes with nullable: true
46
+ def self.openapi_nullable
47
+ Set.new([
48
+ ])
49
+ end
50
+
51
+ # Initializes the object
52
+ # @param [Hash] attributes Model attributes in the form of hash
53
+ def initialize(attributes = {})
54
+ if (!attributes.is_a?(Hash))
55
+ fail ArgumentError, "The input argument (attributes) must be a hash in `IncidentIo::AuditLogAPIKeyExpiryMetadataV2` 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
+ fail ArgumentError, "`#{k}` is not a valid attribute in `IncidentIo::AuditLogAPIKeyExpiryMetadataV2`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
63
+ end
64
+ h[k.to_sym] = v
65
+ }
66
+
67
+ if attributes.key?(:'expires_at')
68
+ self.expires_at = attributes[:'expires_at']
69
+ end
70
+ end
71
+
72
+ # Show invalid properties with the reasons. Usually used together with valid?
73
+ # @return Array for valid properties with the reasons
74
+ def list_invalid_properties
75
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
76
+ invalid_properties = Array.new
77
+ invalid_properties
78
+ end
79
+
80
+ # Check to see if the all the properties in the model are valid
81
+ # @return true if the model is valid
82
+ def valid?
83
+ warn '[DEPRECATED] the `valid?` method is obsolete'
84
+ true
85
+ end
86
+
87
+ # Checks equality by comparing each attribute.
88
+ # @param [Object] Object to be compared
89
+ def ==(o)
90
+ return true if self.equal?(o)
91
+ self.class == o.class &&
92
+ expires_at == o.expires_at
93
+ end
94
+
95
+ # @see the `==` method
96
+ # @param [Object] Object to be compared
97
+ def eql?(o)
98
+ self == o
99
+ end
100
+
101
+ # Calculates hash code according to all attributes.
102
+ # @return [Integer] Hash code
103
+ def hash
104
+ [expires_at].hash
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 self.build_from_hash(attributes)
111
+ return nil unless attributes.is_a?(Hash)
112
+ attributes = attributes.transform_keys(&:to_sym)
113
+ transformed_hash = {}
114
+ openapi_types.each_pair do |key, type|
115
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
116
+ transformed_hash["#{key}"] = nil
117
+ elsif type =~ /\AArray<(.*)>/i
118
+ # check to ensure the input is an array given that the attribute
119
+ # is documented as an array but the input is not
120
+ if attributes[attribute_map[key]].is_a?(Array)
121
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
122
+ end
123
+ elsif !attributes[attribute_map[key]].nil?
124
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
125
+ end
126
+ end
127
+ new(transformed_hash)
128
+ end
129
+
130
+ # Returns the object in the form of hash
131
+ # @return [Hash] Returns the object in the form of hash
132
+ def to_hash
133
+ hash = {}
134
+ self.class.attribute_map.each_pair do |attr, param|
135
+ value = self.send(attr)
136
+ if value.nil?
137
+ is_nullable = self.class.openapi_nullable.include?(attr)
138
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
139
+ end
140
+
141
+ hash[param] = _to_hash(value)
142
+ end
143
+ hash
144
+ end
145
+
146
+ end
147
+
148
+ end
@@ -0,0 +1,175 @@
1
+ =begin
2
+ #incident.io
3
+
4
+ #Ruby client for the incident.io API.
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.25.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module IncidentIo
17
+ class AuditLogAPIKeyExpiryPolicyUpdatedMetadataV2 < ApiModelBase
18
+ # Whether new API keys must have an expiry after the update
19
+ attr_accessor :expiry_required
20
+
21
+ # The longest lifetime, in days, a new key may have after the update. Absent when there is no limit.
22
+ attr_accessor :max_lifetime_days
23
+
24
+ # Attribute mapping from ruby-style variable name to JSON key.
25
+ def self.attribute_map
26
+ {
27
+ :'expiry_required' => :'expiry_required',
28
+ :'max_lifetime_days' => :'max_lifetime_days'
29
+ }
30
+ end
31
+
32
+ # Returns attribute mapping this model knows about
33
+ def self.acceptable_attribute_map
34
+ attribute_map
35
+ end
36
+
37
+ # Returns all the JSON keys this model knows about
38
+ def self.acceptable_attributes
39
+ acceptable_attribute_map.values
40
+ end
41
+
42
+ # Attribute type mapping.
43
+ def self.openapi_types
44
+ {
45
+ :'expiry_required' => :'String',
46
+ :'max_lifetime_days' => :'String'
47
+ }
48
+ end
49
+
50
+ # List of attributes with nullable: true
51
+ def self.openapi_nullable
52
+ Set.new([
53
+ ])
54
+ end
55
+
56
+ # Initializes the object
57
+ # @param [Hash] attributes Model attributes in the form of hash
58
+ def initialize(attributes = {})
59
+ if (!attributes.is_a?(Hash))
60
+ fail ArgumentError, "The input argument (attributes) must be a hash in `IncidentIo::AuditLogAPIKeyExpiryPolicyUpdatedMetadataV2` initialize method"
61
+ end
62
+
63
+ # check to see if the attribute exists and convert string to symbol for hash key
64
+ acceptable_attribute_map = self.class.acceptable_attribute_map
65
+ attributes = attributes.each_with_object({}) { |(k, v), h|
66
+ if (!acceptable_attribute_map.key?(k.to_sym))
67
+ fail ArgumentError, "`#{k}` is not a valid attribute in `IncidentIo::AuditLogAPIKeyExpiryPolicyUpdatedMetadataV2`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
68
+ end
69
+ h[k.to_sym] = v
70
+ }
71
+
72
+ if attributes.key?(:'expiry_required')
73
+ self.expiry_required = attributes[:'expiry_required']
74
+ else
75
+ self.expiry_required = nil
76
+ end
77
+
78
+ if attributes.key?(:'max_lifetime_days')
79
+ self.max_lifetime_days = attributes[:'max_lifetime_days']
80
+ end
81
+ end
82
+
83
+ # Show invalid properties with the reasons. Usually used together with valid?
84
+ # @return Array for valid properties with the reasons
85
+ def list_invalid_properties
86
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
87
+ invalid_properties = Array.new
88
+ if @expiry_required.nil?
89
+ invalid_properties.push('invalid value for "expiry_required", expiry_required cannot be nil.')
90
+ end
91
+
92
+ invalid_properties
93
+ end
94
+
95
+ # Check to see if the all the properties in the model are valid
96
+ # @return true if the model is valid
97
+ def valid?
98
+ warn '[DEPRECATED] the `valid?` method is obsolete'
99
+ return false if @expiry_required.nil?
100
+ true
101
+ end
102
+
103
+ # Custom attribute writer method with validation
104
+ # @param [Object] expiry_required Value to be assigned
105
+ def expiry_required=(expiry_required)
106
+ if expiry_required.nil?
107
+ fail ArgumentError, 'expiry_required cannot be nil'
108
+ end
109
+
110
+ @expiry_required = expiry_required
111
+ end
112
+
113
+ # Checks equality by comparing each attribute.
114
+ # @param [Object] Object to be compared
115
+ def ==(o)
116
+ return true if self.equal?(o)
117
+ self.class == o.class &&
118
+ expiry_required == o.expiry_required &&
119
+ max_lifetime_days == o.max_lifetime_days
120
+ end
121
+
122
+ # @see the `==` method
123
+ # @param [Object] Object to be compared
124
+ def eql?(o)
125
+ self == o
126
+ end
127
+
128
+ # Calculates hash code according to all attributes.
129
+ # @return [Integer] Hash code
130
+ def hash
131
+ [expiry_required, max_lifetime_days].hash
132
+ end
133
+
134
+ # Builds the object from hash
135
+ # @param [Hash] attributes Model attributes in the form of hash
136
+ # @return [Object] Returns the model itself
137
+ def self.build_from_hash(attributes)
138
+ return nil unless attributes.is_a?(Hash)
139
+ attributes = attributes.transform_keys(&:to_sym)
140
+ transformed_hash = {}
141
+ openapi_types.each_pair do |key, type|
142
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
143
+ transformed_hash["#{key}"] = nil
144
+ elsif type =~ /\AArray<(.*)>/i
145
+ # check to ensure the input is an array given that the attribute
146
+ # is documented as an array but the input is not
147
+ if attributes[attribute_map[key]].is_a?(Array)
148
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
149
+ end
150
+ elsif !attributes[attribute_map[key]].nil?
151
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
152
+ end
153
+ end
154
+ new(transformed_hash)
155
+ end
156
+
157
+ # Returns the object in the form of hash
158
+ # @return [Hash] Returns the object in the form of hash
159
+ def to_hash
160
+ hash = {}
161
+ self.class.attribute_map.each_pair do |attr, param|
162
+ value = self.send(attr)
163
+ if value.nil?
164
+ is_nullable = self.class.openapi_nullable.include?(attr)
165
+ next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
166
+ end
167
+
168
+ hash[param] = _to_hash(value)
169
+ end
170
+ hash
171
+ end
172
+
173
+ end
174
+
175
+ end
@@ -0,0 +1,212 @@
1
+ =begin
2
+ #incident.io
3
+
4
+ #Ruby client for the incident.io API.
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.25.0
10
+
11
+ =end
12
+
13
+ require 'date'
14
+ require 'time'
15
+
16
+ module IncidentIo
17
+ class AuditLogMobileKeyArchivedMetadataV2 < ApiModelBase
18
+ # The name of the device, absent when the app did not send one
19
+ attr_accessor :device_name
20
+
21
+ # The model of the device, absent when the app did not send one
22
+ attr_accessor :model_name
23
+
24
+ # The device platform, such as ios or android
25
+ attr_accessor :platform
26
+
27
+ # Why the sign-in ended, such as logged_out, user_deleted, user_has_been_deactivated, sessions_revoked, device_unregistered or duplicate_token
28
+ attr_accessor :reason
29
+
30
+ # Attribute mapping from ruby-style variable name to JSON key.
31
+ def self.attribute_map
32
+ {
33
+ :'device_name' => :'device_name',
34
+ :'model_name' => :'model_name',
35
+ :'platform' => :'platform',
36
+ :'reason' => :'reason'
37
+ }
38
+ end
39
+
40
+ # Returns attribute mapping this model knows about
41
+ def self.acceptable_attribute_map
42
+ attribute_map
43
+ end
44
+
45
+ # Returns all the JSON keys this model knows about
46
+ def self.acceptable_attributes
47
+ acceptable_attribute_map.values
48
+ end
49
+
50
+ # Attribute type mapping.
51
+ def self.openapi_types
52
+ {
53
+ :'device_name' => :'String',
54
+ :'model_name' => :'String',
55
+ :'platform' => :'String',
56
+ :'reason' => :'String'
57
+ }
58
+ end
59
+
60
+ # List of attributes with nullable: true
61
+ def self.openapi_nullable
62
+ Set.new([
63
+ ])
64
+ end
65
+
66
+ # Initializes the object
67
+ # @param [Hash] attributes Model attributes in the form of hash
68
+ def initialize(attributes = {})
69
+ if (!attributes.is_a?(Hash))
70
+ fail ArgumentError, "The input argument (attributes) must be a hash in `IncidentIo::AuditLogMobileKeyArchivedMetadataV2` initialize method"
71
+ end
72
+
73
+ # check to see if the attribute exists and convert string to symbol for hash key
74
+ acceptable_attribute_map = self.class.acceptable_attribute_map
75
+ attributes = attributes.each_with_object({}) { |(k, v), h|
76
+ if (!acceptable_attribute_map.key?(k.to_sym))
77
+ fail ArgumentError, "`#{k}` is not a valid attribute in `IncidentIo::AuditLogMobileKeyArchivedMetadataV2`. Please check the name to make sure it's valid. List of attributes: " + acceptable_attribute_map.keys.inspect
78
+ end
79
+ h[k.to_sym] = v
80
+ }
81
+
82
+ if attributes.key?(:'device_name')
83
+ self.device_name = attributes[:'device_name']
84
+ end
85
+
86
+ if attributes.key?(:'model_name')
87
+ self.model_name = attributes[:'model_name']
88
+ end
89
+
90
+ if attributes.key?(:'platform')
91
+ self.platform = attributes[:'platform']
92
+ else
93
+ self.platform = nil
94
+ end
95
+
96
+ if attributes.key?(:'reason')
97
+ self.reason = attributes[:'reason']
98
+ else
99
+ self.reason = nil
100
+ end
101
+ end
102
+
103
+ # Show invalid properties with the reasons. Usually used together with valid?
104
+ # @return Array for valid properties with the reasons
105
+ def list_invalid_properties
106
+ warn '[DEPRECATED] the `list_invalid_properties` method is obsolete'
107
+ invalid_properties = Array.new
108
+ if @platform.nil?
109
+ invalid_properties.push('invalid value for "platform", platform cannot be nil.')
110
+ end
111
+
112
+ if @reason.nil?
113
+ invalid_properties.push('invalid value for "reason", reason cannot be nil.')
114
+ end
115
+
116
+ invalid_properties
117
+ end
118
+
119
+ # Check to see if the all the properties in the model are valid
120
+ # @return true if the model is valid
121
+ def valid?
122
+ warn '[DEPRECATED] the `valid?` method is obsolete'
123
+ return false if @platform.nil?
124
+ return false if @reason.nil?
125
+ true
126
+ end
127
+
128
+ # Custom attribute writer method with validation
129
+ # @param [Object] platform Value to be assigned
130
+ def platform=(platform)
131
+ if platform.nil?
132
+ fail ArgumentError, 'platform cannot be nil'
133
+ end
134
+
135
+ @platform = platform
136
+ end
137
+
138
+ # Custom attribute writer method with validation
139
+ # @param [Object] reason Value to be assigned
140
+ def reason=(reason)
141
+ if reason.nil?
142
+ fail ArgumentError, 'reason cannot be nil'
143
+ end
144
+
145
+ @reason = reason
146
+ end
147
+
148
+ # Checks equality by comparing each attribute.
149
+ # @param [Object] Object to be compared
150
+ def ==(o)
151
+ return true if self.equal?(o)
152
+ self.class == o.class &&
153
+ device_name == o.device_name &&
154
+ model_name == o.model_name &&
155
+ platform == o.platform &&
156
+ reason == o.reason
157
+ end
158
+
159
+ # @see the `==` method
160
+ # @param [Object] Object to be compared
161
+ def eql?(o)
162
+ self == o
163
+ end
164
+
165
+ # Calculates hash code according to all attributes.
166
+ # @return [Integer] Hash code
167
+ def hash
168
+ [device_name, model_name, platform, reason].hash
169
+ end
170
+
171
+ # Builds the object from hash
172
+ # @param [Hash] attributes Model attributes in the form of hash
173
+ # @return [Object] Returns the model itself
174
+ def self.build_from_hash(attributes)
175
+ return nil unless attributes.is_a?(Hash)
176
+ attributes = attributes.transform_keys(&:to_sym)
177
+ transformed_hash = {}
178
+ openapi_types.each_pair do |key, type|
179
+ if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
180
+ transformed_hash["#{key}"] = nil
181
+ elsif type =~ /\AArray<(.*)>/i
182
+ # check to ensure the input is an array given that the attribute
183
+ # is documented as an array but the input is not
184
+ if attributes[attribute_map[key]].is_a?(Array)
185
+ transformed_hash["#{key}"] = attributes[attribute_map[key]].map { |v| _deserialize($1, v) }
186
+ end
187
+ elsif !attributes[attribute_map[key]].nil?
188
+ transformed_hash["#{key}"] = _deserialize(type, attributes[attribute_map[key]])
189
+ end
190
+ end
191
+ new(transformed_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 = {}
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
+ end
211
+
212
+ end