notifo-io-easierlife 1.0.0 → 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 +599 -97
- data/Rakefile +0 -2
- data/docs/AddAllowedTopicDto.md +4 -15
- data/docs/AddContributorDto.md +5 -17
- data/docs/AppContributorDto.md +6 -19
- data/docs/AppDetailsDto.md +19 -45
- data/docs/AppDto.md +9 -25
- data/docs/AppsApi.md +181 -363
- data/docs/Body.md +7 -0
- data/docs/ConfigsApi.md +28 -68
- data/docs/ConfirmMode.md +3 -12
- data/docs/CreateEmailTemplateDto.md +4 -15
- data/docs/EmailTemplateDto.md +6 -19
- data/docs/EmailTemplatesDto.md +6 -0
- data/docs/EmailVerificationStatus.md +3 -12
- data/docs/ErrorDto.md +8 -23
- data/docs/EventDto.md +15 -37
- data/docs/EventProperties.md +6 -0
- data/docs/EventsApi.md +43 -80
- data/docs/IsoDayOfWeek.md +3 -12
- data/docs/ListResponseDtoOfEventDto.md +5 -17
- data/docs/ListResponseDtoOfLogEntryDto.md +5 -17
- data/docs/ListResponseDtoOfMediaDto.md +5 -17
- data/docs/ListResponseDtoOfSubscriptionDto.md +5 -17
- data/docs/ListResponseDtoOfTemplateDto.md +5 -17
- data/docs/ListResponseDtoOfTopicDto.md +5 -17
- data/docs/ListResponseDtoOfUserDto.md +5 -17
- data/docs/LocalizedText.md +6 -0
- data/docs/LogEntryDto.md +7 -21
- data/docs/LogsApi.md +25 -44
- data/docs/MediaApi.md +118 -212
- data/docs/MediaDto.md +10 -27
- data/docs/MediaMetadata.md +6 -0
- data/docs/MediaType.md +3 -12
- data/docs/NotificationFormattingDto.md +11 -29
- data/docs/NotificationSend.md +3 -12
- data/docs/NotificationSettingDto.md +5 -17
- data/docs/ProfileDto.md +11 -29
- data/docs/PublishDto.md +13 -33
- data/docs/PublishManyDto.md +4 -15
- data/docs/ResizeMode.md +3 -12
- data/docs/SchedulingDto.md +7 -21
- data/docs/SchedulingType.md +3 -12
- data/docs/SubscriptionDto.md +5 -17
- data/docs/TemplateDto.md +6 -19
- data/docs/TemplatesApi.md +61 -116
- data/docs/TopicDto.md +6 -19
- data/docs/TopicsApi.md +25 -44
- data/docs/UpdateProfileDto.md +9 -25
- data/docs/UpsertAppDto.md +13 -33
- data/docs/UpsertTemplateDto.md +6 -19
- data/docs/UpsertTemplatesDto.md +4 -15
- data/docs/UpsertUserDto.md +11 -29
- data/docs/UpsertUsersDto.md +4 -15
- data/docs/UserApi.md +84 -176
- data/docs/UserDto.md +13 -33
- data/docs/UsersApi.md +173 -337
- data/git_push.sh +7 -10
- data/lib/swagger_client.rb +93 -0
- data/lib/{notifo → swagger_client}/api/apps_api.rb +131 -203
- data/lib/{notifo → swagger_client}/api/configs_api.rb +15 -31
- data/lib/{notifo → swagger_client}/api/events_api.rb +30 -46
- data/lib/{notifo → swagger_client}/api/logs_api.rb +13 -22
- data/lib/{notifo → swagger_client}/api/media_api.rb +61 -98
- data/lib/{notifo → swagger_client}/api/templates_api.rb +40 -63
- data/lib/{notifo → swagger_client}/api/topics_api.rb +13 -22
- data/lib/{notifo → swagger_client}/api/user_api.rb +52 -89
- data/lib/{notifo → swagger_client}/api/users_api.rb +122 -187
- data/lib/{notifo → swagger_client}/api_client.rb +55 -57
- data/lib/{notifo → swagger_client}/api_error.rb +6 -6
- data/lib/{notifo → swagger_client}/configuration.rb +12 -84
- data/lib/{notifo → swagger_client}/models/add_allowed_topic_dto.rb +16 -47
- data/lib/swagger_client/models/add_contributor_dto.rb +227 -0
- data/lib/swagger_client/models/app_contributor_dto.rb +242 -0
- data/lib/{notifo → swagger_client}/models/app_details_dto.rb +31 -106
- data/lib/{notifo → swagger_client}/models/app_dto.rb +21 -90
- data/lib/swagger_client/models/body.rb +206 -0
- data/lib/swagger_client/models/confirm_mode.rb +29 -0
- data/lib/{notifo → swagger_client}/models/create_email_template_dto.rb +16 -47
- data/lib/swagger_client/models/email_template_dto.rb +237 -0
- data/lib/swagger_client/models/email_templates_dto.rb +201 -0
- data/lib/swagger_client/models/email_verification_status.rb +30 -0
- data/lib/{notifo → swagger_client}/models/error_dto.rb +20 -36
- data/lib/{notifo → swagger_client}/models/event_dto.rb +27 -117
- data/lib/swagger_client/models/event_properties.rb +201 -0
- data/lib/swagger_client/models/iso_day_of_week.rb +34 -0
- data/lib/{notifo/models/list_response_dto_of_subscription_dto.rb → swagger_client/models/list_response_dto_of_event_dto.rb} +18 -30
- data/lib/{notifo → swagger_client}/models/list_response_dto_of_log_entry_dto.rb +17 -29
- data/lib/{notifo → swagger_client}/models/list_response_dto_of_media_dto.rb +17 -29
- data/lib/{notifo/models/list_response_dto_of_event_dto.rb → swagger_client/models/list_response_dto_of_subscription_dto.rb} +18 -30
- data/lib/{notifo → swagger_client}/models/list_response_dto_of_template_dto.rb +17 -29
- data/lib/{notifo → swagger_client}/models/list_response_dto_of_topic_dto.rb +17 -29
- data/lib/{notifo → swagger_client}/models/list_response_dto_of_user_dto.rb +17 -29
- data/lib/swagger_client/models/localized_text.rb +201 -0
- data/lib/{notifo → swagger_client}/models/log_entry_dto.rb +19 -88
- data/lib/{notifo → swagger_client}/models/media_dto.rb +23 -113
- data/lib/swagger_client/models/media_metadata.rb +201 -0
- data/lib/swagger_client/models/media_type.rb +30 -0
- data/lib/{notifo → swagger_client}/models/notification_formatting_dto.rb +30 -56
- data/lib/swagger_client/models/notification_send.rb +30 -0
- data/lib/{notifo → swagger_client}/models/notification_setting_dto.rb +26 -39
- data/lib/{notifo → swagger_client}/models/profile_dto.rb +23 -76
- data/lib/{notifo → swagger_client}/models/publish_dto.rb +26 -63
- data/lib/{notifo → swagger_client}/models/publish_many_dto.rb +16 -28
- data/lib/swagger_client/models/resize_mode.rb +33 -0
- data/lib/{notifo → swagger_client}/models/scheduling_dto.rb +19 -32
- data/lib/swagger_client/models/scheduling_type.rb +28 -0
- data/lib/{notifo → swagger_client}/models/subscription_dto.rb +17 -49
- data/lib/{notifo → swagger_client}/models/template_dto.rb +18 -49
- data/lib/{notifo → swagger_client}/models/topic_dto.rb +18 -68
- data/lib/{notifo → swagger_client}/models/update_profile_dto.rb +21 -39
- data/lib/{notifo → swagger_client}/models/upsert_app_dto.rb +25 -47
- data/lib/{notifo → swagger_client}/models/upsert_template_dto.rb +18 -50
- data/lib/{notifo → swagger_client}/models/upsert_templates_dto.rb +16 -28
- data/lib/{notifo → swagger_client}/models/upsert_user_dto.rb +23 -43
- data/lib/{notifo → swagger_client}/models/upsert_users_dto.rb +16 -28
- data/lib/{notifo → swagger_client}/models/user_dto.rb +25 -80
- data/lib/swagger_client/version.rb +14 -0
- data/spec/api/apps_api_spec.rb +14 -15
- data/spec/api/configs_api_spec.rb +8 -9
- data/spec/api/events_api_spec.rb +9 -10
- data/spec/api/logs_api_spec.rb +8 -9
- data/spec/api/media_api_spec.rb +13 -14
- data/spec/api/templates_api_spec.rb +9 -10
- data/spec/api/topics_api_spec.rb +8 -9
- data/spec/api/user_api_spec.rb +10 -11
- data/spec/api/users_api_spec.rb +11 -12
- data/spec/api_client_spec.rb +34 -35
- data/spec/base_object_spec.rb +109 -0
- data/spec/configuration_spec.rb +7 -8
- data/spec/models/add_allowed_topic_dto_spec.rb +16 -10
- data/spec/models/add_contributor_dto_spec.rb +16 -10
- data/spec/models/app_contributor_dto_spec.rb +16 -10
- data/spec/models/app_details_dto_spec.rb +16 -10
- data/spec/models/app_dto_spec.rb +16 -10
- data/spec/models/body_spec.rb +40 -0
- data/spec/models/confirm_mode_spec.rb +16 -10
- data/spec/models/create_email_template_dto_spec.rb +16 -10
- data/spec/models/email_template_dto_spec.rb +16 -10
- data/spec/models/email_templates_dto_spec.rb +34 -0
- data/spec/models/email_verification_status_spec.rb +16 -10
- data/spec/models/error_dto_spec.rb +16 -10
- data/spec/models/event_dto_spec.rb +16 -10
- data/spec/models/event_properties_spec.rb +34 -0
- data/spec/models/iso_day_of_week_spec.rb +16 -10
- data/spec/models/list_response_dto_of_event_dto_spec.rb +16 -10
- data/spec/models/list_response_dto_of_log_entry_dto_spec.rb +16 -10
- data/spec/models/list_response_dto_of_media_dto_spec.rb +16 -10
- data/spec/models/list_response_dto_of_subscription_dto_spec.rb +16 -10
- data/spec/models/list_response_dto_of_template_dto_spec.rb +16 -10
- data/spec/models/list_response_dto_of_topic_dto_spec.rb +16 -10
- data/spec/models/list_response_dto_of_user_dto_spec.rb +16 -10
- data/spec/models/localized_text_spec.rb +34 -0
- data/spec/models/log_entry_dto_spec.rb +16 -10
- data/spec/models/media_dto_spec.rb +16 -10
- data/spec/models/media_metadata_spec.rb +34 -0
- data/spec/models/media_type_spec.rb +16 -10
- data/spec/models/notification_formatting_dto_spec.rb +16 -10
- data/spec/models/notification_send_spec.rb +16 -10
- data/spec/models/notification_setting_dto_spec.rb +17 -11
- data/spec/models/profile_dto_spec.rb +16 -10
- data/spec/models/publish_dto_spec.rb +16 -10
- data/spec/models/publish_many_dto_spec.rb +16 -10
- data/spec/models/resize_mode_spec.rb +16 -10
- data/spec/models/scheduling_dto_spec.rb +16 -10
- data/spec/models/scheduling_type_spec.rb +16 -10
- data/spec/models/subscription_dto_spec.rb +16 -10
- data/spec/models/template_dto_spec.rb +16 -10
- data/spec/models/topic_dto_spec.rb +16 -10
- data/spec/models/update_profile_dto_spec.rb +16 -10
- data/spec/models/upsert_app_dto_spec.rb +16 -10
- data/spec/models/upsert_template_dto_spec.rb +16 -10
- data/spec/models/upsert_templates_dto_spec.rb +16 -10
- data/spec/models/upsert_user_dto_spec.rb +16 -10
- data/spec/models/upsert_users_dto_spec.rb +16 -10
- data/spec/models/user_dto_spec.rb +16 -10
- data/spec/spec_helper.rb +5 -6
- data/{notifo.gemspec → swagger_client.gemspec} +9 -9
- metadata +101 -60
- data/lib/notifo.rb +0 -89
- data/lib/notifo/models/add_contributor_dto.rb +0 -277
- data/lib/notifo/models/app_contributor_dto.rb +0 -311
- data/lib/notifo/models/confirm_mode.rb +0 -38
- data/lib/notifo/models/email_template_dto.rb +0 -288
- data/lib/notifo/models/email_verification_status.rb +0 -39
- data/lib/notifo/models/iso_day_of_week.rb +0 -43
- data/lib/notifo/models/media_type.rb +0 -39
- data/lib/notifo/models/notification_send.rb +0 -39
- data/lib/notifo/models/resize_mode.rb +0 -42
- data/lib/notifo/models/scheduling_type.rb +0 -37
- data/lib/notifo/version.rb +0 -15
- data/notifo-io-1.0.0.gem +0 -0
@@ -0,0 +1,30 @@
|
|
1
|
+
=begin
|
2
|
+
#Notifo API
|
3
|
+
|
4
|
+
#No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
|
5
|
+
|
6
|
+
OpenAPI spec version: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
Swagger Codegen version: 3.0.24
|
10
|
+
=end
|
11
|
+
|
12
|
+
require 'date'
|
13
|
+
|
14
|
+
module SwaggerClient
|
15
|
+
class MediaType
|
16
|
+
UNKNOWN = 'Unknown'.freeze
|
17
|
+
IMAGE = 'Image'.freeze
|
18
|
+
AUDIO = 'Audio'.freeze
|
19
|
+
VIDEO = 'Video'.freeze
|
20
|
+
|
21
|
+
# Builds the enum from string
|
22
|
+
# @param [String] The enum value in the form of the string
|
23
|
+
# @return [String] The enum value
|
24
|
+
def build_from_hash(value)
|
25
|
+
constantValues = MediaType.constants.select { |c| MediaType::const_get(c) == value }
|
26
|
+
raise "Invalid ENUM value #{value} for class #MediaType" if constantValues.empty?
|
27
|
+
value
|
28
|
+
end
|
29
|
+
end
|
30
|
+
end
|
@@ -1,19 +1,17 @@
|
|
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
|
-
module
|
14
|
+
module SwaggerClient
|
17
15
|
class NotificationFormattingDto
|
18
16
|
attr_accessor :subject
|
19
17
|
|
@@ -45,22 +43,17 @@ module Notifo
|
|
45
43
|
}
|
46
44
|
end
|
47
45
|
|
48
|
-
# Returns all the JSON keys this model knows about
|
49
|
-
def self.acceptable_attributes
|
50
|
-
attribute_map.values
|
51
|
-
end
|
52
|
-
|
53
46
|
# Attribute type mapping.
|
54
47
|
def self.openapi_types
|
55
48
|
{
|
56
|
-
:'subject' => :'
|
57
|
-
:'body' => :'
|
58
|
-
:'confirm_text' => :'
|
59
|
-
:'image_small' => :'
|
60
|
-
:'image_large' => :'
|
61
|
-
:'link_url' => :'
|
62
|
-
:'link_text' => :'
|
63
|
-
:'confirm_mode' => :'
|
49
|
+
:'subject' => :'Object',
|
50
|
+
:'body' => :'Object',
|
51
|
+
:'confirm_text' => :'Object',
|
52
|
+
:'image_small' => :'Object',
|
53
|
+
:'image_large' => :'Object',
|
54
|
+
:'link_url' => :'Object',
|
55
|
+
:'link_text' => :'Object',
|
56
|
+
:'confirm_mode' => :'Object'
|
64
57
|
}
|
65
58
|
end
|
66
59
|
|
@@ -69,62 +62,48 @@ module Notifo
|
|
69
62
|
Set.new([
|
70
63
|
])
|
71
64
|
end
|
72
|
-
|
65
|
+
|
73
66
|
# Initializes the object
|
74
67
|
# @param [Hash] attributes Model attributes in the form of hash
|
75
68
|
def initialize(attributes = {})
|
76
69
|
if (!attributes.is_a?(Hash))
|
77
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `
|
70
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `SwaggerClient::NotificationFormattingDto` initialize method"
|
78
71
|
end
|
79
72
|
|
80
73
|
# check to see if the attribute exists and convert string to symbol for hash key
|
81
74
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
82
75
|
if (!self.class.attribute_map.key?(k.to_sym))
|
83
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `
|
76
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `SwaggerClient::NotificationFormattingDto`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
84
77
|
end
|
85
78
|
h[k.to_sym] = v
|
86
79
|
}
|
87
80
|
|
88
81
|
if attributes.key?(:'subject')
|
89
|
-
|
90
|
-
self.subject = value
|
91
|
-
end
|
82
|
+
self.subject = attributes[:'subject']
|
92
83
|
end
|
93
84
|
|
94
85
|
if attributes.key?(:'body')
|
95
|
-
|
96
|
-
self.body = value
|
97
|
-
end
|
86
|
+
self.body = attributes[:'body']
|
98
87
|
end
|
99
88
|
|
100
89
|
if attributes.key?(:'confirm_text')
|
101
|
-
|
102
|
-
self.confirm_text = value
|
103
|
-
end
|
90
|
+
self.confirm_text = attributes[:'confirm_text']
|
104
91
|
end
|
105
92
|
|
106
93
|
if attributes.key?(:'image_small')
|
107
|
-
|
108
|
-
self.image_small = value
|
109
|
-
end
|
94
|
+
self.image_small = attributes[:'image_small']
|
110
95
|
end
|
111
96
|
|
112
97
|
if attributes.key?(:'image_large')
|
113
|
-
|
114
|
-
self.image_large = value
|
115
|
-
end
|
98
|
+
self.image_large = attributes[:'image_large']
|
116
99
|
end
|
117
100
|
|
118
101
|
if attributes.key?(:'link_url')
|
119
|
-
|
120
|
-
self.link_url = value
|
121
|
-
end
|
102
|
+
self.link_url = attributes[:'link_url']
|
122
103
|
end
|
123
104
|
|
124
105
|
if attributes.key?(:'link_text')
|
125
|
-
|
126
|
-
self.link_text = value
|
127
|
-
end
|
106
|
+
self.link_text = attributes[:'link_text']
|
128
107
|
end
|
129
108
|
|
130
109
|
if attributes.key?(:'confirm_mode')
|
@@ -195,9 +174,7 @@ module Notifo
|
|
195
174
|
def build_from_hash(attributes)
|
196
175
|
return nil unless attributes.is_a?(Hash)
|
197
176
|
self.class.openapi_types.each_pair do |key, type|
|
198
|
-
if
|
199
|
-
self.send("#{key}=", nil)
|
200
|
-
elsif type =~ /\AArray<(.*)>/i
|
177
|
+
if type =~ /\AArray<(.*)>/i
|
201
178
|
# check to ensure the input is an array given that the attribute
|
202
179
|
# is documented as an array but the input is not
|
203
180
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
@@ -205,6 +182,8 @@ module Notifo
|
|
205
182
|
end
|
206
183
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
207
184
|
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
185
|
+
elsif attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
186
|
+
self.send("#{key}=", nil)
|
208
187
|
end
|
209
188
|
end
|
210
189
|
|
@@ -217,8 +196,8 @@ module Notifo
|
|
217
196
|
# @return [Object] Deserialized data
|
218
197
|
def _deserialize(type, value)
|
219
198
|
case type.to_sym
|
220
|
-
when :
|
221
|
-
|
199
|
+
when :DateTime
|
200
|
+
DateTime.parse(value)
|
222
201
|
when :Date
|
223
202
|
Date.parse(value)
|
224
203
|
when :String
|
@@ -248,9 +227,7 @@ module Notifo
|
|
248
227
|
end
|
249
228
|
end
|
250
229
|
else # model
|
251
|
-
|
252
|
-
klass = Notifo.const_get(type)
|
253
|
-
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
230
|
+
SwaggerClient.const_get(type).build_from_hash(value)
|
254
231
|
end
|
255
232
|
end
|
256
233
|
|
@@ -298,8 +275,5 @@ module Notifo
|
|
298
275
|
else
|
299
276
|
value
|
300
277
|
end
|
301
|
-
end
|
302
|
-
|
303
|
-
end
|
304
|
-
|
278
|
+
end end
|
305
279
|
end
|
@@ -0,0 +1,30 @@
|
|
1
|
+
=begin
|
2
|
+
#Notifo API
|
3
|
+
|
4
|
+
#No description provided (generated by Swagger Codegen https://github.com/swagger-api/swagger-codegen)
|
5
|
+
|
6
|
+
OpenAPI spec version: 1.0.0
|
7
|
+
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
9
|
+
Swagger Codegen version: 3.0.24
|
10
|
+
=end
|
11
|
+
|
12
|
+
require 'date'
|
13
|
+
|
14
|
+
module SwaggerClient
|
15
|
+
class NotificationSend
|
16
|
+
INHERIT = 'Inherit'.freeze
|
17
|
+
SEND = 'Send'.freeze
|
18
|
+
NOT_SENDING = 'NotSending'.freeze
|
19
|
+
NOT_ALLOWED = 'NotAllowed'.freeze
|
20
|
+
|
21
|
+
# Builds the enum from string
|
22
|
+
# @param [String] The enum value in the form of the string
|
23
|
+
# @return [String] The enum value
|
24
|
+
def build_from_hash(value)
|
25
|
+
constantValues = NotificationSend.constants.select { |c| NotificationSend::const_get(c) == value }
|
26
|
+
raise "Invalid ENUM value #{value} for class #NotificationSend" if constantValues.empty?
|
27
|
+
value
|
28
|
+
end
|
29
|
+
end
|
30
|
+
end
|
@@ -1,21 +1,19 @@
|
|
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
|
-
module
|
14
|
+
module SwaggerClient
|
17
15
|
class NotificationSettingDto
|
18
|
-
attr_accessor :
|
16
|
+
attr_accessor :send
|
19
17
|
|
20
18
|
# The delay in seconds.
|
21
19
|
attr_accessor :delay_in_seconds
|
@@ -23,48 +21,42 @@ module Notifo
|
|
23
21
|
# Attribute mapping from ruby-style variable name to JSON key.
|
24
22
|
def self.attribute_map
|
25
23
|
{
|
26
|
-
:'
|
24
|
+
:'send' => :'send',
|
27
25
|
:'delay_in_seconds' => :'delayInSeconds'
|
28
26
|
}
|
29
27
|
end
|
30
28
|
|
31
|
-
# Returns all the JSON keys this model knows about
|
32
|
-
def self.acceptable_attributes
|
33
|
-
attribute_map.values
|
34
|
-
end
|
35
|
-
|
36
29
|
# Attribute type mapping.
|
37
30
|
def self.openapi_types
|
38
31
|
{
|
39
|
-
:'
|
40
|
-
:'delay_in_seconds' => :'
|
32
|
+
:'send' => :'Object',
|
33
|
+
:'delay_in_seconds' => :'Object'
|
41
34
|
}
|
42
35
|
end
|
43
36
|
|
44
37
|
# List of attributes with nullable: true
|
45
38
|
def self.openapi_nullable
|
46
39
|
Set.new([
|
47
|
-
:'delay_in_seconds'
|
48
40
|
])
|
49
41
|
end
|
50
|
-
|
42
|
+
|
51
43
|
# Initializes the object
|
52
44
|
# @param [Hash] attributes Model attributes in the form of hash
|
53
45
|
def initialize(attributes = {})
|
54
46
|
if (!attributes.is_a?(Hash))
|
55
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `
|
47
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `SwaggerClient::NotificationSettingDto` initialize method"
|
56
48
|
end
|
57
49
|
|
58
50
|
# check to see if the attribute exists and convert string to symbol for hash key
|
59
51
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
60
52
|
if (!self.class.attribute_map.key?(k.to_sym))
|
61
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `
|
53
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `SwaggerClient::NotificationSettingDto`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
62
54
|
end
|
63
55
|
h[k.to_sym] = v
|
64
56
|
}
|
65
57
|
|
66
|
-
if attributes.key?(:'
|
67
|
-
self.
|
58
|
+
if attributes.key?(:'send')
|
59
|
+
self.send = attributes[:'send']
|
68
60
|
end
|
69
61
|
|
70
62
|
if attributes.key?(:'delay_in_seconds')
|
@@ -76,8 +68,8 @@ module Notifo
|
|
76
68
|
# @return Array for valid properties with the reasons
|
77
69
|
def list_invalid_properties
|
78
70
|
invalid_properties = Array.new
|
79
|
-
if @
|
80
|
-
invalid_properties.push('invalid value for "
|
71
|
+
if @send.nil?
|
72
|
+
invalid_properties.push('invalid value for "send", send cannot be nil.')
|
81
73
|
end
|
82
74
|
|
83
75
|
invalid_properties
|
@@ -86,7 +78,7 @@ module Notifo
|
|
86
78
|
# Check to see if the all the properties in the model are valid
|
87
79
|
# @return true if the model is valid
|
88
80
|
def valid?
|
89
|
-
return false if @
|
81
|
+
return false if @send.nil?
|
90
82
|
true
|
91
83
|
end
|
92
84
|
|
@@ -95,7 +87,7 @@ module Notifo
|
|
95
87
|
def ==(o)
|
96
88
|
return true if self.equal?(o)
|
97
89
|
self.class == o.class &&
|
98
|
-
|
90
|
+
send == o.send &&
|
99
91
|
delay_in_seconds == o.delay_in_seconds
|
100
92
|
end
|
101
93
|
|
@@ -108,7 +100,7 @@ module Notifo
|
|
108
100
|
# Calculates hash code according to all attributes.
|
109
101
|
# @return [Integer] Hash code
|
110
102
|
def hash
|
111
|
-
[
|
103
|
+
[send, delay_in_seconds].hash
|
112
104
|
end
|
113
105
|
|
114
106
|
# Builds the object from hash
|
@@ -124,9 +116,7 @@ module Notifo
|
|
124
116
|
def build_from_hash(attributes)
|
125
117
|
return nil unless attributes.is_a?(Hash)
|
126
118
|
self.class.openapi_types.each_pair do |key, type|
|
127
|
-
if
|
128
|
-
self.send("#{key}=", nil)
|
129
|
-
elsif type =~ /\AArray<(.*)>/i
|
119
|
+
if type =~ /\AArray<(.*)>/i
|
130
120
|
# check to ensure the input is an array given that the attribute
|
131
121
|
# is documented as an array but the input is not
|
132
122
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
@@ -134,6 +124,8 @@ module Notifo
|
|
134
124
|
end
|
135
125
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
136
126
|
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
127
|
+
elsif attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
128
|
+
self.send("#{key}=", nil)
|
137
129
|
end
|
138
130
|
end
|
139
131
|
|
@@ -146,8 +138,8 @@ module Notifo
|
|
146
138
|
# @return [Object] Deserialized data
|
147
139
|
def _deserialize(type, value)
|
148
140
|
case type.to_sym
|
149
|
-
when :
|
150
|
-
|
141
|
+
when :DateTime
|
142
|
+
DateTime.parse(value)
|
151
143
|
when :Date
|
152
144
|
Date.parse(value)
|
153
145
|
when :String
|
@@ -177,9 +169,7 @@ module Notifo
|
|
177
169
|
end
|
178
170
|
end
|
179
171
|
else # model
|
180
|
-
|
181
|
-
klass = Notifo.const_get(type)
|
182
|
-
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
172
|
+
SwaggerClient.const_get(type).build_from_hash(value)
|
183
173
|
end
|
184
174
|
end
|
185
175
|
|
@@ -227,8 +217,5 @@ module Notifo
|
|
227
217
|
else
|
228
218
|
value
|
229
219
|
end
|
230
|
-
end
|
231
|
-
|
232
|
-
end
|
233
|
-
|
220
|
+
end end
|
234
221
|
end
|
@@ -1,19 +1,17 @@
|
|
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
|
-
module
|
14
|
+
module SwaggerClient
|
17
15
|
class ProfileDto
|
18
16
|
# The full name of the user.
|
19
17
|
attr_accessor :full_name
|
@@ -53,45 +51,37 @@ module Notifo
|
|
53
51
|
}
|
54
52
|
end
|
55
53
|
|
56
|
-
# Returns all the JSON keys this model knows about
|
57
|
-
def self.acceptable_attributes
|
58
|
-
attribute_map.values
|
59
|
-
end
|
60
|
-
|
61
54
|
# Attribute type mapping.
|
62
55
|
def self.openapi_types
|
63
56
|
{
|
64
|
-
:'full_name' => :'
|
65
|
-
:'email_address' => :'
|
66
|
-
:'phone_number' => :'
|
67
|
-
:'preferred_language' => :'
|
68
|
-
:'preferred_timezone' => :'
|
69
|
-
:'supported_languages' => :'
|
70
|
-
:'supported_timezones' => :'
|
71
|
-
:'settings' => :'
|
57
|
+
:'full_name' => :'Object',
|
58
|
+
:'email_address' => :'Object',
|
59
|
+
:'phone_number' => :'Object',
|
60
|
+
:'preferred_language' => :'Object',
|
61
|
+
:'preferred_timezone' => :'Object',
|
62
|
+
:'supported_languages' => :'Object',
|
63
|
+
:'supported_timezones' => :'Object',
|
64
|
+
:'settings' => :'Object'
|
72
65
|
}
|
73
66
|
end
|
74
67
|
|
75
68
|
# List of attributes with nullable: true
|
76
69
|
def self.openapi_nullable
|
77
70
|
Set.new([
|
78
|
-
:'phone_number',
|
79
|
-
:'preferred_language',
|
80
|
-
:'preferred_timezone',
|
81
71
|
])
|
82
72
|
end
|
83
|
-
|
73
|
+
|
84
74
|
# Initializes the object
|
85
75
|
# @param [Hash] attributes Model attributes in the form of hash
|
86
76
|
def initialize(attributes = {})
|
87
77
|
if (!attributes.is_a?(Hash))
|
88
|
-
fail ArgumentError, "The input argument (attributes) must be a hash in `
|
78
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `SwaggerClient::ProfileDto` initialize method"
|
89
79
|
end
|
90
80
|
|
91
81
|
# check to see if the attribute exists and convert string to symbol for hash key
|
92
82
|
attributes = attributes.each_with_object({}) { |(k, v), h|
|
93
83
|
if (!self.class.attribute_map.key?(k.to_sym))
|
94
|
-
fail ArgumentError, "`#{k}` is not a valid attribute in `
|
84
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `SwaggerClient::ProfileDto`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
95
85
|
end
|
96
86
|
h[k.to_sym] = v
|
97
87
|
}
|
@@ -143,18 +133,10 @@ module Notifo
|
|
143
133
|
invalid_properties.push('invalid value for "full_name", full_name cannot be nil.')
|
144
134
|
end
|
145
135
|
|
146
|
-
if @full_name.to_s.length < 1
|
147
|
-
invalid_properties.push('invalid value for "full_name", the character length must be great than or equal to 1.')
|
148
|
-
end
|
149
|
-
|
150
136
|
if @email_address.nil?
|
151
137
|
invalid_properties.push('invalid value for "email_address", email_address cannot be nil.')
|
152
138
|
end
|
153
139
|
|
154
|
-
if @email_address.to_s.length < 1
|
155
|
-
invalid_properties.push('invalid value for "email_address", the character length must be great than or equal to 1.')
|
156
|
-
end
|
157
|
-
|
158
140
|
if @supported_languages.nil?
|
159
141
|
invalid_properties.push('invalid value for "supported_languages", supported_languages cannot be nil.')
|
160
142
|
end
|
@@ -174,43 +156,13 @@ module Notifo
|
|
174
156
|
# @return true if the model is valid
|
175
157
|
def valid?
|
176
158
|
return false if @full_name.nil?
|
177
|
-
return false if @full_name.to_s.length < 1
|
178
159
|
return false if @email_address.nil?
|
179
|
-
return false if @email_address.to_s.length < 1
|
180
160
|
return false if @supported_languages.nil?
|
181
161
|
return false if @supported_timezones.nil?
|
182
162
|
return false if @settings.nil?
|
183
163
|
true
|
184
164
|
end
|
185
165
|
|
186
|
-
# Custom attribute writer method with validation
|
187
|
-
# @param [Object] full_name Value to be assigned
|
188
|
-
def full_name=(full_name)
|
189
|
-
if full_name.nil?
|
190
|
-
fail ArgumentError, 'full_name cannot be nil'
|
191
|
-
end
|
192
|
-
|
193
|
-
if full_name.to_s.length < 1
|
194
|
-
fail ArgumentError, 'invalid value for "full_name", the character length must be great than or equal to 1.'
|
195
|
-
end
|
196
|
-
|
197
|
-
@full_name = full_name
|
198
|
-
end
|
199
|
-
|
200
|
-
# Custom attribute writer method with validation
|
201
|
-
# @param [Object] email_address Value to be assigned
|
202
|
-
def email_address=(email_address)
|
203
|
-
if email_address.nil?
|
204
|
-
fail ArgumentError, 'email_address cannot be nil'
|
205
|
-
end
|
206
|
-
|
207
|
-
if email_address.to_s.length < 1
|
208
|
-
fail ArgumentError, 'invalid value for "email_address", the character length must be great than or equal to 1.'
|
209
|
-
end
|
210
|
-
|
211
|
-
@email_address = email_address
|
212
|
-
end
|
213
|
-
|
214
166
|
# Checks equality by comparing each attribute.
|
215
167
|
# @param [Object] Object to be compared
|
216
168
|
def ==(o)
|
@@ -251,9 +203,7 @@ module Notifo
|
|
251
203
|
def build_from_hash(attributes)
|
252
204
|
return nil unless attributes.is_a?(Hash)
|
253
205
|
self.class.openapi_types.each_pair do |key, type|
|
254
|
-
if
|
255
|
-
self.send("#{key}=", nil)
|
256
|
-
elsif type =~ /\AArray<(.*)>/i
|
206
|
+
if type =~ /\AArray<(.*)>/i
|
257
207
|
# check to ensure the input is an array given that the attribute
|
258
208
|
# is documented as an array but the input is not
|
259
209
|
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
@@ -261,6 +211,8 @@ module Notifo
|
|
261
211
|
end
|
262
212
|
elsif !attributes[self.class.attribute_map[key]].nil?
|
263
213
|
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
214
|
+
elsif attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
215
|
+
self.send("#{key}=", nil)
|
264
216
|
end
|
265
217
|
end
|
266
218
|
|
@@ -273,8 +225,8 @@ module Notifo
|
|
273
225
|
# @return [Object] Deserialized data
|
274
226
|
def _deserialize(type, value)
|
275
227
|
case type.to_sym
|
276
|
-
when :
|
277
|
-
|
228
|
+
when :DateTime
|
229
|
+
DateTime.parse(value)
|
278
230
|
when :Date
|
279
231
|
Date.parse(value)
|
280
232
|
when :String
|
@@ -304,9 +256,7 @@ module Notifo
|
|
304
256
|
end
|
305
257
|
end
|
306
258
|
else # model
|
307
|
-
|
308
|
-
klass = Notifo.const_get(type)
|
309
|
-
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
259
|
+
SwaggerClient.const_get(type).build_from_hash(value)
|
310
260
|
end
|
311
261
|
end
|
312
262
|
|
@@ -354,8 +304,5 @@ module Notifo
|
|
354
304
|
else
|
355
305
|
value
|
356
306
|
end
|
357
|
-
end
|
358
|
-
|
359
|
-
end
|
360
|
-
|
307
|
+
end end
|
361
308
|
end
|