notifo-io 1.0.1 → 1.0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +510 -8
- data/Rakefile +0 -2
- data/docs/AddAllowedTopicDto.md +3 -14
- data/docs/AddContributorDto.md +4 -16
- data/docs/AppContributorDto.md +5 -18
- data/docs/AppDetailsDto.md +18 -44
- data/docs/AppDto.md +8 -24
- data/docs/AppsApi.md +149 -331
- data/docs/Body.md +7 -0
- data/docs/ConfigsApi.md +21 -61
- data/docs/ConfirmMode.md +2 -11
- data/docs/CreateEmailTemplateDto.md +3 -14
- data/docs/EmailTemplateDto.md +5 -18
- data/docs/EmailTemplatesDto.md +6 -0
- data/docs/EmailVerificationStatus.md +2 -11
- data/docs/ErrorDto.md +7 -22
- data/docs/EventDto.md +14 -36
- data/docs/EventProperties.md +6 -0
- data/docs/EventsApi.md +36 -73
- data/docs/IsoDayOfWeek.md +2 -11
- data/docs/ListResponseDtoOfEventDto.md +4 -16
- data/docs/ListResponseDtoOfLogEntryDto.md +4 -16
- data/docs/ListResponseDtoOfMediaDto.md +4 -16
- data/docs/ListResponseDtoOfSubscriptionDto.md +4 -16
- data/docs/ListResponseDtoOfTemplateDto.md +4 -16
- data/docs/ListResponseDtoOfTopicDto.md +4 -16
- data/docs/ListResponseDtoOfUserDto.md +4 -16
- data/docs/LocalizedText.md +6 -0
- data/docs/LogEntryDto.md +6 -20
- data/docs/LogsApi.md +21 -40
- data/docs/MediaApi.md +102 -196
- data/docs/MediaDto.md +9 -26
- data/docs/MediaMetadata.md +6 -0
- data/docs/MediaType.md +2 -11
- data/docs/NotificationFormattingDto.md +10 -28
- data/docs/NotificationSend.md +2 -11
- data/docs/NotificationSettingDto.md +4 -16
- data/docs/ProfileDto.md +10 -28
- data/docs/PublishDto.md +12 -32
- data/docs/PublishManyDto.md +3 -14
- data/docs/ResizeMode.md +2 -11
- data/docs/SchedulingDto.md +6 -20
- data/docs/SchedulingType.md +2 -11
- data/docs/SubscriptionDto.md +4 -16
- data/docs/TemplateDto.md +5 -18
- data/docs/TemplatesApi.md +51 -106
- data/docs/TopicDto.md +5 -18
- data/docs/TopicsApi.md +21 -40
- data/docs/UpdateProfileDto.md +8 -24
- data/docs/UpsertAppDto.md +12 -32
- data/docs/UpsertTemplateDto.md +5 -18
- data/docs/UpsertTemplatesDto.md +3 -14
- data/docs/UpsertUserDto.md +10 -28
- data/docs/UpsertUsersDto.md +3 -14
- data/docs/UserApi.md +68 -160
- data/docs/UserDto.md +12 -32
- data/docs/UsersApi.md +144 -308
- data/git_push.sh +7 -10
- data/lib/notifo.rb +9 -5
- data/lib/notifo/api/apps_api.rb +130 -202
- data/lib/notifo/api/configs_api.rb +14 -30
- data/lib/notifo/api/events_api.rb +29 -45
- data/lib/notifo/api/logs_api.rb +12 -21
- data/lib/notifo/api/media_api.rb +60 -97
- data/lib/notifo/api/templates_api.rb +39 -62
- data/lib/notifo/api/topics_api.rb +12 -21
- data/lib/notifo/api/user_api.rb +51 -88
- data/lib/notifo/api/users_api.rb +121 -186
- data/lib/notifo/api_client.rb +54 -56
- data/lib/notifo/api_error.rb +5 -5
- data/lib/notifo/configuration.rb +12 -84
- data/lib/notifo/models/add_allowed_topic_dto.rb +13 -44
- data/lib/notifo/models/add_contributor_dto.rb +14 -64
- data/lib/notifo/models/app_contributor_dto.rb +15 -84
- data/lib/notifo/models/app_details_dto.rb +28 -103
- data/lib/notifo/models/app_dto.rb +18 -87
- data/lib/notifo/models/{inline_object.rb → body.rb} +16 -29
- data/lib/notifo/models/confirm_mode.rb +7 -16
- data/lib/notifo/models/create_email_template_dto.rb +13 -44
- data/lib/notifo/models/email_template_dto.rb +15 -66
- data/lib/notifo/models/email_templates_dto.rb +201 -0
- data/lib/notifo/models/email_verification_status.rb +8 -17
- data/lib/notifo/models/error_dto.rb +17 -33
- data/lib/notifo/models/event_dto.rb +24 -114
- data/lib/notifo/models/event_properties.rb +201 -0
- data/lib/notifo/models/iso_day_of_week.rb +12 -21
- data/lib/notifo/models/list_response_dto_of_event_dto.rb +14 -26
- data/lib/notifo/models/list_response_dto_of_log_entry_dto.rb +14 -26
- data/lib/notifo/models/list_response_dto_of_media_dto.rb +14 -26
- data/lib/notifo/models/list_response_dto_of_subscription_dto.rb +14 -26
- data/lib/notifo/models/list_response_dto_of_template_dto.rb +14 -26
- data/lib/notifo/models/list_response_dto_of_topic_dto.rb +14 -26
- data/lib/notifo/models/list_response_dto_of_user_dto.rb +14 -26
- data/lib/notifo/models/localized_text.rb +201 -0
- data/lib/notifo/models/log_entry_dto.rb +16 -85
- data/lib/notifo/models/media_dto.rb +20 -110
- data/lib/notifo/models/media_metadata.rb +201 -0
- data/lib/notifo/models/media_type.rb +8 -17
- data/lib/notifo/models/notification_formatting_dto.rb +27 -53
- data/lib/notifo/models/notification_send.rb +8 -17
- data/lib/notifo/models/notification_setting_dto.rb +23 -36
- data/lib/notifo/models/profile_dto.rb +20 -73
- data/lib/notifo/models/publish_dto.rb +23 -60
- data/lib/notifo/models/publish_many_dto.rb +13 -25
- data/lib/notifo/models/resize_mode.rb +11 -20
- data/lib/notifo/models/scheduling_dto.rb +16 -29
- data/lib/notifo/models/scheduling_type.rb +6 -15
- data/lib/notifo/models/subscription_dto.rb +14 -46
- data/lib/notifo/models/template_dto.rb +15 -46
- data/lib/notifo/models/topic_dto.rb +15 -65
- data/lib/notifo/models/update_profile_dto.rb +18 -36
- data/lib/notifo/models/upsert_app_dto.rb +22 -44
- data/lib/notifo/models/upsert_template_dto.rb +15 -47
- data/lib/notifo/models/upsert_templates_dto.rb +13 -25
- data/lib/notifo/models/upsert_user_dto.rb +20 -40
- data/lib/notifo/models/upsert_users_dto.rb +13 -25
- data/lib/notifo/models/user_dto.rb +22 -77
- data/lib/notifo/version.rb +4 -5
- data/notifo.gemspec +7 -7
- data/spec/api/apps_api_spec.rb +14 -15
- data/spec/api/configs_api_spec.rb +7 -8
- data/spec/api/events_api_spec.rb +8 -9
- data/spec/api/logs_api_spec.rb +7 -8
- data/spec/api/media_api_spec.rb +32 -11
- data/spec/api/templates_api_spec.rb +8 -9
- data/spec/api/topics_api_spec.rb +7 -8
- data/spec/api/user_api_spec.rb +9 -10
- data/spec/api/users_api_spec.rb +10 -11
- data/spec/api_client_spec.rb +5 -6
- data/spec/base_object_spec.rb +109 -0
- data/spec/configuration_spec.rb +7 -8
- data/spec/models/add_allowed_topic_dto_spec.rb +15 -9
- data/spec/models/add_contributor_dto_spec.rb +15 -9
- data/spec/models/app_contributor_dto_spec.rb +15 -9
- data/spec/models/app_details_dto_spec.rb +15 -9
- data/spec/models/app_dto_spec.rb +15 -9
- data/spec/models/body_spec.rb +40 -0
- data/spec/models/confirm_mode_spec.rb +15 -9
- data/spec/models/create_email_template_dto_spec.rb +15 -9
- data/spec/models/email_template_dto_spec.rb +15 -9
- data/spec/models/email_templates_dto_spec.rb +34 -0
- data/spec/models/email_verification_status_spec.rb +15 -9
- data/spec/models/error_dto_spec.rb +15 -9
- data/spec/models/event_dto_spec.rb +15 -9
- data/spec/models/event_properties_spec.rb +34 -0
- data/spec/models/iso_day_of_week_spec.rb +15 -9
- data/spec/models/list_response_dto_of_event_dto_spec.rb +15 -9
- data/spec/models/list_response_dto_of_log_entry_dto_spec.rb +15 -9
- data/spec/models/list_response_dto_of_media_dto_spec.rb +15 -9
- data/spec/models/list_response_dto_of_subscription_dto_spec.rb +15 -9
- data/spec/models/list_response_dto_of_template_dto_spec.rb +15 -9
- data/spec/models/list_response_dto_of_topic_dto_spec.rb +15 -9
- data/spec/models/list_response_dto_of_user_dto_spec.rb +15 -9
- data/spec/models/localized_text_spec.rb +34 -0
- data/spec/models/log_entry_dto_spec.rb +15 -9
- data/spec/models/media_dto_spec.rb +21 -9
- data/spec/models/media_metadata_spec.rb +34 -0
- data/spec/models/media_type_spec.rb +15 -9
- data/spec/models/notification_formatting_dto_spec.rb +15 -9
- data/spec/models/notification_send_spec.rb +15 -9
- data/spec/models/notification_setting_dto_spec.rb +16 -10
- data/spec/models/profile_dto_spec.rb +15 -9
- data/spec/models/publish_dto_spec.rb +15 -9
- data/spec/models/publish_many_dto_spec.rb +15 -9
- data/spec/models/resize_mode_spec.rb +15 -9
- data/spec/models/scheduling_dto_spec.rb +15 -9
- data/spec/models/scheduling_type_spec.rb +15 -9
- data/spec/models/subscription_dto_spec.rb +15 -9
- data/spec/models/template_dto_spec.rb +15 -9
- data/spec/models/topic_dto_spec.rb +15 -9
- data/spec/models/update_profile_dto_spec.rb +15 -9
- data/spec/models/upsert_app_dto_spec.rb +15 -9
- data/spec/models/upsert_template_dto_spec.rb +15 -9
- data/spec/models/upsert_templates_dto_spec.rb +15 -9
- data/spec/models/upsert_user_dto_spec.rb +15 -9
- data/spec/models/upsert_users_dto_spec.rb +15 -9
- data/spec/models/user_dto_spec.rb +15 -9
- data/spec/spec_helper.rb +4 -5
- metadata +44 -9
- data/docs/InlineObject.md +0 -18
- data/notifo-1.0.0.gem +0 -0
- data/notifo-io-1.0.0.2.gem +0 -0
- data/notifo-io-1.0.0.gem +0 -0
- data/spec/models/inline_object_spec.rb +0 -34
@@ -1,17 +1,15 @@
|
|
1
1
|
=begin
|
2
2
|
#Notifo API
|
3
3
|
|
4
|
-
#No description provided (generated by
|
4
|
+
#No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
|
5
5
|
|
6
|
-
|
7
|
-
|
8
|
-
Generated by: https://openapi-generator.tech
|
9
|
-
OpenAPI Generator version: 5.1.0-SNAPSHOT
|
6
|
+
OpenAPI spec version: 1.0.0
|
10
7
|
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
Swagger Codegen version: 3.0.24
|
11
10
|
=end
|
12
11
|
|
13
12
|
require 'date'
|
14
|
-
require 'time'
|
15
13
|
|
16
14
|
module Notifo
|
17
15
|
class AddContributorDto
|
@@ -29,16 +27,11 @@ module Notifo
|
|
29
27
|
}
|
30
28
|
end
|
31
29
|
|
32
|
-
# Returns all the JSON keys this model knows about
|
33
|
-
def self.acceptable_attributes
|
34
|
-
attribute_map.values
|
35
|
-
end
|
36
|
-
|
37
30
|
# Attribute type mapping.
|
38
31
|
def self.openapi_types
|
39
32
|
{
|
40
|
-
:'email' => :'
|
41
|
-
:'role' => :'
|
33
|
+
:'email' => :'Object',
|
34
|
+
:'role' => :'Object'
|
42
35
|
}
|
43
36
|
end
|
44
37
|
|
@@ -47,7 +40,7 @@ module Notifo
|
|
47
40
|
Set.new([
|
48
41
|
])
|
49
42
|
end
|
50
|
-
|
43
|
+
|
51
44
|
# Initializes the object
|
52
45
|
# @param [Hash] attributes Model attributes in the form of hash
|
53
46
|
def initialize(attributes = {})
|
@@ -80,18 +73,10 @@ module Notifo
|
|
80
73
|
invalid_properties.push('invalid value for "email", email cannot be nil.')
|
81
74
|
end
|
82
75
|
|
83
|
-
if @email.to_s.length < 1
|
84
|
-
invalid_properties.push('invalid value for "email", the character length must be great than or equal to 1.')
|
85
|
-
end
|
86
|
-
|
87
76
|
if @role.nil?
|
88
77
|
invalid_properties.push('invalid value for "role", role cannot be nil.')
|
89
78
|
end
|
90
79
|
|
91
|
-
if @role.to_s.length < 1
|
92
|
-
invalid_properties.push('invalid value for "role", the character length must be great than or equal to 1.')
|
93
|
-
end
|
94
|
-
|
95
80
|
invalid_properties
|
96
81
|
end
|
97
82
|
|
@@ -99,40 +84,10 @@ module Notifo
|
|
99
84
|
# @return true if the model is valid
|
100
85
|
def valid?
|
101
86
|
return false if @email.nil?
|
102
|
-
return false if @email.to_s.length < 1
|
103
87
|
return false if @role.nil?
|
104
|
-
return false if @role.to_s.length < 1
|
105
88
|
true
|
106
89
|
end
|
107
90
|
|
108
|
-
# Custom attribute writer method with validation
|
109
|
-
# @param [Object] email Value to be assigned
|
110
|
-
def email=(email)
|
111
|
-
if email.nil?
|
112
|
-
fail ArgumentError, 'email cannot be nil'
|
113
|
-
end
|
114
|
-
|
115
|
-
if email.to_s.length < 1
|
116
|
-
fail ArgumentError, 'invalid value for "email", the character length must be great than or equal to 1.'
|
117
|
-
end
|
118
|
-
|
119
|
-
@email = email
|
120
|
-
end
|
121
|
-
|
122
|
-
# Custom attribute writer method with validation
|
123
|
-
# @param [Object] role Value to be assigned
|
124
|
-
def role=(role)
|
125
|
-
if role.nil?
|
126
|
-
fail ArgumentError, 'role cannot be nil'
|
127
|
-
end
|
128
|
-
|
129
|
-
if role.to_s.length < 1
|
130
|
-
fail ArgumentError, 'invalid value for "role", the character length must be great than or equal to 1.'
|
131
|
-
end
|
132
|
-
|
133
|
-
@role = role
|
134
|
-
end
|
135
|
-
|
136
91
|
# Checks equality by comparing each attribute.
|
137
92
|
# @param [Object] Object to be compared
|
138
93
|
def ==(o)
|
@@ -167,9 +122,7 @@ module Notifo
|
|
167
122
|
def build_from_hash(attributes)
|
168
123
|
return nil unless attributes.is_a?(Hash)
|
169
124
|
self.class.openapi_types.each_pair do |key, type|
|
170
|
-
if
|
171
|
-
self.send("#{key}=", nil)
|
172
|
-
elsif type =~ /\AArray<(.*)>/i
|
125
|
+
if type =~ /\AArray<(.*)>/i
|
173
126
|
# check to ensure the input is an array given that the attribute
|
174
127
|
# is documented as an array but the input is not
|
175
128
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
@@ -177,6 +130,8 @@ module Notifo
|
|
177
130
|
end
|
178
131
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
179
132
|
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
133
|
+
elsif attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
134
|
+
self.send("#{key}=", nil)
|
180
135
|
end
|
181
136
|
end
|
182
137
|
|
@@ -189,8 +144,8 @@ module Notifo
|
|
189
144
|
# @return [Object] Deserialized data
|
190
145
|
def _deserialize(type, value)
|
191
146
|
case type.to_sym
|
192
|
-
when :
|
193
|
-
|
147
|
+
when :DateTime
|
148
|
+
DateTime.parse(value)
|
194
149
|
when :Date
|
195
150
|
Date.parse(value)
|
196
151
|
when :String
|
@@ -220,9 +175,7 @@ module Notifo
|
|
220
175
|
end
|
221
176
|
end
|
222
177
|
else # model
|
223
|
-
|
224
|
-
klass = Notifo.const_get(type)
|
225
|
-
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
178
|
+
Notifo.const_get(type).build_from_hash(value)
|
226
179
|
end
|
227
180
|
end
|
228
181
|
|
@@ -270,8 +223,5 @@ module Notifo
|
|
270
223
|
else
|
271
224
|
value
|
272
225
|
end
|
273
|
-
end
|
274
|
-
|
275
|
-
end
|
276
|
-
|
226
|
+
end end
|
277
227
|
end
|
@@ -1,17 +1,15 @@
|
|
1
1
|
=begin
|
2
2
|
#Notifo API
|
3
3
|
|
4
|
-
#No description provided (generated by
|
4
|
+
#No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
|
5
5
|
|
6
|
-
|
7
|
-
|
8
|
-
Generated by: https://openapi-generator.tech
|
9
|
-
OpenAPI Generator version: 5.1.0-SNAPSHOT
|
6
|
+
OpenAPI spec version: 1.0.0
|
10
7
|
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
Swagger Codegen version: 3.0.24
|
11
10
|
=end
|
12
11
|
|
13
12
|
require 'date'
|
14
|
-
require 'time'
|
15
13
|
|
16
14
|
module Notifo
|
17
15
|
class AppContributorDto
|
@@ -33,17 +31,12 @@ module Notifo
|
|
33
31
|
}
|
34
32
|
end
|
35
33
|
|
36
|
-
# Returns all the JSON keys this model knows about
|
37
|
-
def self.acceptable_attributes
|
38
|
-
attribute_map.values
|
39
|
-
end
|
40
|
-
|
41
34
|
# Attribute type mapping.
|
42
35
|
def self.openapi_types
|
43
36
|
{
|
44
|
-
:'user_id' => :'
|
45
|
-
:'user_name' => :'
|
46
|
-
:'role' => :'
|
37
|
+
:'user_id' => :'Object',
|
38
|
+
:'user_name' => :'Object',
|
39
|
+
:'role' => :'Object'
|
47
40
|
}
|
48
41
|
end
|
49
42
|
|
@@ -52,7 +45,7 @@ module Notifo
|
|
52
45
|
Set.new([
|
53
46
|
])
|
54
47
|
end
|
55
|
-
|
48
|
+
|
56
49
|
# Initializes the object
|
57
50
|
# @param [Hash] attributes Model attributes in the form of hash
|
58
51
|
def initialize(attributes = {})
|
@@ -89,26 +82,14 @@ module Notifo
|
|
89
82
|
invalid_properties.push('invalid value for "user_id", user_id cannot be nil.')
|
90
83
|
end
|
91
84
|
|
92
|
-
if @user_id.to_s.length < 1
|
93
|
-
invalid_properties.push('invalid value for "user_id", the character length must be great than or equal to 1.')
|
94
|
-
end
|
95
|
-
|
96
85
|
if @user_name.nil?
|
97
86
|
invalid_properties.push('invalid value for "user_name", user_name cannot be nil.')
|
98
87
|
end
|
99
88
|
|
100
|
-
if @user_name.to_s.length < 1
|
101
|
-
invalid_properties.push('invalid value for "user_name", the character length must be great than or equal to 1.')
|
102
|
-
end
|
103
|
-
|
104
89
|
if @role.nil?
|
105
90
|
invalid_properties.push('invalid value for "role", role cannot be nil.')
|
106
91
|
end
|
107
92
|
|
108
|
-
if @role.to_s.length < 1
|
109
|
-
invalid_properties.push('invalid value for "role", the character length must be great than or equal to 1.')
|
110
|
-
end
|
111
|
-
|
112
93
|
invalid_properties
|
113
94
|
end
|
114
95
|
|
@@ -116,56 +97,11 @@ module Notifo
|
|
116
97
|
# @return true if the model is valid
|
117
98
|
def valid?
|
118
99
|
return false if @user_id.nil?
|
119
|
-
return false if @user_id.to_s.length < 1
|
120
100
|
return false if @user_name.nil?
|
121
|
-
return false if @user_name.to_s.length < 1
|
122
101
|
return false if @role.nil?
|
123
|
-
return false if @role.to_s.length < 1
|
124
102
|
true
|
125
103
|
end
|
126
104
|
|
127
|
-
# Custom attribute writer method with validation
|
128
|
-
# @param [Object] user_id Value to be assigned
|
129
|
-
def user_id=(user_id)
|
130
|
-
if user_id.nil?
|
131
|
-
fail ArgumentError, 'user_id cannot be nil'
|
132
|
-
end
|
133
|
-
|
134
|
-
if user_id.to_s.length < 1
|
135
|
-
fail ArgumentError, 'invalid value for "user_id", the character length must be great than or equal to 1.'
|
136
|
-
end
|
137
|
-
|
138
|
-
@user_id = user_id
|
139
|
-
end
|
140
|
-
|
141
|
-
# Custom attribute writer method with validation
|
142
|
-
# @param [Object] user_name Value to be assigned
|
143
|
-
def user_name=(user_name)
|
144
|
-
if user_name.nil?
|
145
|
-
fail ArgumentError, 'user_name cannot be nil'
|
146
|
-
end
|
147
|
-
|
148
|
-
if user_name.to_s.length < 1
|
149
|
-
fail ArgumentError, 'invalid value for "user_name", the character length must be great than or equal to 1.'
|
150
|
-
end
|
151
|
-
|
152
|
-
@user_name = user_name
|
153
|
-
end
|
154
|
-
|
155
|
-
# Custom attribute writer method with validation
|
156
|
-
# @param [Object] role Value to be assigned
|
157
|
-
def role=(role)
|
158
|
-
if role.nil?
|
159
|
-
fail ArgumentError, 'role cannot be nil'
|
160
|
-
end
|
161
|
-
|
162
|
-
if role.to_s.length < 1
|
163
|
-
fail ArgumentError, 'invalid value for "role", the character length must be great than or equal to 1.'
|
164
|
-
end
|
165
|
-
|
166
|
-
@role = role
|
167
|
-
end
|
168
|
-
|
169
105
|
# Checks equality by comparing each attribute.
|
170
106
|
# @param [Object] Object to be compared
|
171
107
|
def ==(o)
|
@@ -201,9 +137,7 @@ module Notifo
|
|
201
137
|
def build_from_hash(attributes)
|
202
138
|
return nil unless attributes.is_a?(Hash)
|
203
139
|
self.class.openapi_types.each_pair do |key, type|
|
204
|
-
if
|
205
|
-
self.send("#{key}=", nil)
|
206
|
-
elsif type =~ /\AArray<(.*)>/i
|
140
|
+
if type =~ /\AArray<(.*)>/i
|
207
141
|
# check to ensure the input is an array given that the attribute
|
208
142
|
# is documented as an array but the input is not
|
209
143
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
@@ -211,6 +145,8 @@ module Notifo
|
|
211
145
|
end
|
212
146
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
213
147
|
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
148
|
+
elsif attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
149
|
+
self.send("#{key}=", nil)
|
214
150
|
end
|
215
151
|
end
|
216
152
|
|
@@ -223,8 +159,8 @@ module Notifo
|
|
223
159
|
# @return [Object] Deserialized data
|
224
160
|
def _deserialize(type, value)
|
225
161
|
case type.to_sym
|
226
|
-
when :
|
227
|
-
|
162
|
+
when :DateTime
|
163
|
+
DateTime.parse(value)
|
228
164
|
when :Date
|
229
165
|
Date.parse(value)
|
230
166
|
when :String
|
@@ -254,9 +190,7 @@ module Notifo
|
|
254
190
|
end
|
255
191
|
end
|
256
192
|
else # model
|
257
|
-
|
258
|
-
klass = Notifo.const_get(type)
|
259
|
-
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
193
|
+
Notifo.const_get(type).build_from_hash(value)
|
260
194
|
end
|
261
195
|
end
|
262
196
|
|
@@ -304,8 +238,5 @@ module Notifo
|
|
304
238
|
else
|
305
239
|
value
|
306
240
|
end
|
307
|
-
end
|
308
|
-
|
309
|
-
end
|
310
|
-
|
241
|
+
end end
|
311
242
|
end
|
@@ -1,17 +1,15 @@
|
|
1
1
|
=begin
|
2
2
|
#Notifo API
|
3
3
|
|
4
|
-
#No description provided (generated by
|
4
|
+
#No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
|
5
5
|
|
6
|
-
|
7
|
-
|
8
|
-
Generated by: https://openapi-generator.tech
|
9
|
-
OpenAPI Generator version: 5.1.0-SNAPSHOT
|
6
|
+
OpenAPI spec version: 1.0.0
|
10
7
|
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
Swagger Codegen version: 3.0.24
|
11
10
|
=end
|
12
11
|
|
13
12
|
require 'date'
|
14
|
-
require 'time'
|
15
13
|
|
16
14
|
module Notifo
|
17
15
|
class AppDetailsDto
|
@@ -84,45 +82,34 @@ module Notifo
|
|
84
82
|
}
|
85
83
|
end
|
86
84
|
|
87
|
-
# Returns all the JSON keys this model knows about
|
88
|
-
def self.acceptable_attributes
|
89
|
-
attribute_map.values
|
90
|
-
end
|
91
|
-
|
92
85
|
# Attribute type mapping.
|
93
86
|
def self.openapi_types
|
94
87
|
{
|
95
|
-
:'id' => :'
|
96
|
-
:'name' => :'
|
97
|
-
:'role' => :'
|
98
|
-
:'languages' => :'
|
99
|
-
:'email_address' => :'
|
100
|
-
:'email_name' => :'
|
101
|
-
:'firebase_project' => :'
|
102
|
-
:'firebase_credential' => :'
|
103
|
-
:'webhook_url' => :'
|
104
|
-
:'confirm_url' => :'
|
105
|
-
:'allow_email' => :'
|
106
|
-
:'allow_sms' => :'
|
107
|
-
:'email_verification_status' => :'
|
108
|
-
:'api_keys' => :'
|
109
|
-
:'contributors' => :'
|
110
|
-
:'counters' => :'
|
88
|
+
:'id' => :'Object',
|
89
|
+
:'name' => :'Object',
|
90
|
+
:'role' => :'Object',
|
91
|
+
:'languages' => :'Object',
|
92
|
+
:'email_address' => :'Object',
|
93
|
+
:'email_name' => :'Object',
|
94
|
+
:'firebase_project' => :'Object',
|
95
|
+
:'firebase_credential' => :'Object',
|
96
|
+
:'webhook_url' => :'Object',
|
97
|
+
:'confirm_url' => :'Object',
|
98
|
+
:'allow_email' => :'Object',
|
99
|
+
:'allow_sms' => :'Object',
|
100
|
+
:'email_verification_status' => :'Object',
|
101
|
+
:'api_keys' => :'Object',
|
102
|
+
:'contributors' => :'Object',
|
103
|
+
:'counters' => :'Object'
|
111
104
|
}
|
112
105
|
end
|
113
106
|
|
114
107
|
# List of attributes with nullable: true
|
115
108
|
def self.openapi_nullable
|
116
109
|
Set.new([
|
117
|
-
:'email_address',
|
118
|
-
:'email_name',
|
119
|
-
:'firebase_project',
|
120
|
-
:'firebase_credential',
|
121
|
-
:'webhook_url',
|
122
|
-
:'confirm_url',
|
123
110
|
])
|
124
111
|
end
|
125
|
-
|
112
|
+
|
126
113
|
# Initializes the object
|
127
114
|
# @param [Hash] attributes Model attributes in the form of hash
|
128
115
|
def initialize(attributes = {})
|
@@ -219,26 +206,14 @@ module Notifo
|
|
219
206
|
invalid_properties.push('invalid value for "id", id cannot be nil.')
|
220
207
|
end
|
221
208
|
|
222
|
-
if @id.to_s.length < 1
|
223
|
-
invalid_properties.push('invalid value for "id", the character length must be great than or equal to 1.')
|
224
|
-
end
|
225
|
-
|
226
209
|
if @name.nil?
|
227
210
|
invalid_properties.push('invalid value for "name", name cannot be nil.')
|
228
211
|
end
|
229
212
|
|
230
|
-
if @name.to_s.length < 1
|
231
|
-
invalid_properties.push('invalid value for "name", the character length must be great than or equal to 1.')
|
232
|
-
end
|
233
|
-
|
234
213
|
if @role.nil?
|
235
214
|
invalid_properties.push('invalid value for "role", role cannot be nil.')
|
236
215
|
end
|
237
216
|
|
238
|
-
if @role.to_s.length < 1
|
239
|
-
invalid_properties.push('invalid value for "role", the character length must be great than or equal to 1.')
|
240
|
-
end
|
241
|
-
|
242
217
|
if @languages.nil?
|
243
218
|
invalid_properties.push('invalid value for "languages", languages cannot be nil.')
|
244
219
|
end
|
@@ -274,11 +249,8 @@ module Notifo
|
|
274
249
|
# @return true if the model is valid
|
275
250
|
def valid?
|
276
251
|
return false if @id.nil?
|
277
|
-
return false if @id.to_s.length < 1
|
278
252
|
return false if @name.nil?
|
279
|
-
return false if @name.to_s.length < 1
|
280
253
|
return false if @role.nil?
|
281
|
-
return false if @role.to_s.length < 1
|
282
254
|
return false if @languages.nil?
|
283
255
|
return false if @allow_email.nil?
|
284
256
|
return false if @allow_sms.nil?
|
@@ -289,48 +261,6 @@ module Notifo
|
|
289
261
|
true
|
290
262
|
end
|
291
263
|
|
292
|
-
# Custom attribute writer method with validation
|
293
|
-
# @param [Object] id Value to be assigned
|
294
|
-
def id=(id)
|
295
|
-
if id.nil?
|
296
|
-
fail ArgumentError, 'id cannot be nil'
|
297
|
-
end
|
298
|
-
|
299
|
-
if id.to_s.length < 1
|
300
|
-
fail ArgumentError, 'invalid value for "id", the character length must be great than or equal to 1.'
|
301
|
-
end
|
302
|
-
|
303
|
-
@id = id
|
304
|
-
end
|
305
|
-
|
306
|
-
# Custom attribute writer method with validation
|
307
|
-
# @param [Object] name Value to be assigned
|
308
|
-
def name=(name)
|
309
|
-
if name.nil?
|
310
|
-
fail ArgumentError, 'name cannot be nil'
|
311
|
-
end
|
312
|
-
|
313
|
-
if name.to_s.length < 1
|
314
|
-
fail ArgumentError, 'invalid value for "name", the character length must be great than or equal to 1.'
|
315
|
-
end
|
316
|
-
|
317
|
-
@name = name
|
318
|
-
end
|
319
|
-
|
320
|
-
# Custom attribute writer method with validation
|
321
|
-
# @param [Object] role Value to be assigned
|
322
|
-
def role=(role)
|
323
|
-
if role.nil?
|
324
|
-
fail ArgumentError, 'role cannot be nil'
|
325
|
-
end
|
326
|
-
|
327
|
-
if role.to_s.length < 1
|
328
|
-
fail ArgumentError, 'invalid value for "role", the character length must be great than or equal to 1.'
|
329
|
-
end
|
330
|
-
|
331
|
-
@role = role
|
332
|
-
end
|
333
|
-
|
334
264
|
# Checks equality by comparing each attribute.
|
335
265
|
# @param [Object] Object to be compared
|
336
266
|
def ==(o)
|
@@ -379,9 +309,7 @@ module Notifo
|
|
379
309
|
def build_from_hash(attributes)
|
380
310
|
return nil unless attributes.is_a?(Hash)
|
381
311
|
self.class.openapi_types.each_pair do |key, type|
|
382
|
-
if
|
383
|
-
self.send("#{key}=", nil)
|
384
|
-
elsif type =~ /\AArray<(.*)>/i
|
312
|
+
if type =~ /\AArray<(.*)>/i
|
385
313
|
# check to ensure the input is an array given that the attribute
|
386
314
|
# is documented as an array but the input is not
|
387
315
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
@@ -389,6 +317,8 @@ module Notifo
|
|
389
317
|
end
|
390
318
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
391
319
|
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
320
|
+
elsif attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
321
|
+
self.send("#{key}=", nil)
|
392
322
|
end
|
393
323
|
end
|
394
324
|
|
@@ -401,8 +331,8 @@ module Notifo
|
|
401
331
|
# @return [Object] Deserialized data
|
402
332
|
def _deserialize(type, value)
|
403
333
|
case type.to_sym
|
404
|
-
when :
|
405
|
-
|
334
|
+
when :DateTime
|
335
|
+
DateTime.parse(value)
|
406
336
|
when :Date
|
407
337
|
Date.parse(value)
|
408
338
|
when :String
|
@@ -432,9 +362,7 @@ module Notifo
|
|
432
362
|
end
|
433
363
|
end
|
434
364
|
else # model
|
435
|
-
|
436
|
-
klass = Notifo.const_get(type)
|
437
|
-
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
365
|
+
Notifo.const_get(type).build_from_hash(value)
|
438
366
|
end
|
439
367
|
end
|
440
368
|
|
@@ -482,8 +410,5 @@ module Notifo
|
|
482
410
|
else
|
483
411
|
value
|
484
412
|
end
|
485
|
-
end
|
486
|
-
|
487
|
-
end
|
488
|
-
|
413
|
+
end end
|
489
414
|
end
|