sib-api-v3-sdk 8.0.0 → 8.1.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 +4 -4
- data/Gemfile +1 -1
- data/README.md +14 -11
- data/docs/CRMApi.md +85 -33
- data/docs/CreateSubAccount.md +1 -0
- data/docs/MasterAccountApi.md +57 -0
- data/docs/RequestContactImport.md +3 -2
- data/docs/SendSmtpEmail.md +3 -3
- data/docs/TaskTypes.md +10 -0
- data/lib/sib-api-v3-sdk/api/crm_api.rb +68 -22
- data/lib/sib-api-v3-sdk/api/master_account_api.rb +51 -0
- data/lib/sib-api-v3-sdk/api/transactional_emails_api.rb +2 -2
- data/lib/sib-api-v3-sdk/models/create_sub_account.rb +16 -1
- data/lib/sib-api-v3-sdk/models/get_email_event_report_events.rb +2 -2
- data/lib/sib-api-v3-sdk/models/request_contact_import.rb +15 -3
- data/lib/sib-api-v3-sdk/models/send_smtp_email.rb +3 -3
- data/lib/sib-api-v3-sdk/models/task_types.rb +206 -0
- data/lib/sib-api-v3-sdk/version.rb +1 -1
- data/lib/sib-api-v3-sdk.rb +1 -0
- data/spec/api/crm_api_spec.rb +21 -11
- data/spec/api/master_account_api_spec.rb +11 -0
- data/spec/models/create_sub_account_spec.rb +6 -0
- data/spec/models/get_email_event_report_events_spec.rb +1 -1
- data/spec/models/request_contact_import_spec.rb +6 -0
- data/spec/models/task_types_spec.rb +53 -0
- metadata +6 -2
@@ -30,7 +30,7 @@ module SibApiV3Sdk
|
|
30
30
|
end
|
31
31
|
|
32
32
|
|
33
|
-
# Get file
|
33
|
+
# Get file details.
|
34
34
|
# @param id File id to get file data.
|
35
35
|
# @param [Hash] opts the optional parameters
|
36
36
|
# @return [FileData]
|
@@ -39,7 +39,7 @@ module SibApiV3Sdk
|
|
39
39
|
data
|
40
40
|
end
|
41
41
|
|
42
|
-
# Get file
|
42
|
+
# Get file details
|
43
43
|
# @param id File id to get file data.
|
44
44
|
# @param [Hash] opts the optional parameters
|
45
45
|
# @return [Array<(FileData, Fixnum, Hash)>] FileData data, response status code and response headers
|
@@ -82,7 +82,7 @@ module SibApiV3Sdk
|
|
82
82
|
end
|
83
83
|
return data, status_code, headers
|
84
84
|
end
|
85
|
-
# Delete file
|
85
|
+
# Delete a file
|
86
86
|
# @param id File id to delete.
|
87
87
|
# @param [Hash] opts the optional parameters
|
88
88
|
# @return [nil]
|
@@ -91,7 +91,7 @@ module SibApiV3Sdk
|
|
91
91
|
nil
|
92
92
|
end
|
93
93
|
|
94
|
-
# Delete file
|
94
|
+
# Delete a file
|
95
95
|
# @param id File id to delete.
|
96
96
|
# @param [Hash] opts the optional parameters
|
97
97
|
# @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
|
@@ -133,7 +133,7 @@ module SibApiV3Sdk
|
|
133
133
|
end
|
134
134
|
return data, status_code, headers
|
135
135
|
end
|
136
|
-
# Download file
|
136
|
+
# Download a file
|
137
137
|
# @param id File id to download.
|
138
138
|
# @param [Hash] opts the optional parameters
|
139
139
|
# @return [nil]
|
@@ -142,7 +142,7 @@ module SibApiV3Sdk
|
|
142
142
|
nil
|
143
143
|
end
|
144
144
|
|
145
|
-
# Download file
|
145
|
+
# Download a file
|
146
146
|
# @param id File id to download.
|
147
147
|
# @param [Hash] opts the optional parameters
|
148
148
|
# @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
|
@@ -184,7 +184,7 @@ module SibApiV3Sdk
|
|
184
184
|
end
|
185
185
|
return data, status_code, headers
|
186
186
|
end
|
187
|
-
# Upload
|
187
|
+
# Upload a file
|
188
188
|
# @param file File data to create a file.
|
189
189
|
# @param [Hash] opts the optional parameters
|
190
190
|
# @option opts [Array<String>] :deals_ids Deal ids linked to a file
|
@@ -194,7 +194,7 @@ module SibApiV3Sdk
|
|
194
194
|
data
|
195
195
|
end
|
196
196
|
|
197
|
-
# Upload
|
197
|
+
# Upload a file
|
198
198
|
# @param file File data to create a file.
|
199
199
|
# @param [Hash] opts the optional parameters
|
200
200
|
# @option opts [Array<String>] :deals_ids Deal ids linked to a file
|
@@ -240,7 +240,7 @@ module SibApiV3Sdk
|
|
240
240
|
end
|
241
241
|
return data, status_code, headers
|
242
242
|
end
|
243
|
-
# Delete
|
243
|
+
# Delete a note
|
244
244
|
# @param id Note ID to delete
|
245
245
|
# @param [Hash] opts the optional parameters
|
246
246
|
# @return [nil]
|
@@ -249,7 +249,7 @@ module SibApiV3Sdk
|
|
249
249
|
nil
|
250
250
|
end
|
251
251
|
|
252
|
-
# Delete
|
252
|
+
# Delete a note
|
253
253
|
# @param id Note ID to delete
|
254
254
|
# @param [Hash] opts the optional parameters
|
255
255
|
# @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
|
@@ -291,7 +291,7 @@ module SibApiV3Sdk
|
|
291
291
|
end
|
292
292
|
return data, status_code, headers
|
293
293
|
end
|
294
|
-
# Get
|
294
|
+
# Get a note
|
295
295
|
# @param id Note ID to get
|
296
296
|
# @param [Hash] opts the optional parameters
|
297
297
|
# @return [Note]
|
@@ -300,7 +300,7 @@ module SibApiV3Sdk
|
|
300
300
|
data
|
301
301
|
end
|
302
302
|
|
303
|
-
# Get
|
303
|
+
# Get a note
|
304
304
|
# @param id Note ID to get
|
305
305
|
# @param [Hash] opts the optional parameters
|
306
306
|
# @return [Array<(Note, Fixnum, Hash)>] Note data, response status code and response headers
|
@@ -401,7 +401,7 @@ module SibApiV3Sdk
|
|
401
401
|
end
|
402
402
|
return data, status_code, headers
|
403
403
|
end
|
404
|
-
# Create a
|
404
|
+
# Create a note
|
405
405
|
# @param body Note data to create a note.
|
406
406
|
# @param [Hash] opts the optional parameters
|
407
407
|
# @return [Note]
|
@@ -410,7 +410,7 @@ module SibApiV3Sdk
|
|
410
410
|
data
|
411
411
|
end
|
412
412
|
|
413
|
-
# Create a
|
413
|
+
# Create a note
|
414
414
|
# @param body Note data to create a note.
|
415
415
|
# @param [Hash] opts the optional parameters
|
416
416
|
# @return [Array<(Note, Fixnum, Hash)>] Note data, response status code and response headers
|
@@ -453,7 +453,7 @@ module SibApiV3Sdk
|
|
453
453
|
end
|
454
454
|
return data, status_code, headers
|
455
455
|
end
|
456
|
-
# Delete
|
456
|
+
# Delete a task
|
457
457
|
# @param id
|
458
458
|
# @param [Hash] opts the optional parameters
|
459
459
|
# @return [nil]
|
@@ -462,7 +462,7 @@ module SibApiV3Sdk
|
|
462
462
|
nil
|
463
463
|
end
|
464
464
|
|
465
|
-
# Delete
|
465
|
+
# Delete a task
|
466
466
|
# @param id
|
467
467
|
# @param [Hash] opts the optional parameters
|
468
468
|
# @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
|
@@ -504,7 +504,7 @@ module SibApiV3Sdk
|
|
504
504
|
end
|
505
505
|
return data, status_code, headers
|
506
506
|
end
|
507
|
-
# Get
|
507
|
+
# Get a task
|
508
508
|
# @param id
|
509
509
|
# @param [Hash] opts the optional parameters
|
510
510
|
# @return [Task]
|
@@ -513,7 +513,7 @@ module SibApiV3Sdk
|
|
513
513
|
data
|
514
514
|
end
|
515
515
|
|
516
|
-
# Get
|
516
|
+
# Get a task
|
517
517
|
# @param id
|
518
518
|
# @param [Hash] opts the optional parameters
|
519
519
|
# @return [Array<(Task, Fixnum, Hash)>] Task data, response status code and response headers
|
@@ -556,7 +556,7 @@ module SibApiV3Sdk
|
|
556
556
|
end
|
557
557
|
return data, status_code, headers
|
558
558
|
end
|
559
|
-
# Update
|
559
|
+
# Update a task
|
560
560
|
# @param id
|
561
561
|
# @param body Updated task details.
|
562
562
|
# @param [Hash] opts the optional parameters
|
@@ -566,7 +566,7 @@ module SibApiV3Sdk
|
|
566
566
|
data
|
567
567
|
end
|
568
568
|
|
569
|
-
# Update
|
569
|
+
# Update a task
|
570
570
|
# @param id
|
571
571
|
# @param body Updated task details.
|
572
572
|
# @param [Hash] opts the optional parameters
|
@@ -614,7 +614,7 @@ module SibApiV3Sdk
|
|
614
614
|
end
|
615
615
|
return data, status_code, headers
|
616
616
|
end
|
617
|
-
# Create a
|
617
|
+
# Create a task
|
618
618
|
# @param body Task name.
|
619
619
|
# @param [Hash] opts the optional parameters
|
620
620
|
# @return [Task]
|
@@ -623,7 +623,7 @@ module SibApiV3Sdk
|
|
623
623
|
data
|
624
624
|
end
|
625
625
|
|
626
|
-
# Create a
|
626
|
+
# Create a task
|
627
627
|
# @param body Task name.
|
628
628
|
# @param [Hash] opts the optional parameters
|
629
629
|
# @return [Array<(Task, Fixnum, Hash)>] Task data, response status code and response headers
|
@@ -666,5 +666,51 @@ module SibApiV3Sdk
|
|
666
666
|
end
|
667
667
|
return data, status_code, headers
|
668
668
|
end
|
669
|
+
# Get all task types
|
670
|
+
# @param [Hash] opts the optional parameters
|
671
|
+
# @return [TaskTypes]
|
672
|
+
def crm_tasktypes_get(opts = {})
|
673
|
+
data, _status_code, _headers = crm_tasktypes_get_with_http_info(opts)
|
674
|
+
data
|
675
|
+
end
|
676
|
+
|
677
|
+
# Get all task types
|
678
|
+
# @param [Hash] opts the optional parameters
|
679
|
+
# @return [Array<(TaskTypes, Fixnum, Hash)>] TaskTypes data, response status code and response headers
|
680
|
+
def crm_tasktypes_get_with_http_info(opts = {})
|
681
|
+
if @api_client.config.debugging
|
682
|
+
@api_client.config.logger.debug 'Calling API: CRMApi.crm_tasktypes_get ...'
|
683
|
+
end
|
684
|
+
# resource path
|
685
|
+
local_var_path = '/crm/tasktypes'
|
686
|
+
|
687
|
+
# query parameters
|
688
|
+
query_params = {}
|
689
|
+
|
690
|
+
# header parameters
|
691
|
+
header_params = {}
|
692
|
+
# HTTP header 'Accept' (if needed)
|
693
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
694
|
+
# HTTP header 'Content-Type'
|
695
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
696
|
+
|
697
|
+
# form parameters
|
698
|
+
form_params = {}
|
699
|
+
|
700
|
+
# http body (model)
|
701
|
+
post_body = nil
|
702
|
+
auth_names = ['api-key', 'partner-key']
|
703
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path,
|
704
|
+
:header_params => header_params,
|
705
|
+
:query_params => query_params,
|
706
|
+
:form_params => form_params,
|
707
|
+
:body => post_body,
|
708
|
+
:auth_names => auth_names,
|
709
|
+
:return_type => 'TaskTypes')
|
710
|
+
if @api_client.config.debugging
|
711
|
+
@api_client.config.logger.debug "API called: CRMApi#crm_tasktypes_get\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
712
|
+
end
|
713
|
+
return data, status_code, headers
|
714
|
+
end
|
669
715
|
end
|
670
716
|
end
|
@@ -140,6 +140,57 @@ module SibApiV3Sdk
|
|
140
140
|
end
|
141
141
|
return data, status_code, headers
|
142
142
|
end
|
143
|
+
# Delete a sub-account
|
144
|
+
# @param id Id of the sub-account organization to be deleted
|
145
|
+
# @param [Hash] opts the optional parameters
|
146
|
+
# @return [nil]
|
147
|
+
def corporate_sub_account_id_delete(id, opts = {})
|
148
|
+
corporate_sub_account_id_delete_with_http_info(id, opts)
|
149
|
+
nil
|
150
|
+
end
|
151
|
+
|
152
|
+
# Delete a sub-account
|
153
|
+
# @param id Id of the sub-account organization to be deleted
|
154
|
+
# @param [Hash] opts the optional parameters
|
155
|
+
# @return [Array<(nil, Fixnum, Hash)>] nil, response status code and response headers
|
156
|
+
def corporate_sub_account_id_delete_with_http_info(id, opts = {})
|
157
|
+
if @api_client.config.debugging
|
158
|
+
@api_client.config.logger.debug 'Calling API: MasterAccountApi.corporate_sub_account_id_delete ...'
|
159
|
+
end
|
160
|
+
# verify the required parameter 'id' is set
|
161
|
+
if @api_client.config.client_side_validation && id.nil?
|
162
|
+
fail ArgumentError, "Missing the required parameter 'id' when calling MasterAccountApi.corporate_sub_account_id_delete"
|
163
|
+
end
|
164
|
+
# resource path
|
165
|
+
local_var_path = '/corporate/subAccount/{id}'.sub('{' + 'id' + '}', id.to_s)
|
166
|
+
|
167
|
+
# query parameters
|
168
|
+
query_params = {}
|
169
|
+
|
170
|
+
# header parameters
|
171
|
+
header_params = {}
|
172
|
+
# HTTP header 'Accept' (if needed)
|
173
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
174
|
+
# HTTP header 'Content-Type'
|
175
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
176
|
+
|
177
|
+
# form parameters
|
178
|
+
form_params = {}
|
179
|
+
|
180
|
+
# http body (model)
|
181
|
+
post_body = nil
|
182
|
+
auth_names = ['api-key', 'partner-key']
|
183
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path,
|
184
|
+
:header_params => header_params,
|
185
|
+
:query_params => query_params,
|
186
|
+
:form_params => form_params,
|
187
|
+
:body => post_body,
|
188
|
+
:auth_names => auth_names)
|
189
|
+
if @api_client.config.debugging
|
190
|
+
@api_client.config.logger.debug "API called: MasterAccountApi#corporate_sub_account_id_delete\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
191
|
+
end
|
192
|
+
return data, status_code, headers
|
193
|
+
end
|
143
194
|
# Get sub-account details
|
144
195
|
# This endpoint will provide the details of specified sub-account organization
|
145
196
|
# @param id Id of the sub-account organization
|
@@ -438,8 +438,8 @@ module SibApiV3Sdk
|
|
438
438
|
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling TransactionalEmailsApi.get_email_event_report, must be smaller than or equal to 100.'
|
439
439
|
end
|
440
440
|
|
441
|
-
if @api_client.config.client_side_validation && opts[:'event'] && !['bounces', 'hardBounces', 'softBounces', 'delivered', 'spam', 'requests', 'opened', 'clicks', 'invalid', 'deferred', 'blocked', 'unsubscribed', 'error'].include?(opts[:'event'])
|
442
|
-
fail ArgumentError, 'invalid value for "event", must be one of bounces, hardBounces, softBounces, delivered, spam, requests, opened, clicks, invalid, deferred, blocked, unsubscribed, error'
|
441
|
+
if @api_client.config.client_side_validation && opts[:'event'] && !['bounces', 'hardBounces', 'softBounces', 'delivered', 'spam', 'requests', 'opened', 'clicks', 'invalid', 'deferred', 'blocked', 'unsubscribed', 'error', 'loadedByProxy'].include?(opts[:'event'])
|
442
|
+
fail ArgumentError, 'invalid value for "event", must be one of bounces, hardBounces, softBounces, delivered, spam, requests, opened, clicks, invalid, deferred, blocked, unsubscribed, error, loadedByProxy'
|
443
443
|
end
|
444
444
|
if @api_client.config.client_side_validation && opts[:'sort'] && !['asc', 'desc'].include?(opts[:'sort'])
|
445
445
|
fail ArgumentError, 'invalid value for "sort", must be one of asc, desc'
|
@@ -17,6 +17,9 @@ module SibApiV3Sdk
|
|
17
17
|
# Name of the organization
|
18
18
|
attr_accessor :company_name
|
19
19
|
|
20
|
+
# Email address for the organization
|
21
|
+
attr_accessor :email
|
22
|
+
|
20
23
|
# Language for identifying localization information
|
21
24
|
attr_accessor :language
|
22
25
|
|
@@ -49,6 +52,7 @@ module SibApiV3Sdk
|
|
49
52
|
def self.attribute_map
|
50
53
|
{
|
51
54
|
:'company_name' => :'companyName',
|
55
|
+
:'email' => :'email',
|
52
56
|
:'language' => :'language',
|
53
57
|
:'timezone' => :'timezone'
|
54
58
|
}
|
@@ -58,6 +62,7 @@ module SibApiV3Sdk
|
|
58
62
|
def self.swagger_types
|
59
63
|
{
|
60
64
|
:'company_name' => :'String',
|
65
|
+
:'email' => :'String',
|
61
66
|
:'language' => :'String',
|
62
67
|
:'timezone' => :'String'
|
63
68
|
}
|
@@ -75,6 +80,10 @@ module SibApiV3Sdk
|
|
75
80
|
self.company_name = attributes[:'companyName']
|
76
81
|
end
|
77
82
|
|
83
|
+
if attributes.has_key?(:'email')
|
84
|
+
self.email = attributes[:'email']
|
85
|
+
end
|
86
|
+
|
78
87
|
if attributes.has_key?(:'language')
|
79
88
|
self.language = attributes[:'language']
|
80
89
|
end
|
@@ -92,6 +101,10 @@ module SibApiV3Sdk
|
|
92
101
|
invalid_properties.push('invalid value for "company_name", company_name cannot be nil.')
|
93
102
|
end
|
94
103
|
|
104
|
+
if @email.nil?
|
105
|
+
invalid_properties.push('invalid value for "email", email cannot be nil.')
|
106
|
+
end
|
107
|
+
|
95
108
|
invalid_properties
|
96
109
|
end
|
97
110
|
|
@@ -99,6 +112,7 @@ module SibApiV3Sdk
|
|
99
112
|
# @return true if the model is valid
|
100
113
|
def valid?
|
101
114
|
return false if @company_name.nil?
|
115
|
+
return false if @email.nil?
|
102
116
|
language_validator = EnumAttributeValidator.new('String', ['en', 'fr', 'it', 'es', 'pt', 'de'])
|
103
117
|
return false unless language_validator.valid?(@language)
|
104
118
|
true
|
@@ -120,6 +134,7 @@ module SibApiV3Sdk
|
|
120
134
|
return true if self.equal?(o)
|
121
135
|
self.class == o.class &&
|
122
136
|
company_name == o.company_name &&
|
137
|
+
email == o.email &&
|
123
138
|
language == o.language &&
|
124
139
|
timezone == o.timezone
|
125
140
|
end
|
@@ -133,7 +148,7 @@ module SibApiV3Sdk
|
|
133
148
|
# Calculates hash code according to all attributes.
|
134
149
|
# @return [Fixnum] Hash code
|
135
150
|
def hash
|
136
|
-
[company_name, language, timezone].hash
|
151
|
+
[company_name, email, language, timezone].hash
|
137
152
|
end
|
138
153
|
|
139
154
|
# Builds the object from hash
|
@@ -186,7 +186,7 @@ module SibApiV3Sdk
|
|
186
186
|
return false if @date.nil?
|
187
187
|
return false if @message_id.nil?
|
188
188
|
return false if @event.nil?
|
189
|
-
event_validator = EnumAttributeValidator.new('String', ['bounces', 'hardBounces', 'softBounces', 'delivered', 'spam', 'requests', 'opened', 'clicks', 'invalid', 'deferred', 'blocked', 'unsubscribed', 'error'])
|
189
|
+
event_validator = EnumAttributeValidator.new('String', ['bounces', 'hardBounces', 'softBounces', 'delivered', 'spam', 'requests', 'opened', 'clicks', 'invalid', 'deferred', 'blocked', 'unsubscribed', 'error', 'loadedByProxy'])
|
190
190
|
return false unless event_validator.valid?(@event)
|
191
191
|
true
|
192
192
|
end
|
@@ -194,7 +194,7 @@ module SibApiV3Sdk
|
|
194
194
|
# Custom attribute writer method checking allowed values (enum).
|
195
195
|
# @param [Object] event Object to be assigned
|
196
196
|
def event=(event)
|
197
|
-
validator = EnumAttributeValidator.new('String', ['bounces', 'hardBounces', 'softBounces', 'delivered', 'spam', 'requests', 'opened', 'clicks', 'invalid', 'deferred', 'blocked', 'unsubscribed', 'error'])
|
197
|
+
validator = EnumAttributeValidator.new('String', ['bounces', 'hardBounces', 'softBounces', 'delivered', 'spam', 'requests', 'opened', 'clicks', 'invalid', 'deferred', 'blocked', 'unsubscribed', 'error', 'loadedByProxy'])
|
198
198
|
unless validator.valid?(event)
|
199
199
|
fail ArgumentError, 'invalid value for "event", must be one of #{validator.allowable_values}.'
|
200
200
|
end
|
@@ -14,12 +14,15 @@ require 'date'
|
|
14
14
|
|
15
15
|
module SibApiV3Sdk
|
16
16
|
class RequestContactImport
|
17
|
-
# Mandatory if fileBody is not defined. URL of the file to be imported (no local file). Possible file formats: .txt, .csv
|
17
|
+
# Mandatory if fileBody or jsonBody is not defined. URL of the file to be imported (no local file). Possible file formats: .txt, .csv, .json
|
18
18
|
attr_accessor :file_url
|
19
19
|
|
20
|
-
# Mandatory if fileUrl is not defined. CSV content to be imported. Use semicolon to separate multiple attributes. Maximum allowed file body size is 10MB . However we recommend a safe limit of around 8 MB to avoid the issues caused due to increase of file body size while parsing. Please use fileUrl instead to import bigger files.
|
20
|
+
# Mandatory if fileUrl and jsonBody is not defined. CSV content to be imported. Use semicolon to separate multiple attributes. Maximum allowed file body size is 10MB . However we recommend a safe limit of around 8 MB to avoid the issues caused due to increase of file body size while parsing. Please use fileUrl instead to import bigger files.
|
21
21
|
attr_accessor :file_body
|
22
22
|
|
23
|
+
# **Mandatory if fileUrl and fileBody is not defined.** JSON content to be imported. **Maximum allowed json body size is 10MB** . However we recommend a safe limit of around 8 MB to avoid the issues caused due to increase of json body size while parsing. Please use fileUrl instead to import bigger files.
|
24
|
+
attr_accessor :json_body
|
25
|
+
|
23
26
|
# Mandatory if newList is not defined. Ids of the lists in which the contacts shall be imported. For example, [2, 4, 7].
|
24
27
|
attr_accessor :list_ids
|
25
28
|
|
@@ -45,6 +48,7 @@ module SibApiV3Sdk
|
|
45
48
|
{
|
46
49
|
:'file_url' => :'fileUrl',
|
47
50
|
:'file_body' => :'fileBody',
|
51
|
+
:'json_body' => :'jsonBody',
|
48
52
|
:'list_ids' => :'listIds',
|
49
53
|
:'notify_url' => :'notifyUrl',
|
50
54
|
:'new_list' => :'newList',
|
@@ -60,6 +64,7 @@ module SibApiV3Sdk
|
|
60
64
|
{
|
61
65
|
:'file_url' => :'String',
|
62
66
|
:'file_body' => :'String',
|
67
|
+
:'json_body' => :'Array<Hash<String, Object>>',
|
63
68
|
:'list_ids' => :'Array<Integer>',
|
64
69
|
:'notify_url' => :'String',
|
65
70
|
:'new_list' => :'RequestContactImportNewList',
|
@@ -86,6 +91,12 @@ module SibApiV3Sdk
|
|
86
91
|
self.file_body = attributes[:'fileBody']
|
87
92
|
end
|
88
93
|
|
94
|
+
if attributes.has_key?(:'jsonBody')
|
95
|
+
if (value = attributes[:'jsonBody']).is_a?(Array)
|
96
|
+
self.json_body = value
|
97
|
+
end
|
98
|
+
end
|
99
|
+
|
89
100
|
if attributes.has_key?(:'listIds')
|
90
101
|
if (value = attributes[:'listIds']).is_a?(Array)
|
91
102
|
self.list_ids = value
|
@@ -145,6 +156,7 @@ module SibApiV3Sdk
|
|
145
156
|
self.class == o.class &&
|
146
157
|
file_url == o.file_url &&
|
147
158
|
file_body == o.file_body &&
|
159
|
+
json_body == o.json_body &&
|
148
160
|
list_ids == o.list_ids &&
|
149
161
|
notify_url == o.notify_url &&
|
150
162
|
new_list == o.new_list &&
|
@@ -163,7 +175,7 @@ module SibApiV3Sdk
|
|
163
175
|
# Calculates hash code according to all attributes.
|
164
176
|
# @return [Fixnum] Hash code
|
165
177
|
def hash
|
166
|
-
[file_url, file_body, list_ids, notify_url, new_list, email_blacklist, sms_blacklist, update_existing_contacts, empty_contacts_attributes].hash
|
178
|
+
[file_url, file_body, json_body, list_ids, notify_url, new_list, email_blacklist, sms_blacklist, update_existing_contacts, empty_contacts_attributes].hash
|
167
179
|
end
|
168
180
|
|
169
181
|
# Builds the object from hash
|
@@ -36,19 +36,19 @@ module SibApiV3Sdk
|
|
36
36
|
|
37
37
|
attr_accessor :reply_to
|
38
38
|
|
39
|
-
# Pass the absolute URL (no local file) or the base64 content of the attachment along with the attachment name (Mandatory if attachment content is passed). For example, `[{\"url\":\"https://attachment.domain.com/myAttachmentFromUrl.jpg\", \"name\":\"myAttachmentFromUrl.jpg\"}, {\"content\":\"base64 example content\", \"name\":\"myAttachmentFromBase64.jpg\"}]`. Allowed extensions for attachment file: xlsx, xls, ods, docx, docm, doc, csv, pdf, txt, gif, jpg, jpeg, png, tif, tiff, rtf, bmp, cgm, css, shtml, html, htm, zip, xml, ppt, pptx, tar, ez, ics, mobi, msg, pub, eps, odt, mp3, m4a, m4v, wma, ogg, flac, wav, aif, aifc, aiff, mp4, mov, avi, mkv, mpeg, mpg, wmv and
|
39
|
+
# Pass the absolute URL (no local file) or the base64 content of the attachment along with the attachment name (Mandatory if attachment content is passed). For example, `[{\"url\":\"https://attachment.domain.com/myAttachmentFromUrl.jpg\", \"name\":\"myAttachmentFromUrl.jpg\"}, {\"content\":\"base64 example content\", \"name\":\"myAttachmentFromBase64.jpg\"}]`. Allowed extensions for attachment file: xlsx, xls, ods, docx, docm, doc, csv, pdf, txt, gif, jpg, jpeg, png, tif, tiff, rtf, bmp, cgm, css, shtml, html, htm, zip, xml, ppt, pptx, tar, ez, ics, mobi, msg, pub, eps, odt, mp3, m4a, m4v, wma, ogg, flac, wav, aif, aifc, aiff, mp4, mov, avi, mkv, mpeg, mpg, wmv, pkpass and xlsm ( If 'templateId' is passed and is in New Template Language format then both attachment url and content are accepted. If template is in Old template Language format, then 'attachment' is ignored )
|
40
40
|
attr_accessor :attachment
|
41
41
|
|
42
42
|
# Pass the set of custom headers (not the standard headers) that shall be sent along the mail headers in the original email. 'sender.ip' header can be set (only for dedicated ip users) to mention the IP to be used for sending transactional emails. Headers are allowed in `This-Case-Only` (i.e. words separated by hyphen with first letter of each word in capital letter), they will be converted to such case styling if not in this format in the request payload. For example, `{\"sender.ip\":\"1.2.3.4\", \"X-Mailin-custom\":\"some_custom_header\", \"idempotencyKey\":\"abc-123\"}`.
|
43
43
|
attr_accessor :headers
|
44
44
|
|
45
|
-
# Id of the template.
|
45
|
+
# Id of the template.
|
46
46
|
attr_accessor :template_id
|
47
47
|
|
48
48
|
# Pass the set of attributes to customize the template. For example, {\"FNAME\":\"Joe\", \"LNAME\":\"Doe\"}. It's considered only if template is in New Template Language format.
|
49
49
|
attr_accessor :params
|
50
50
|
|
51
|
-
# You can customize and send out multiple versions of a templateId. Some global parameters such as **to(mandatory), bcc, cc, replyTo, subject** can also be customized specific to each version. Total number of recipients in one API request must not exceed
|
51
|
+
# You can customize and send out multiple versions of a mail. templateId can be customized only if global parameter contains templateId. htmlContent and textContent can be customized only if any of the two, htmlContent or textContent, is present in global parameters. Some global parameters such as **to(mandatory), bcc, cc, replyTo, subject** can also be customized specific to each version. Total number of recipients in one API request must not exceed 2000. However, you can still pass upto 99 recipients maximum in one message version. The size of individual params in all the messageVersions shall not exceed 100 KB limit and that of cumulative params shall not exceed 1000 KB. You can follow this **step-by-step guide** on how to use **messageVersions** to batch send emails - https://developers.sendinblue.com/docs/batch-send-transactional-emails
|
52
52
|
attr_accessor :message_versions
|
53
53
|
|
54
54
|
# Tag your emails to find them more easily
|