bombbomb 2.0.25797 → 2.0.25798

Sign up to get free protection for your applications and to get access to all the features.
Files changed (75) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +7 -0
  3. data/README.md +68 -33
  4. data/Rakefile +8 -3
  5. data/bombbomb.gemspec +8 -17
  6. data/docs/AccountsApi.md +164 -5
  7. data/docs/AutomationsApi.md +52 -0
  8. data/docs/ClientGroupAssetMetaData.md +11 -0
  9. data/docs/ContactsApi.md +9 -6
  10. data/docs/EmailsApi.md +220 -0
  11. data/docs/FormsApi.md +60 -0
  12. data/docs/InlineResponse200.md +1 -1
  13. data/docs/IntegrationsApi.md +223 -0
  14. data/docs/JerichoConfiguration.md +2 -0
  15. data/docs/PromptMonthlyPerformance.md +11 -0
  16. data/docs/PromptOverview.md +11 -0
  17. data/docs/PromptSocialPrompt.md +20 -0
  18. data/docs/PromptsApi.md +230 -3
  19. data/docs/SocialsApi.md +167 -2
  20. data/docs/TeamsApi.md +300 -16
  21. data/docs/UsersApi.md +100 -0
  22. data/docs/VideoEmailPrompt.md +15 -15
  23. data/git_push.sh +1 -13
  24. data/lib/bombbomb.rb +8 -14
  25. data/lib/bombbomb/api/accounts_api.rb +189 -51
  26. data/lib/bombbomb/api/automations_api.rb +71 -30
  27. data/lib/bombbomb/api/contacts_api.rb +58 -86
  28. data/lib/bombbomb/api/curriculum_api.rb +8 -27
  29. data/lib/bombbomb/api/emails_api.rb +262 -66
  30. data/lib/bombbomb/api/files_api.rb +32 -53
  31. data/lib/bombbomb/api/forms_api.rb +77 -0
  32. data/lib/bombbomb/api/integrations_api.rb +238 -20
  33. data/lib/bombbomb/api/lists_api.rb +32 -53
  34. data/lib/bombbomb/api/orders_api.rb +8 -21
  35. data/lib/bombbomb/api/prompts_api.rb +347 -112
  36. data/lib/bombbomb/api/socials_api.rb +242 -87
  37. data/lib/bombbomb/api/teams_api.rb +485 -193
  38. data/lib/bombbomb/api/users_api.rb +119 -0
  39. data/lib/bombbomb/api/utilities_api.rb +23 -44
  40. data/lib/bombbomb/api/videos_api.rb +38 -55
  41. data/lib/bombbomb/api/webhooks_api.rb +23 -50
  42. data/lib/bombbomb/api_client.rb +55 -45
  43. data/lib/bombbomb/api_error.rb +9 -18
  44. data/lib/bombbomb/configuration.rb +8 -13
  45. data/lib/bombbomb/models/bb_web_hook.rb +6 -17
  46. data/lib/bombbomb/models/client_group_asset_meta_data.rb +215 -0
  47. data/lib/bombbomb/models/curriculum.rb +6 -17
  48. data/lib/bombbomb/models/curriculum_user_progress.rb +6 -17
  49. data/lib/bombbomb/models/curriculum_with_progress.rb +6 -17
  50. data/lib/bombbomb/models/hosted_doc.rb +6 -17
  51. data/lib/bombbomb/models/inline_response_200.rb +7 -18
  52. data/lib/bombbomb/models/inline_response_200_items.rb +1 -1
  53. data/lib/bombbomb/models/jericho_configuration.rb +34 -21
  54. data/lib/bombbomb/models/jericho_performance.rb +6 -17
  55. data/lib/bombbomb/models/o_auth_client.rb +6 -17
  56. data/lib/bombbomb/models/prompt_bot.rb +6 -17
  57. data/lib/bombbomb/models/prompt_monthly_performance.rb +219 -0
  58. data/lib/bombbomb/models/prompt_overview.rb +219 -0
  59. data/lib/bombbomb/models/prompt_social_prompt.rb +311 -0
  60. data/lib/bombbomb/models/sign_upload_request.rb +6 -17
  61. data/lib/bombbomb/models/sign_upload_response.rb +6 -17
  62. data/lib/bombbomb/models/string.rb +6 -17
  63. data/lib/bombbomb/models/team_public_representation.rb +6 -17
  64. data/lib/bombbomb/models/video_email_prompt.rb +128 -144
  65. data/lib/bombbomb/models/video_encoding_status_response.rb +6 -17
  66. data/lib/bombbomb/models/video_public_representation.rb +6 -17
  67. data/lib/bombbomb/models/video_recorder_method_response.rb +6 -17
  68. data/lib/bombbomb/version.rb +3 -14
  69. data/spec/api/forms_api_spec.rb +58 -0
  70. data/spec/api/users_api_spec.rb +57 -0
  71. data/spec/models/{inline_response_200_items_spec.rb → client_group_asset_meta_data_spec.rb} +8 -19
  72. data/spec/models/prompt_monthly_performance_spec.rb +60 -0
  73. data/spec/models/prompt_overview_spec.rb +60 -0
  74. data/spec/models/{prompt_bot_bot_spec.rb → prompt_social_prompt_spec.rb} +27 -15
  75. metadata +40 -20
@@ -0,0 +1,311 @@
1
+ =begin
2
+ #BombBomb
3
+
4
+ #We make it easy to build relationships using simple videos.
5
+
6
+ OpenAPI spec version: 2.0.831
7
+
8
+ Generated by: https://github.com/swagger-api/swagger-codegen.git
9
+ Swagger Codegen version: 2.3.1
10
+
11
+ =end
12
+
13
+ require 'date'
14
+
15
+ module BombBomb
16
+ # The Prompt\\SocialPrompt class
17
+ class PromptSocialPrompt
18
+ # The identifier of the prompt. Read Only.
19
+ attr_accessor :id
20
+
21
+ # The prompt's owner. Read Only.
22
+ attr_accessor :user_id
23
+
24
+ # If sent in a jericho context, this will have the jericho id
25
+ attr_accessor :jericho_id
26
+
27
+ # The prompt's subject line
28
+ attr_accessor :prompt_subject
29
+
30
+ # The suggested script of the prompt.
31
+ attr_accessor :prompt_html
32
+
33
+ # When the final email is scheduled to be sent
34
+ attr_accessor :scheduled_send_date
35
+
36
+ # The client group campaign that created the prompt.
37
+ attr_accessor :client_group_id
38
+
39
+ # The URL of a thumbnail image for this prompt
40
+ attr_accessor :thumbnail_url
41
+
42
+ # The status of the prompt: created = 0, sent = 10, recorded = 20, job_created = 30, timed_out = 40, declined = 50 Read Only
43
+ attr_accessor :status
44
+
45
+ # When the email was first sent out
46
+ attr_accessor :created_date
47
+
48
+ # When the user was last notified about a prompt email waiting for a video
49
+ attr_accessor :last_notified
50
+
51
+ # The sendMechanism property
52
+ attr_accessor :send_mechanism
53
+
54
+ # The types of mechanisms this prompt can send.
55
+ attr_accessor :send_types
56
+
57
+
58
+ # Attribute mapping from ruby-style variable name to JSON key.
59
+ def self.attribute_map
60
+ {
61
+ :'id' => :'id',
62
+ :'user_id' => :'userId',
63
+ :'jericho_id' => :'jerichoId',
64
+ :'prompt_subject' => :'promptSubject',
65
+ :'prompt_html' => :'promptHtml',
66
+ :'scheduled_send_date' => :'scheduledSendDate',
67
+ :'client_group_id' => :'clientGroupId',
68
+ :'thumbnail_url' => :'thumbnailUrl',
69
+ :'status' => :'status',
70
+ :'created_date' => :'createdDate',
71
+ :'last_notified' => :'lastNotified',
72
+ :'send_mechanism' => :'sendMechanism',
73
+ :'send_types' => :'sendTypes'
74
+ }
75
+ end
76
+
77
+ # Attribute type mapping.
78
+ def self.swagger_types
79
+ {
80
+ :'id' => :'String',
81
+ :'user_id' => :'String',
82
+ :'jericho_id' => :'String',
83
+ :'prompt_subject' => :'String',
84
+ :'prompt_html' => :'String',
85
+ :'scheduled_send_date' => :'DateTime',
86
+ :'client_group_id' => :'String',
87
+ :'thumbnail_url' => :'String',
88
+ :'status' => :'Integer',
89
+ :'created_date' => :'DateTime',
90
+ :'last_notified' => :'DateTime',
91
+ :'send_mechanism' => :'DateTime',
92
+ :'send_types' => :'Array<String>'
93
+ }
94
+ end
95
+
96
+ # Initializes the object
97
+ # @param [Hash] attributes Model attributes in the form of hash
98
+ def initialize(attributes = {})
99
+ return unless attributes.is_a?(Hash)
100
+
101
+ # convert string to symbol for hash key
102
+ attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
103
+
104
+ if attributes.has_key?(:'id')
105
+ self.id = attributes[:'id']
106
+ end
107
+
108
+ if attributes.has_key?(:'userId')
109
+ self.user_id = attributes[:'userId']
110
+ end
111
+
112
+ if attributes.has_key?(:'jerichoId')
113
+ self.jericho_id = attributes[:'jerichoId']
114
+ end
115
+
116
+ if attributes.has_key?(:'promptSubject')
117
+ self.prompt_subject = attributes[:'promptSubject']
118
+ end
119
+
120
+ if attributes.has_key?(:'promptHtml')
121
+ self.prompt_html = attributes[:'promptHtml']
122
+ end
123
+
124
+ if attributes.has_key?(:'scheduledSendDate')
125
+ self.scheduled_send_date = attributes[:'scheduledSendDate']
126
+ end
127
+
128
+ if attributes.has_key?(:'clientGroupId')
129
+ self.client_group_id = attributes[:'clientGroupId']
130
+ end
131
+
132
+ if attributes.has_key?(:'thumbnailUrl')
133
+ self.thumbnail_url = attributes[:'thumbnailUrl']
134
+ end
135
+
136
+ if attributes.has_key?(:'status')
137
+ self.status = attributes[:'status']
138
+ end
139
+
140
+ if attributes.has_key?(:'createdDate')
141
+ self.created_date = attributes[:'createdDate']
142
+ end
143
+
144
+ if attributes.has_key?(:'lastNotified')
145
+ self.last_notified = attributes[:'lastNotified']
146
+ end
147
+
148
+ if attributes.has_key?(:'sendMechanism')
149
+ self.send_mechanism = attributes[:'sendMechanism']
150
+ end
151
+
152
+ if attributes.has_key?(:'sendTypes')
153
+ if (value = attributes[:'sendTypes']).is_a?(Array)
154
+ self.send_types = value
155
+ end
156
+ end
157
+
158
+ end
159
+
160
+ # Show invalid properties with the reasons. Usually used together with valid?
161
+ # @return Array for valid properties with the reasons
162
+ def list_invalid_properties
163
+ invalid_properties = Array.new
164
+ return invalid_properties
165
+ end
166
+
167
+ # Check to see if the all the properties in the model are valid
168
+ # @return true if the model is valid
169
+ def valid?
170
+ return true
171
+ end
172
+
173
+ # Checks equality by comparing each attribute.
174
+ # @param [Object] Object to be compared
175
+ def ==(o)
176
+ return true if self.equal?(o)
177
+ self.class == o.class &&
178
+ id == o.id &&
179
+ user_id == o.user_id &&
180
+ jericho_id == o.jericho_id &&
181
+ prompt_subject == o.prompt_subject &&
182
+ prompt_html == o.prompt_html &&
183
+ scheduled_send_date == o.scheduled_send_date &&
184
+ client_group_id == o.client_group_id &&
185
+ thumbnail_url == o.thumbnail_url &&
186
+ status == o.status &&
187
+ created_date == o.created_date &&
188
+ last_notified == o.last_notified &&
189
+ send_mechanism == o.send_mechanism &&
190
+ send_types == o.send_types
191
+ end
192
+
193
+ # @see the `==` method
194
+ # @param [Object] Object to be compared
195
+ def eql?(o)
196
+ self == o
197
+ end
198
+
199
+ # Calculates hash code according to all attributes.
200
+ # @return [Fixnum] Hash code
201
+ def hash
202
+ [id, user_id, jericho_id, prompt_subject, prompt_html, scheduled_send_date, client_group_id, thumbnail_url, status, created_date, last_notified, send_mechanism, send_types].hash
203
+ end
204
+
205
+ # Builds the object from hash
206
+ # @param [Hash] attributes Model attributes in the form of hash
207
+ # @return [Object] Returns the model itself
208
+ def build_from_hash(attributes)
209
+ return nil unless attributes.is_a?(Hash)
210
+ self.class.swagger_types.each_pair do |key, type|
211
+ if type =~ /\AArray<(.*)>/i
212
+ # check to ensure the input is an array given that the the attribute
213
+ # is documented as an array but the input is not
214
+ if attributes[self.class.attribute_map[key]].is_a?(Array)
215
+ self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
216
+ end
217
+ elsif !attributes[self.class.attribute_map[key]].nil?
218
+ self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
219
+ end # or else data not found in attributes(hash), not an issue as the data can be optional
220
+ end
221
+
222
+ self
223
+ end
224
+
225
+ # Deserializes the data based on type
226
+ # @param string type Data type
227
+ # @param string value Value to be deserialized
228
+ # @return [Object] Deserialized data
229
+ def _deserialize(type, value)
230
+ case type.to_sym
231
+ when :DateTime
232
+ DateTime.parse(value)
233
+ when :Date
234
+ Date.parse(value)
235
+ when :String
236
+ value.to_s
237
+ when :Integer
238
+ value.to_i
239
+ when :Float
240
+ value.to_f
241
+ when :BOOLEAN
242
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
243
+ true
244
+ else
245
+ false
246
+ end
247
+ when :Object
248
+ # generic object (usually a Hash), return directly
249
+ value
250
+ when /\AArray<(?<inner_type>.+)>\z/
251
+ inner_type = Regexp.last_match[:inner_type]
252
+ value.map { |v| _deserialize(inner_type, v) }
253
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
254
+ k_type = Regexp.last_match[:k_type]
255
+ v_type = Regexp.last_match[:v_type]
256
+ {}.tap do |hash|
257
+ value.each do |k, v|
258
+ hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
259
+ end
260
+ end
261
+ else # model
262
+ temp_model = BombBomb.const_get(type).new
263
+ temp_model.build_from_hash(value)
264
+ end
265
+ end
266
+
267
+ # Returns the string representation of the object
268
+ # @return [String] String presentation of the object
269
+ def to_s
270
+ to_hash.to_s
271
+ end
272
+
273
+ # to_body is an alias to to_hash (backward compatibility)
274
+ # @return [Hash] Returns the object in the form of hash
275
+ def to_body
276
+ to_hash
277
+ end
278
+
279
+ # Returns the object in the form of hash
280
+ # @return [Hash] Returns the object in the form of hash
281
+ def to_hash
282
+ hash = {}
283
+ self.class.attribute_map.each_pair do |attr, param|
284
+ value = self.send(attr)
285
+ next if value.nil?
286
+ hash[param] = _to_hash(value)
287
+ end
288
+ hash
289
+ end
290
+
291
+ # Outputs non-array value in the form of hash
292
+ # For object, use to_hash. Otherwise, just return the value
293
+ # @param [Object] value Any valid value
294
+ # @return [Hash] Returns the value in the form of hash
295
+ def _to_hash(value)
296
+ if value.is_a?(Array)
297
+ value.compact.map{ |v| _to_hash(v) }
298
+ elsif value.is_a?(Hash)
299
+ {}.tap do |hash|
300
+ value.each { |k, v| hash[k] = _to_hash(v) }
301
+ end
302
+ elsif value.respond_to? :to_hash
303
+ value.to_hash
304
+ else
305
+ value
306
+ end
307
+ end
308
+
309
+ end
310
+
311
+ end
@@ -3,21 +3,10 @@
3
3
 
4
4
  #We make it easy to build relationships using simple videos.
5
5
 
6
- OpenAPI spec version: 2.0.25797
6
+ OpenAPI spec version: 2.0.831
7
7
 
8
8
  Generated by: https://github.com/swagger-api/swagger-codegen.git
9
-
10
- Licensed under the Apache License, Version 2.0 (the "License");
11
- you may not use this file except in compliance with the License.
12
- You may obtain a copy of the License at
13
-
14
- http://www.apache.org/licenses/LICENSE-2.0
15
-
16
- Unless required by applicable law or agreed to in writing, software
17
- distributed under the License is distributed on an "AS IS" BASIS,
18
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19
- See the License for the specific language governing permissions and
20
- limitations under the License.
9
+ Swagger Codegen version: 2.3.1
21
10
 
22
11
  =end
23
12
 
@@ -68,7 +57,7 @@ module BombBomb
68
57
  end
69
58
 
70
59
  # Show invalid properties with the reasons. Usually used together with valid?
71
- # @return Array for valid properies with the reasons
60
+ # @return Array for valid properties with the reasons
72
61
  def list_invalid_properties
73
62
  invalid_properties = Array.new
74
63
  return invalid_properties
@@ -107,7 +96,7 @@ module BombBomb
107
96
  def build_from_hash(attributes)
108
97
  return nil unless attributes.is_a?(Hash)
109
98
  self.class.swagger_types.each_pair do |key, type|
110
- if type =~ /^Array<(.*)>/i
99
+ if type =~ /\AArray<(.*)>/i
111
100
  # check to ensure the input is an array given that the the attribute
112
101
  # is documented as an array but the input is not
113
102
  if attributes[self.class.attribute_map[key]].is_a?(Array)
@@ -138,7 +127,7 @@ module BombBomb
138
127
  when :Float
139
128
  value.to_f
140
129
  when :BOOLEAN
141
- if value.to_s =~ /^(true|t|yes|y|1)$/i
130
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
142
131
  true
143
132
  else
144
133
  false
@@ -149,7 +138,7 @@ module BombBomb
149
138
  when /\AArray<(?<inner_type>.+)>\z/
150
139
  inner_type = Regexp.last_match[:inner_type]
151
140
  value.map { |v| _deserialize(inner_type, v) }
152
- when /\AHash<(?<k_type>.+), (?<v_type>.+)>\z/
141
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
153
142
  k_type = Regexp.last_match[:k_type]
154
143
  v_type = Regexp.last_match[:v_type]
155
144
  {}.tap do |hash|
@@ -3,21 +3,10 @@
3
3
 
4
4
  #We make it easy to build relationships using simple videos.
5
5
 
6
- OpenAPI spec version: 2.0.25797
6
+ OpenAPI spec version: 2.0.831
7
7
 
8
8
  Generated by: https://github.com/swagger-api/swagger-codegen.git
9
-
10
- Licensed under the Apache License, Version 2.0 (the "License");
11
- you may not use this file except in compliance with the License.
12
- You may obtain a copy of the License at
13
-
14
- http://www.apache.org/licenses/LICENSE-2.0
15
-
16
- Unless required by applicable law or agreed to in writing, software
17
- distributed under the License is distributed on an "AS IS" BASIS,
18
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19
- See the License for the specific language governing permissions and
20
- limitations under the License.
9
+ Swagger Codegen version: 2.3.1
21
10
 
22
11
  =end
23
12
 
@@ -68,7 +57,7 @@ module BombBomb
68
57
  end
69
58
 
70
59
  # Show invalid properties with the reasons. Usually used together with valid?
71
- # @return Array for valid properies with the reasons
60
+ # @return Array for valid properties with the reasons
72
61
  def list_invalid_properties
73
62
  invalid_properties = Array.new
74
63
  return invalid_properties
@@ -107,7 +96,7 @@ module BombBomb
107
96
  def build_from_hash(attributes)
108
97
  return nil unless attributes.is_a?(Hash)
109
98
  self.class.swagger_types.each_pair do |key, type|
110
- if type =~ /^Array<(.*)>/i
99
+ if type =~ /\AArray<(.*)>/i
111
100
  # check to ensure the input is an array given that the the attribute
112
101
  # is documented as an array but the input is not
113
102
  if attributes[self.class.attribute_map[key]].is_a?(Array)
@@ -138,7 +127,7 @@ module BombBomb
138
127
  when :Float
139
128
  value.to_f
140
129
  when :BOOLEAN
141
- if value.to_s =~ /^(true|t|yes|y|1)$/i
130
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
142
131
  true
143
132
  else
144
133
  false
@@ -149,7 +138,7 @@ module BombBomb
149
138
  when /\AArray<(?<inner_type>.+)>\z/
150
139
  inner_type = Regexp.last_match[:inner_type]
151
140
  value.map { |v| _deserialize(inner_type, v) }
152
- when /\AHash<(?<k_type>.+), (?<v_type>.+)>\z/
141
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
153
142
  k_type = Regexp.last_match[:k_type]
154
143
  v_type = Regexp.last_match[:v_type]
155
144
  {}.tap do |hash|
@@ -3,21 +3,10 @@
3
3
 
4
4
  #We make it easy to build relationships using simple videos.
5
5
 
6
- OpenAPI spec version: 2.0.25797
6
+ OpenAPI spec version: 2.0.831
7
7
 
8
8
  Generated by: https://github.com/swagger-api/swagger-codegen.git
9
-
10
- Licensed under the Apache License, Version 2.0 (the "License");
11
- you may not use this file except in compliance with the License.
12
- You may obtain a copy of the License at
13
-
14
- http://www.apache.org/licenses/LICENSE-2.0
15
-
16
- Unless required by applicable law or agreed to in writing, software
17
- distributed under the License is distributed on an "AS IS" BASIS,
18
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19
- See the License for the specific language governing permissions and
20
- limitations under the License.
9
+ Swagger Codegen version: 2.3.1
21
10
 
22
11
  =end
23
12
 
@@ -50,7 +39,7 @@ module BombBomb
50
39
  end
51
40
 
52
41
  # Show invalid properties with the reasons. Usually used together with valid?
53
- # @return Array for valid properies with the reasons
42
+ # @return Array for valid properties with the reasons
54
43
  def list_invalid_properties
55
44
  invalid_properties = Array.new
56
45
  return invalid_properties
@@ -87,7 +76,7 @@ module BombBomb
87
76
  def build_from_hash(attributes)
88
77
  return nil unless attributes.is_a?(Hash)
89
78
  self.class.swagger_types.each_pair do |key, type|
90
- if type =~ /^Array<(.*)>/i
79
+ if type =~ /\AArray<(.*)>/i
91
80
  # check to ensure the input is an array given that the the attribute
92
81
  # is documented as an array but the input is not
93
82
  if attributes[self.class.attribute_map[key]].is_a?(Array)
@@ -118,7 +107,7 @@ module BombBomb
118
107
  when :Float
119
108
  value.to_f
120
109
  when :BOOLEAN
121
- if value.to_s =~ /^(true|t|yes|y|1)$/i
110
+ if value.to_s =~ /\A(true|t|yes|y|1)\z/i
122
111
  true
123
112
  else
124
113
  false
@@ -129,7 +118,7 @@ module BombBomb
129
118
  when /\AArray<(?<inner_type>.+)>\z/
130
119
  inner_type = Regexp.last_match[:inner_type]
131
120
  value.map { |v| _deserialize(inner_type, v) }
132
- when /\AHash<(?<k_type>.+), (?<v_type>.+)>\z/
121
+ when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
133
122
  k_type = Regexp.last_match[:k_type]
134
123
  v_type = Regexp.last_match[:v_type]
135
124
  {}.tap do |hash|