files.com 1.2.262 → 1.2.264

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.
package/_VERSION CHANGED
@@ -1 +1 @@
1
- 1.2.262
1
+ 1.2.264
@@ -15,6 +15,7 @@
15
15
  },
16
16
  "default_mime_type": "application/octet-stream",
17
17
  "mdn_validation_level": "none",
18
+ "signature_validation_level": "normal",
18
19
  "enable_dedicated_ips": true,
19
20
  "hex_public_certificate_serial": "A5:EB:C1:95:DC:D8:2B:E7",
20
21
  "public_certificate": "example",
@@ -35,7 +36,8 @@
35
36
  * `http_auth_username` (string): Username to send to server for HTTP Authentication.
36
37
  * `additional_http_headers` (object): Additional HTTP Headers for outgoing message sent to this partner.
37
38
  * `default_mime_type` (string): Default mime type of the file attached to the encrypted message
38
- * `mdn_validation_level` (string): How should Files.com evaluate message transfer success based on a partner's MDN response? This setting does not affect MDN storage; all MDNs received from a partner are always stored. `none`: MDN is stored for informational purposes only, a successful HTTPS transfer is a successful AS2 transfer. `weak`: Inspect the MDN for MIC and Disposition only. `normal`: `weak` plus validate MDN signature matches body, `strict`: `normal` but do not allow signatures from self-signed or incorrectly purposed certificates.
39
+ * `mdn_validation_level` (string): How should Files.com evaluate message transfer success based on a partner's MDN response? This setting does not affect MDN storage; all MDNs received from a partner are always stored. `none`: MDN is stored for informational purposes only, a successful HTTPS transfer is a successful AS2 transfer. `weak`: Inspect the MDN for MIC and Disposition only. `normal`: `weak` plus validate MDN signature matches body, `strict`: `normal` but do not allow signatures from self-signed or incorrectly purposed certificates. `auto`: Automatically set the correct value for this setting based on next mdn received.
40
+ * `signature_validation_level` (string): Should Files.com require signatures on incoming AS2 messages? `normal`: require that incoming messages are signed with a valid matching signature. `none`: Unsigned incoming messages are allowed. `auto`: Automatically set the correct value for this setting based on next message received.
39
41
  * `enable_dedicated_ips` (boolean): If `true`, we will use your site's dedicated IPs for all outbound connections to this AS2 Partner.
40
42
  * `hex_public_certificate_serial` (string): Serial of public certificate used for message security in hex format.
41
43
  * `public_certificate` (string): Public certificate used for message security.
@@ -83,6 +85,7 @@ await As2Partner.create({
83
85
  'enable_dedicated_ips': true,
84
86
  'http_auth_username': "username",
85
87
  'mdn_validation_level': "none",
88
+ 'signature_validation_level': "normal",
86
89
  'server_certificate': "require_match",
87
90
  'default_mime_type': "application/octet-stream",
88
91
  'additional_http_headers': {"key":"example value"},
@@ -99,7 +102,8 @@ await As2Partner.create({
99
102
  * `enable_dedicated_ips` (boolean): If `true`, we will use your site's dedicated IPs for all outbound connections to this AS2 Partner.
100
103
  * `http_auth_username` (string): Username to send to server for HTTP Authentication.
101
104
  * `http_auth_password` (string): Password to send to server for HTTP Authentication.
102
- * `mdn_validation_level` (string): How should Files.com evaluate message transfer success based on a partner's MDN response? This setting does not affect MDN storage; all MDNs received from a partner are always stored. `none`: MDN is stored for informational purposes only, a successful HTTPS transfer is a successful AS2 transfer. `weak`: Inspect the MDN for MIC and Disposition only. `normal`: `weak` plus validate MDN signature matches body, `strict`: `normal` but do not allow signatures from self-signed or incorrectly purposed certificates.
105
+ * `mdn_validation_level` (string): How should Files.com evaluate message transfer success based on a partner's MDN response? This setting does not affect MDN storage; all MDNs received from a partner are always stored. `none`: MDN is stored for informational purposes only, a successful HTTPS transfer is a successful AS2 transfer. `weak`: Inspect the MDN for MIC and Disposition only. `normal`: `weak` plus validate MDN signature matches body, `strict`: `normal` but do not allow signatures from self-signed or incorrectly purposed certificates. `auto`: Automatically set the correct value for this setting based on next mdn received.
106
+ * `signature_validation_level` (string): Should Files.com require signatures on incoming AS2 messages? `normal`: require that incoming messages are signed with a valid matching signature. `none`: Unsigned incoming messages are allowed. `auto`: Automatically set the correct value for this setting based on next message received.
103
107
  * `server_certificate` (string): Should we require that the remote HTTP server have a valid SSL Certificate for HTTPS? (This only applies to Outgoing AS2 message from Files.com to a Partner.)
104
108
  * `default_mime_type` (string): Default mime type of the file attached to the encrypted message
105
109
  * `additional_http_headers` (object): Additional HTTP Headers for outgoing message sent to this partner.
@@ -119,6 +123,7 @@ await as2_partner.update({
119
123
  'enable_dedicated_ips': true,
120
124
  'http_auth_username': "username",
121
125
  'mdn_validation_level': "none",
126
+ 'signature_validation_level': "normal",
122
127
  'server_certificate': "require_match",
123
128
  'default_mime_type': "application/octet-stream",
124
129
  'additional_http_headers': {"key":"example value"},
@@ -134,7 +139,8 @@ await as2_partner.update({
134
139
  * `enable_dedicated_ips` (boolean): If `true`, we will use your site's dedicated IPs for all outbound connections to this AS2 Partner.
135
140
  * `http_auth_username` (string): Username to send to server for HTTP Authentication.
136
141
  * `http_auth_password` (string): Password to send to server for HTTP Authentication.
137
- * `mdn_validation_level` (string): How should Files.com evaluate message transfer success based on a partner's MDN response? This setting does not affect MDN storage; all MDNs received from a partner are always stored. `none`: MDN is stored for informational purposes only, a successful HTTPS transfer is a successful AS2 transfer. `weak`: Inspect the MDN for MIC and Disposition only. `normal`: `weak` plus validate MDN signature matches body, `strict`: `normal` but do not allow signatures from self-signed or incorrectly purposed certificates.
142
+ * `mdn_validation_level` (string): How should Files.com evaluate message transfer success based on a partner's MDN response? This setting does not affect MDN storage; all MDNs received from a partner are always stored. `none`: MDN is stored for informational purposes only, a successful HTTPS transfer is a successful AS2 transfer. `weak`: Inspect the MDN for MIC and Disposition only. `normal`: `weak` plus validate MDN signature matches body, `strict`: `normal` but do not allow signatures from self-signed or incorrectly purposed certificates. `auto`: Automatically set the correct value for this setting based on next mdn received.
143
+ * `signature_validation_level` (string): Should Files.com require signatures on incoming AS2 messages? `normal`: require that incoming messages are signed with a valid matching signature. `none`: Unsigned incoming messages are allowed. `auto`: Automatically set the correct value for this setting based on next message received.
138
144
  * `server_certificate` (string): Should we require that the remote HTTP server have a valid SSL Certificate for HTTPS? (This only applies to Outgoing AS2 message from Files.com to a Partner.)
139
145
  * `default_mime_type` (string): Default mime type of the file attached to the encrypted message
140
146
  * `additional_http_headers` (object): Additional HTTP Headers for outgoing message sent to this partner.
@@ -157,6 +163,7 @@ await as2_partner.update({
157
163
  },
158
164
  "default_mime_type": "application/octet-stream",
159
165
  "mdn_validation_level": "none",
166
+ "signature_validation_level": "normal",
160
167
  "enable_dedicated_ips": true,
161
168
  "hex_public_certificate_serial": "A5:EB:C1:95:DC:D8:2B:E7",
162
169
  "public_certificate": "example",
@@ -17,7 +17,6 @@
17
17
  "keep_after_copy": true,
18
18
  "delete_empty_folders": true,
19
19
  "disabled": true,
20
- "interval": "week",
21
20
  "trigger": "example",
22
21
  "trigger_file": "example",
23
22
  "include_patterns": [
@@ -29,6 +28,7 @@
29
28
  "created_at": "2000-01-01T01:00:00Z",
30
29
  "updated_at": "2000-01-01T01:00:00Z",
31
30
  "sync_interval_minutes": 1,
31
+ "interval": "week",
32
32
  "recurring_day": 25,
33
33
  "schedule_days_of_week": [
34
34
  0,
@@ -56,7 +56,6 @@
56
56
  * `keep_after_copy` (boolean): Keep files after copying?
57
57
  * `delete_empty_folders` (boolean): Delete empty folders after sync?
58
58
  * `disabled` (boolean): Is this sync disabled?
59
- * `interval` (string): If trigger is `daily`, this specifies how often to run this sync. One of: `day`, `week`, `week_end`, `month`, `month_end`, `quarter`, `quarter_end`, `year`, `year_end`
60
59
  * `trigger` (string): Trigger type: daily, custom_schedule, or manual
61
60
  * `trigger_file` (string): Some MFT services request an empty file (known as a trigger file) to signal the sync is complete and they can begin further processing. If trigger_file is set, a zero-byte file will be sent at the end of the sync.
62
61
  * `include_patterns` (array(string)): Array of glob patterns to include
@@ -64,6 +63,7 @@
64
63
  * `created_at` (date-time): When this sync was created
65
64
  * `updated_at` (date-time): When this sync was last updated
66
65
  * `sync_interval_minutes` (int64): Frequency in minutes between syncs. If set, this value must be greater than or equal to the `remote_sync_interval` value for the site's plan. If left blank, the plan's `remote_sync_interval` will be used. This setting is only used if `trigger` is empty.
66
+ * `interval` (string): If trigger is `daily`, this specifies how often to run this sync. One of: `day`, `week`, `week_end`, `month`, `month_end`, `quarter`, `quarter_end`, `year`, `year_end`
67
67
  * `recurring_day` (int64): If trigger type is `daily`, this specifies a day number to run in one of the supported intervals: `week`, `month`, `quarter`, `year`.
68
68
  * `schedule_days_of_week` (array(int64)): If trigger is `custom_schedule`, Custom schedule description for when the sync should be run. 0-based days of the week. 0 is Sunday, 1 is Monday, etc.
69
69
  * `schedule_times_of_day` (array(string)): If trigger is `custom_schedule`, Custom schedule description for when the sync should be run. Times of day in HH:MM format.
@@ -112,7 +112,7 @@ await Sync.create({
112
112
  'keep_after_copy': false,
113
113
  'delete_empty_folders': false,
114
114
  'disabled': false,
115
- 'interval': 1,
115
+ 'interval': "week",
116
116
  'trigger': "example",
117
117
  'trigger_file': "example",
118
118
  'recurring_day': 25,
@@ -135,7 +135,7 @@ await Sync.create({
135
135
  * `keep_after_copy` (boolean): Keep files after copying?
136
136
  * `delete_empty_folders` (boolean): Delete empty folders after sync?
137
137
  * `disabled` (boolean): Is this sync disabled?
138
- * `interval` (int64): Interval in minutes for sync (if scheduled)
138
+ * `interval` (string): If trigger is `daily`, this specifies how often to run this sync. One of: `day`, `week`, `week_end`, `month`, `month_end`, `quarter`, `quarter_end`, `year`, `year_end`
139
139
  * `trigger` (string): Trigger type: daily, custom_schedule, or manual
140
140
  * `trigger_file` (string): Some MFT services request an empty file (known as a trigger file) to signal the sync is complete and they can begin further processing. If trigger_file is set, a zero-byte file will be sent at the end of the sync.
141
141
  * `recurring_day` (int64): If trigger type is `daily`, this specifies a day number to run in one of the supported intervals: `week`, `month`, `quarter`, `year`.
@@ -170,7 +170,7 @@ await sync.update({
170
170
  'keep_after_copy': false,
171
171
  'delete_empty_folders': false,
172
172
  'disabled': false,
173
- 'interval': 1,
173
+ 'interval': "week",
174
174
  'trigger': "example",
175
175
  'trigger_file': "example",
176
176
  'recurring_day': 25,
@@ -193,7 +193,7 @@ await sync.update({
193
193
  * `keep_after_copy` (boolean): Keep files after copying?
194
194
  * `delete_empty_folders` (boolean): Delete empty folders after sync?
195
195
  * `disabled` (boolean): Is this sync disabled?
196
- * `interval` (int64): Interval in minutes for sync (if scheduled)
196
+ * `interval` (string): If trigger is `daily`, this specifies how often to run this sync. One of: `day`, `week`, `week_end`, `month`, `month_end`, `quarter`, `quarter_end`, `year`, `year_end`
197
197
  * `trigger` (string): Trigger type: daily, custom_schedule, or manual
198
198
  * `trigger_file` (string): Some MFT services request an empty file (known as a trigger file) to signal the sync is complete and they can begin further processing. If trigger_file is set, a zero-byte file will be sent at the end of the sync.
199
199
  * `recurring_day` (int64): If trigger type is `daily`, this specifies a day number to run in one of the supported intervals: `week`, `month`, `quarter`, `year`.
@@ -218,7 +218,6 @@ await sync.update({
218
218
  "keep_after_copy": true,
219
219
  "delete_empty_folders": true,
220
220
  "disabled": true,
221
- "interval": "week",
222
221
  "trigger": "example",
223
222
  "trigger_file": "example",
224
223
  "include_patterns": [
@@ -230,6 +229,7 @@ await sync.update({
230
229
  "created_at": "2000-01-01T01:00:00Z",
231
230
  "updated_at": "2000-01-01T01:00:00Z",
232
231
  "sync_interval_minutes": 1,
232
+ "interval": "week",
233
233
  "recurring_day": 25,
234
234
  "schedule_days_of_week": [
235
235
  0,
package/lib/Files.js CHANGED
@@ -12,7 +12,7 @@ var apiKey;
12
12
  var baseUrl = 'https://app.files.com';
13
13
  var sessionId = null;
14
14
  var language = null;
15
- var version = '1.2.262';
15
+ var version = '1.2.264';
16
16
  var userAgent = "Files.com JavaScript SDK v".concat(version);
17
17
  var logLevel = _Logger.LogLevel.INFO;
18
18
  var debugRequest = false;
@@ -88,13 +88,20 @@ var As2Partner = /*#__PURE__*/(0, _createClass2.default)(function As2Partner() {
88
88
  (0, _defineProperty2.default)(this, "setDefaultMimeType", function (value) {
89
89
  _this.attributes.default_mime_type = value;
90
90
  });
91
- // string # How should Files.com evaluate message transfer success based on a partner's MDN response? This setting does not affect MDN storage; all MDNs received from a partner are always stored. `none`: MDN is stored for informational purposes only, a successful HTTPS transfer is a successful AS2 transfer. `weak`: Inspect the MDN for MIC and Disposition only. `normal`: `weak` plus validate MDN signature matches body, `strict`: `normal` but do not allow signatures from self-signed or incorrectly purposed certificates.
91
+ // string # How should Files.com evaluate message transfer success based on a partner's MDN response? This setting does not affect MDN storage; all MDNs received from a partner are always stored. `none`: MDN is stored for informational purposes only, a successful HTTPS transfer is a successful AS2 transfer. `weak`: Inspect the MDN for MIC and Disposition only. `normal`: `weak` plus validate MDN signature matches body, `strict`: `normal` but do not allow signatures from self-signed or incorrectly purposed certificates. `auto`: Automatically set the correct value for this setting based on next mdn received.
92
92
  (0, _defineProperty2.default)(this, "getMdnValidationLevel", function () {
93
93
  return _this.attributes.mdn_validation_level;
94
94
  });
95
95
  (0, _defineProperty2.default)(this, "setMdnValidationLevel", function (value) {
96
96
  _this.attributes.mdn_validation_level = value;
97
97
  });
98
+ // string # Should Files.com require signatures on incoming AS2 messages? `normal`: require that incoming messages are signed with a valid matching signature. `none`: Unsigned incoming messages are allowed. `auto`: Automatically set the correct value for this setting based on next message received.
99
+ (0, _defineProperty2.default)(this, "getSignatureValidationLevel", function () {
100
+ return _this.attributes.signature_validation_level;
101
+ });
102
+ (0, _defineProperty2.default)(this, "setSignatureValidationLevel", function (value) {
103
+ _this.attributes.signature_validation_level = value;
104
+ });
98
105
  // boolean # If `true`, we will use your site's dedicated IPs for all outbound connections to this AS2 Partner.
99
106
  (0, _defineProperty2.default)(this, "getEnableDedicatedIps", function () {
100
107
  return _this.attributes.enable_dedicated_ips;
@@ -169,7 +176,8 @@ var As2Partner = /*#__PURE__*/(0, _createClass2.default)(function As2Partner() {
169
176
  // enable_dedicated_ips - boolean - If `true`, we will use your site's dedicated IPs for all outbound connections to this AS2 Partner.
170
177
  // http_auth_username - string - Username to send to server for HTTP Authentication.
171
178
  // http_auth_password - string - Password to send to server for HTTP Authentication.
172
- // mdn_validation_level - string - How should Files.com evaluate message transfer success based on a partner's MDN response? This setting does not affect MDN storage; all MDNs received from a partner are always stored. `none`: MDN is stored for informational purposes only, a successful HTTPS transfer is a successful AS2 transfer. `weak`: Inspect the MDN for MIC and Disposition only. `normal`: `weak` plus validate MDN signature matches body, `strict`: `normal` but do not allow signatures from self-signed or incorrectly purposed certificates.
179
+ // mdn_validation_level - string - How should Files.com evaluate message transfer success based on a partner's MDN response? This setting does not affect MDN storage; all MDNs received from a partner are always stored. `none`: MDN is stored for informational purposes only, a successful HTTPS transfer is a successful AS2 transfer. `weak`: Inspect the MDN for MIC and Disposition only. `normal`: `weak` plus validate MDN signature matches body, `strict`: `normal` but do not allow signatures from self-signed or incorrectly purposed certificates. `auto`: Automatically set the correct value for this setting based on next mdn received.
180
+ // signature_validation_level - string - Should Files.com require signatures on incoming AS2 messages? `normal`: require that incoming messages are signed with a valid matching signature. `none`: Unsigned incoming messages are allowed. `auto`: Automatically set the correct value for this setting based on next message received.
173
181
  // server_certificate - string - Should we require that the remote HTTP server have a valid SSL Certificate for HTTPS? (This only applies to Outgoing AS2 message from Files.com to a Partner.)
174
182
  // default_mime_type - string - Default mime type of the file attached to the encrypted message
175
183
  // additional_http_headers - object - Additional HTTP Headers for outgoing message sent to this partner.
@@ -221,56 +229,62 @@ var As2Partner = /*#__PURE__*/(0, _createClass2.default)(function As2Partner() {
221
229
  }
222
230
  throw new errors.InvalidParameterError("Bad parameter: mdn_validation_level must be of type String, received ".concat((0, _utils.getType)(params.mdn_validation_level)));
223
231
  case 6:
224
- if (!(params.server_certificate && !(0, _utils.isString)(params.server_certificate))) {
232
+ if (!(params.signature_validation_level && !(0, _utils.isString)(params.signature_validation_level))) {
225
233
  _context.next = 7;
226
234
  break;
227
235
  }
228
- throw new errors.InvalidParameterError("Bad parameter: server_certificate must be of type String, received ".concat((0, _utils.getType)(params.server_certificate)));
236
+ throw new errors.InvalidParameterError("Bad parameter: signature_validation_level must be of type String, received ".concat((0, _utils.getType)(params.signature_validation_level)));
229
237
  case 7:
230
- if (!(params.default_mime_type && !(0, _utils.isString)(params.default_mime_type))) {
238
+ if (!(params.server_certificate && !(0, _utils.isString)(params.server_certificate))) {
231
239
  _context.next = 8;
232
240
  break;
233
241
  }
234
- throw new errors.InvalidParameterError("Bad parameter: default_mime_type must be of type String, received ".concat((0, _utils.getType)(params.default_mime_type)));
242
+ throw new errors.InvalidParameterError("Bad parameter: server_certificate must be of type String, received ".concat((0, _utils.getType)(params.server_certificate)));
235
243
  case 8:
236
- if (!(params.name && !(0, _utils.isString)(params.name))) {
244
+ if (!(params.default_mime_type && !(0, _utils.isString)(params.default_mime_type))) {
237
245
  _context.next = 9;
238
246
  break;
239
247
  }
240
- throw new errors.InvalidParameterError("Bad parameter: name must be of type String, received ".concat((0, _utils.getType)(params.name)));
248
+ throw new errors.InvalidParameterError("Bad parameter: default_mime_type must be of type String, received ".concat((0, _utils.getType)(params.default_mime_type)));
241
249
  case 9:
242
- if (!(params.uri && !(0, _utils.isString)(params.uri))) {
250
+ if (!(params.name && !(0, _utils.isString)(params.name))) {
243
251
  _context.next = 10;
244
252
  break;
245
253
  }
246
- throw new errors.InvalidParameterError("Bad parameter: uri must be of type String, received ".concat((0, _utils.getType)(params.uri)));
254
+ throw new errors.InvalidParameterError("Bad parameter: name must be of type String, received ".concat((0, _utils.getType)(params.name)));
247
255
  case 10:
248
- if (!(params.public_certificate && !(0, _utils.isString)(params.public_certificate))) {
256
+ if (!(params.uri && !(0, _utils.isString)(params.uri))) {
249
257
  _context.next = 11;
250
258
  break;
251
259
  }
252
- throw new errors.InvalidParameterError("Bad parameter: public_certificate must be of type String, received ".concat((0, _utils.getType)(params.public_certificate)));
260
+ throw new errors.InvalidParameterError("Bad parameter: uri must be of type String, received ".concat((0, _utils.getType)(params.uri)));
253
261
  case 11:
262
+ if (!(params.public_certificate && !(0, _utils.isString)(params.public_certificate))) {
263
+ _context.next = 12;
264
+ break;
265
+ }
266
+ throw new errors.InvalidParameterError("Bad parameter: public_certificate must be of type String, received ".concat((0, _utils.getType)(params.public_certificate)));
267
+ case 12:
254
268
  if (params.id) {
255
- _context.next = 13;
269
+ _context.next = 14;
256
270
  break;
257
271
  }
258
272
  if (!_this.attributes.id) {
259
- _context.next = 12;
273
+ _context.next = 13;
260
274
  break;
261
275
  }
262
276
  params.id = _this.id;
263
- _context.next = 13;
277
+ _context.next = 14;
264
278
  break;
265
- case 12:
266
- throw new errors.MissingParameterError('Parameter missing: id');
267
279
  case 13:
268
- _context.next = 14;
269
- return _Api.default.sendRequest("/as2_partners/".concat(encodeURIComponent(params.id)), 'PATCH', params, _this.options);
280
+ throw new errors.MissingParameterError('Parameter missing: id');
270
281
  case 14:
282
+ _context.next = 15;
283
+ return _Api.default.sendRequest("/as2_partners/".concat(encodeURIComponent(params.id)), 'PATCH', params, _this.options);
284
+ case 15:
271
285
  response = _context.sent;
272
286
  return _context.abrupt("return", new As2Partner(response === null || response === void 0 ? void 0 : response.data, _this.options));
273
- case 15:
287
+ case 16:
274
288
  case "end":
275
289
  return _context.stop();
276
290
  }
@@ -470,7 +484,8 @@ _As2Partner = As2Partner;
470
484
  // enable_dedicated_ips - boolean - If `true`, we will use your site's dedicated IPs for all outbound connections to this AS2 Partner.
471
485
  // http_auth_username - string - Username to send to server for HTTP Authentication.
472
486
  // http_auth_password - string - Password to send to server for HTTP Authentication.
473
- // mdn_validation_level - string - How should Files.com evaluate message transfer success based on a partner's MDN response? This setting does not affect MDN storage; all MDNs received from a partner are always stored. `none`: MDN is stored for informational purposes only, a successful HTTPS transfer is a successful AS2 transfer. `weak`: Inspect the MDN for MIC and Disposition only. `normal`: `weak` plus validate MDN signature matches body, `strict`: `normal` but do not allow signatures from self-signed or incorrectly purposed certificates.
487
+ // mdn_validation_level - string - How should Files.com evaluate message transfer success based on a partner's MDN response? This setting does not affect MDN storage; all MDNs received from a partner are always stored. `none`: MDN is stored for informational purposes only, a successful HTTPS transfer is a successful AS2 transfer. `weak`: Inspect the MDN for MIC and Disposition only. `normal`: `weak` plus validate MDN signature matches body, `strict`: `normal` but do not allow signatures from self-signed or incorrectly purposed certificates. `auto`: Automatically set the correct value for this setting based on next mdn received.
488
+ // signature_validation_level - string - Should Files.com require signatures on incoming AS2 messages? `normal`: require that incoming messages are signed with a valid matching signature. `none`: Unsigned incoming messages are allowed. `auto`: Automatically set the correct value for this setting based on next message received.
474
489
  // server_certificate - string - Should we require that the remote HTTP server have a valid SSL Certificate for HTTPS? (This only applies to Outgoing AS2 message from Files.com to a Partner.)
475
490
  // default_mime_type - string - Default mime type of the file attached to the encrypted message
476
491
  // additional_http_headers - object - Additional HTTP Headers for outgoing message sent to this partner.
@@ -530,48 +545,54 @@ _As2Partner = As2Partner;
530
545
  }
531
546
  throw new errors.InvalidParameterError("Bad parameter: mdn_validation_level must be of type String, received ".concat((0, _utils.getType)(params.mdn_validation_level)));
532
547
  case 7:
533
- if (!(params.server_certificate && !(0, _utils.isString)(params.server_certificate))) {
548
+ if (!(params.signature_validation_level && !(0, _utils.isString)(params.signature_validation_level))) {
534
549
  _context6.next = 8;
535
550
  break;
536
551
  }
537
- throw new errors.InvalidParameterError("Bad parameter: server_certificate must be of type String, received ".concat((0, _utils.getType)(params.server_certificate)));
552
+ throw new errors.InvalidParameterError("Bad parameter: signature_validation_level must be of type String, received ".concat((0, _utils.getType)(params.signature_validation_level)));
538
553
  case 8:
539
- if (!(params.default_mime_type && !(0, _utils.isString)(params.default_mime_type))) {
554
+ if (!(params.server_certificate && !(0, _utils.isString)(params.server_certificate))) {
540
555
  _context6.next = 9;
541
556
  break;
542
557
  }
543
- throw new errors.InvalidParameterError("Bad parameter: default_mime_type must be of type String, received ".concat((0, _utils.getType)(params.default_mime_type)));
558
+ throw new errors.InvalidParameterError("Bad parameter: server_certificate must be of type String, received ".concat((0, _utils.getType)(params.server_certificate)));
544
559
  case 9:
545
- if (!(params.as2_station_id && !(0, _utils.isInt)(params.as2_station_id))) {
560
+ if (!(params.default_mime_type && !(0, _utils.isString)(params.default_mime_type))) {
546
561
  _context6.next = 10;
547
562
  break;
548
563
  }
549
- throw new errors.InvalidParameterError("Bad parameter: as2_station_id must be of type Int, received ".concat((0, _utils.getType)(params.as2_station_id)));
564
+ throw new errors.InvalidParameterError("Bad parameter: default_mime_type must be of type String, received ".concat((0, _utils.getType)(params.default_mime_type)));
550
565
  case 10:
551
- if (!(params.name && !(0, _utils.isString)(params.name))) {
566
+ if (!(params.as2_station_id && !(0, _utils.isInt)(params.as2_station_id))) {
552
567
  _context6.next = 11;
553
568
  break;
554
569
  }
555
- throw new errors.InvalidParameterError("Bad parameter: name must be of type String, received ".concat((0, _utils.getType)(params.name)));
570
+ throw new errors.InvalidParameterError("Bad parameter: as2_station_id must be of type Int, received ".concat((0, _utils.getType)(params.as2_station_id)));
556
571
  case 11:
557
- if (!(params.uri && !(0, _utils.isString)(params.uri))) {
572
+ if (!(params.name && !(0, _utils.isString)(params.name))) {
558
573
  _context6.next = 12;
559
574
  break;
560
575
  }
561
- throw new errors.InvalidParameterError("Bad parameter: uri must be of type String, received ".concat((0, _utils.getType)(params.uri)));
576
+ throw new errors.InvalidParameterError("Bad parameter: name must be of type String, received ".concat((0, _utils.getType)(params.name)));
562
577
  case 12:
563
- if (!(params.public_certificate && !(0, _utils.isString)(params.public_certificate))) {
578
+ if (!(params.uri && !(0, _utils.isString)(params.uri))) {
564
579
  _context6.next = 13;
565
580
  break;
566
581
  }
567
- throw new errors.InvalidParameterError("Bad parameter: public_certificate must be of type String, received ".concat((0, _utils.getType)(params.public_certificate)));
582
+ throw new errors.InvalidParameterError("Bad parameter: uri must be of type String, received ".concat((0, _utils.getType)(params.uri)));
568
583
  case 13:
569
- _context6.next = 14;
570
- return _Api.default.sendRequest('/as2_partners', 'POST', params, options);
584
+ if (!(params.public_certificate && !(0, _utils.isString)(params.public_certificate))) {
585
+ _context6.next = 14;
586
+ break;
587
+ }
588
+ throw new errors.InvalidParameterError("Bad parameter: public_certificate must be of type String, received ".concat((0, _utils.getType)(params.public_certificate)));
571
589
  case 14:
590
+ _context6.next = 15;
591
+ return _Api.default.sendRequest('/as2_partners', 'POST', params, options);
592
+ case 15:
572
593
  response = _context6.sent;
573
594
  return _context6.abrupt("return", new _As2Partner(response === null || response === void 0 ? void 0 : response.data, options));
574
- case 15:
595
+ case 16:
575
596
  case "end":
576
597
  return _context6.stop();
577
598
  }
@@ -123,13 +123,6 @@ var Sync = /*#__PURE__*/(0, _createClass2.default)(function Sync() {
123
123
  (0, _defineProperty2.default)(this, "setDisabled", function (value) {
124
124
  _this.attributes.disabled = value;
125
125
  });
126
- // string # If trigger is `daily`, this specifies how often to run this sync. One of: `day`, `week`, `week_end`, `month`, `month_end`, `quarter`, `quarter_end`, `year`, `year_end`
127
- (0, _defineProperty2.default)(this, "getInterval", function () {
128
- return _this.attributes.interval;
129
- });
130
- (0, _defineProperty2.default)(this, "setInterval", function (value) {
131
- _this.attributes.interval = value;
132
- });
133
126
  // string # Trigger type: daily, custom_schedule, or manual
134
127
  (0, _defineProperty2.default)(this, "getTrigger", function () {
135
128
  return _this.attributes.trigger;
@@ -173,6 +166,13 @@ var Sync = /*#__PURE__*/(0, _createClass2.default)(function Sync() {
173
166
  (0, _defineProperty2.default)(this, "setSyncIntervalMinutes", function (value) {
174
167
  _this.attributes.sync_interval_minutes = value;
175
168
  });
169
+ // string # If trigger is `daily`, this specifies how often to run this sync. One of: `day`, `week`, `week_end`, `month`, `month_end`, `quarter`, `quarter_end`, `year`, `year_end`
170
+ (0, _defineProperty2.default)(this, "getInterval", function () {
171
+ return _this.attributes.interval;
172
+ });
173
+ (0, _defineProperty2.default)(this, "setInterval", function (value) {
174
+ _this.attributes.interval = value;
175
+ });
176
176
  // int64 # If trigger type is `daily`, this specifies a day number to run in one of the supported intervals: `week`, `month`, `quarter`, `year`.
177
177
  (0, _defineProperty2.default)(this, "getRecurringDay", function () {
178
178
  return _this.attributes.recurring_day;
@@ -212,7 +212,7 @@ var Sync = /*#__PURE__*/(0, _createClass2.default)(function Sync() {
212
212
  // keep_after_copy - boolean - Keep files after copying?
213
213
  // delete_empty_folders - boolean - Delete empty folders after sync?
214
214
  // disabled - boolean - Is this sync disabled?
215
- // interval - int64 - Interval in minutes for sync (if scheduled)
215
+ // interval - string - If trigger is `daily`, this specifies how often to run this sync. One of: `day`, `week`, `week_end`, `month`, `month_end`, `quarter`, `quarter_end`, `year`, `year_end`
216
216
  // trigger - string - Trigger type: daily, custom_schedule, or manual
217
217
  // trigger_file - string - Some MFT services request an empty file (known as a trigger file) to signal the sync is complete and they can begin further processing. If trigger_file is set, a zero-byte file will be sent at the end of the sync.
218
218
  // recurring_day - int64 - If trigger type is `daily`, this specifies a day number to run in one of the supported intervals: `week`, `month`, `quarter`, `year`.
@@ -282,11 +282,11 @@ var Sync = /*#__PURE__*/(0, _createClass2.default)(function Sync() {
282
282
  }
283
283
  throw new errors.InvalidParameterError("Bad parameter: dest_remote_server_id must be of type Int, received ".concat((0, _utils.getType)(params.dest_remote_server_id)));
284
284
  case 9:
285
- if (!(params.interval && !(0, _utils.isInt)(params.interval))) {
285
+ if (!(params.interval && !(0, _utils.isString)(params.interval))) {
286
286
  _context.next = 10;
287
287
  break;
288
288
  }
289
- throw new errors.InvalidParameterError("Bad parameter: interval must be of type Int, received ".concat((0, _utils.getType)(params.interval)));
289
+ throw new errors.InvalidParameterError("Bad parameter: interval must be of type String, received ".concat((0, _utils.getType)(params.interval)));
290
290
  case 10:
291
291
  if (!(params.trigger && !(0, _utils.isString)(params.trigger))) {
292
292
  _context.next = 11;
@@ -550,7 +550,7 @@ _Sync = Sync;
550
550
  // keep_after_copy - boolean - Keep files after copying?
551
551
  // delete_empty_folders - boolean - Delete empty folders after sync?
552
552
  // disabled - boolean - Is this sync disabled?
553
- // interval - int64 - Interval in minutes for sync (if scheduled)
553
+ // interval - string - If trigger is `daily`, this specifies how often to run this sync. One of: `day`, `week`, `week_end`, `month`, `month_end`, `quarter`, `quarter_end`, `year`, `year_end`
554
554
  // trigger - string - Trigger type: daily, custom_schedule, or manual
555
555
  // trigger_file - string - Some MFT services request an empty file (known as a trigger file) to signal the sync is complete and they can begin further processing. If trigger_file is set, a zero-byte file will be sent at the end of the sync.
556
556
  // recurring_day - int64 - If trigger type is `daily`, this specifies a day number to run in one of the supported intervals: `week`, `month`, `quarter`, `year`.
@@ -603,11 +603,11 @@ _Sync = Sync;
603
603
  }
604
604
  throw new errors.InvalidParameterError("Bad parameter: dest_remote_server_id must be of type Int, received ".concat((0, _utils.getType)(params.dest_remote_server_id)));
605
605
  case 6:
606
- if (!(params.interval && !(0, _utils.isInt)(params.interval))) {
606
+ if (!(params.interval && !(0, _utils.isString)(params.interval))) {
607
607
  _context6.next = 7;
608
608
  break;
609
609
  }
610
- throw new errors.InvalidParameterError("Bad parameter: interval must be of type Int, received ".concat((0, _utils.getType)(params.interval)));
610
+ throw new errors.InvalidParameterError("Bad parameter: interval must be of type String, received ".concat((0, _utils.getType)(params.interval)));
611
611
  case 7:
612
612
  if (!(params.trigger && !(0, _utils.isString)(params.trigger))) {
613
613
  _context6.next = 8;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "files.com",
3
- "version": "1.2.262",
3
+ "version": "1.2.264",
4
4
  "description": "Files.com SDK for JavaScript",
5
5
  "keywords": [
6
6
  "files.com",
package/src/Files.js CHANGED
@@ -6,7 +6,7 @@ let apiKey
6
6
  let baseUrl = 'https://app.files.com'
7
7
  let sessionId = null
8
8
  let language = null
9
- const version = '1.2.262'
9
+ const version = '1.2.264'
10
10
  let userAgent = `Files.com JavaScript SDK v${version}`
11
11
 
12
12
  let logLevel = LogLevel.INFO
@@ -84,13 +84,20 @@ class As2Partner {
84
84
  this.attributes.default_mime_type = value
85
85
  }
86
86
 
87
- // string # How should Files.com evaluate message transfer success based on a partner's MDN response? This setting does not affect MDN storage; all MDNs received from a partner are always stored. `none`: MDN is stored for informational purposes only, a successful HTTPS transfer is a successful AS2 transfer. `weak`: Inspect the MDN for MIC and Disposition only. `normal`: `weak` plus validate MDN signature matches body, `strict`: `normal` but do not allow signatures from self-signed or incorrectly purposed certificates.
87
+ // string # How should Files.com evaluate message transfer success based on a partner's MDN response? This setting does not affect MDN storage; all MDNs received from a partner are always stored. `none`: MDN is stored for informational purposes only, a successful HTTPS transfer is a successful AS2 transfer. `weak`: Inspect the MDN for MIC and Disposition only. `normal`: `weak` plus validate MDN signature matches body, `strict`: `normal` but do not allow signatures from self-signed or incorrectly purposed certificates. `auto`: Automatically set the correct value for this setting based on next mdn received.
88
88
  getMdnValidationLevel = () => this.attributes.mdn_validation_level
89
89
 
90
90
  setMdnValidationLevel = value => {
91
91
  this.attributes.mdn_validation_level = value
92
92
  }
93
93
 
94
+ // string # Should Files.com require signatures on incoming AS2 messages? `normal`: require that incoming messages are signed with a valid matching signature. `none`: Unsigned incoming messages are allowed. `auto`: Automatically set the correct value for this setting based on next message received.
95
+ getSignatureValidationLevel = () => this.attributes.signature_validation_level
96
+
97
+ setSignatureValidationLevel = value => {
98
+ this.attributes.signature_validation_level = value
99
+ }
100
+
94
101
  // boolean # If `true`, we will use your site's dedicated IPs for all outbound connections to this AS2 Partner.
95
102
  getEnableDedicatedIps = () => this.attributes.enable_dedicated_ips
96
103
 
@@ -165,7 +172,8 @@ class As2Partner {
165
172
  // enable_dedicated_ips - boolean - If `true`, we will use your site's dedicated IPs for all outbound connections to this AS2 Partner.
166
173
  // http_auth_username - string - Username to send to server for HTTP Authentication.
167
174
  // http_auth_password - string - Password to send to server for HTTP Authentication.
168
- // mdn_validation_level - string - How should Files.com evaluate message transfer success based on a partner's MDN response? This setting does not affect MDN storage; all MDNs received from a partner are always stored. `none`: MDN is stored for informational purposes only, a successful HTTPS transfer is a successful AS2 transfer. `weak`: Inspect the MDN for MIC and Disposition only. `normal`: `weak` plus validate MDN signature matches body, `strict`: `normal` but do not allow signatures from self-signed or incorrectly purposed certificates.
175
+ // mdn_validation_level - string - How should Files.com evaluate message transfer success based on a partner's MDN response? This setting does not affect MDN storage; all MDNs received from a partner are always stored. `none`: MDN is stored for informational purposes only, a successful HTTPS transfer is a successful AS2 transfer. `weak`: Inspect the MDN for MIC and Disposition only. `normal`: `weak` plus validate MDN signature matches body, `strict`: `normal` but do not allow signatures from self-signed or incorrectly purposed certificates. `auto`: Automatically set the correct value for this setting based on next mdn received.
176
+ // signature_validation_level - string - Should Files.com require signatures on incoming AS2 messages? `normal`: require that incoming messages are signed with a valid matching signature. `none`: Unsigned incoming messages are allowed. `auto`: Automatically set the correct value for this setting based on next message received.
169
177
  // server_certificate - string - Should we require that the remote HTTP server have a valid SSL Certificate for HTTPS? (This only applies to Outgoing AS2 message from Files.com to a Partner.)
170
178
  // default_mime_type - string - Default mime type of the file attached to the encrypted message
171
179
  // additional_http_headers - object - Additional HTTP Headers for outgoing message sent to this partner.
@@ -198,6 +206,10 @@ class As2Partner {
198
206
  throw new errors.InvalidParameterError(`Bad parameter: mdn_validation_level must be of type String, received ${getType(params.mdn_validation_level)}`)
199
207
  }
200
208
 
209
+ if (params.signature_validation_level && !isString(params.signature_validation_level)) {
210
+ throw new errors.InvalidParameterError(`Bad parameter: signature_validation_level must be of type String, received ${getType(params.signature_validation_level)}`)
211
+ }
212
+
201
213
  if (params.server_certificate && !isString(params.server_certificate)) {
202
214
  throw new errors.InvalidParameterError(`Bad parameter: server_certificate must be of type String, received ${getType(params.server_certificate)}`)
203
215
  }
@@ -320,7 +332,8 @@ class As2Partner {
320
332
  // enable_dedicated_ips - boolean - If `true`, we will use your site's dedicated IPs for all outbound connections to this AS2 Partner.
321
333
  // http_auth_username - string - Username to send to server for HTTP Authentication.
322
334
  // http_auth_password - string - Password to send to server for HTTP Authentication.
323
- // mdn_validation_level - string - How should Files.com evaluate message transfer success based on a partner's MDN response? This setting does not affect MDN storage; all MDNs received from a partner are always stored. `none`: MDN is stored for informational purposes only, a successful HTTPS transfer is a successful AS2 transfer. `weak`: Inspect the MDN for MIC and Disposition only. `normal`: `weak` plus validate MDN signature matches body, `strict`: `normal` but do not allow signatures from self-signed or incorrectly purposed certificates.
335
+ // mdn_validation_level - string - How should Files.com evaluate message transfer success based on a partner's MDN response? This setting does not affect MDN storage; all MDNs received from a partner are always stored. `none`: MDN is stored for informational purposes only, a successful HTTPS transfer is a successful AS2 transfer. `weak`: Inspect the MDN for MIC and Disposition only. `normal`: `weak` plus validate MDN signature matches body, `strict`: `normal` but do not allow signatures from self-signed or incorrectly purposed certificates. `auto`: Automatically set the correct value for this setting based on next mdn received.
336
+ // signature_validation_level - string - Should Files.com require signatures on incoming AS2 messages? `normal`: require that incoming messages are signed with a valid matching signature. `none`: Unsigned incoming messages are allowed. `auto`: Automatically set the correct value for this setting based on next message received.
324
337
  // server_certificate - string - Should we require that the remote HTTP server have a valid SSL Certificate for HTTPS? (This only applies to Outgoing AS2 message from Files.com to a Partner.)
325
338
  // default_mime_type - string - Default mime type of the file attached to the encrypted message
326
339
  // additional_http_headers - object - Additional HTTP Headers for outgoing message sent to this partner.
@@ -357,6 +370,10 @@ class As2Partner {
357
370
  throw new errors.InvalidParameterError(`Bad parameter: mdn_validation_level must be of type String, received ${getType(params.mdn_validation_level)}`)
358
371
  }
359
372
 
373
+ if (params.signature_validation_level && !isString(params.signature_validation_level)) {
374
+ throw new errors.InvalidParameterError(`Bad parameter: signature_validation_level must be of type String, received ${getType(params.signature_validation_level)}`)
375
+ }
376
+
360
377
  if (params.server_certificate && !isString(params.server_certificate)) {
361
378
  throw new errors.InvalidParameterError(`Bad parameter: server_certificate must be of type String, received ${getType(params.server_certificate)}`)
362
379
  }
@@ -119,13 +119,6 @@ class Sync {
119
119
  this.attributes.disabled = value
120
120
  }
121
121
 
122
- // string # If trigger is `daily`, this specifies how often to run this sync. One of: `day`, `week`, `week_end`, `month`, `month_end`, `quarter`, `quarter_end`, `year`, `year_end`
123
- getInterval = () => this.attributes.interval
124
-
125
- setInterval = value => {
126
- this.attributes.interval = value
127
- }
128
-
129
122
  // string # Trigger type: daily, custom_schedule, or manual
130
123
  getTrigger = () => this.attributes.trigger
131
124
 
@@ -167,6 +160,13 @@ class Sync {
167
160
  this.attributes.sync_interval_minutes = value
168
161
  }
169
162
 
163
+ // string # If trigger is `daily`, this specifies how often to run this sync. One of: `day`, `week`, `week_end`, `month`, `month_end`, `quarter`, `quarter_end`, `year`, `year_end`
164
+ getInterval = () => this.attributes.interval
165
+
166
+ setInterval = value => {
167
+ this.attributes.interval = value
168
+ }
169
+
170
170
  // int64 # If trigger type is `daily`, this specifies a day number to run in one of the supported intervals: `week`, `month`, `quarter`, `year`.
171
171
  getRecurringDay = () => this.attributes.recurring_day
172
172
 
@@ -206,7 +206,7 @@ class Sync {
206
206
  // keep_after_copy - boolean - Keep files after copying?
207
207
  // delete_empty_folders - boolean - Delete empty folders after sync?
208
208
  // disabled - boolean - Is this sync disabled?
209
- // interval - int64 - Interval in minutes for sync (if scheduled)
209
+ // interval - string - If trigger is `daily`, this specifies how often to run this sync. One of: `day`, `week`, `week_end`, `month`, `month_end`, `quarter`, `quarter_end`, `year`, `year_end`
210
210
  // trigger - string - Trigger type: daily, custom_schedule, or manual
211
211
  // trigger_file - string - Some MFT services request an empty file (known as a trigger file) to signal the sync is complete and they can begin further processing. If trigger_file is set, a zero-byte file will be sent at the end of the sync.
212
212
  // recurring_day - int64 - If trigger type is `daily`, this specifies a day number to run in one of the supported intervals: `week`, `month`, `quarter`, `year`.
@@ -251,8 +251,8 @@ class Sync {
251
251
  throw new errors.InvalidParameterError(`Bad parameter: dest_remote_server_id must be of type Int, received ${getType(params.dest_remote_server_id)}`)
252
252
  }
253
253
 
254
- if (params.interval && !isInt(params.interval)) {
255
- throw new errors.InvalidParameterError(`Bad parameter: interval must be of type Int, received ${getType(params.interval)}`)
254
+ if (params.interval && !isString(params.interval)) {
255
+ throw new errors.InvalidParameterError(`Bad parameter: interval must be of type String, received ${getType(params.interval)}`)
256
256
  }
257
257
 
258
258
  if (params.trigger && !isString(params.trigger)) {
@@ -388,7 +388,7 @@ class Sync {
388
388
  // keep_after_copy - boolean - Keep files after copying?
389
389
  // delete_empty_folders - boolean - Delete empty folders after sync?
390
390
  // disabled - boolean - Is this sync disabled?
391
- // interval - int64 - Interval in minutes for sync (if scheduled)
391
+ // interval - string - If trigger is `daily`, this specifies how often to run this sync. One of: `day`, `week`, `week_end`, `month`, `month_end`, `quarter`, `quarter_end`, `year`, `year_end`
392
392
  // trigger - string - Trigger type: daily, custom_schedule, or manual
393
393
  // trigger_file - string - Some MFT services request an empty file (known as a trigger file) to signal the sync is complete and they can begin further processing. If trigger_file is set, a zero-byte file will be sent at the end of the sync.
394
394
  // recurring_day - int64 - If trigger type is `daily`, this specifies a day number to run in one of the supported intervals: `week`, `month`, `quarter`, `year`.
@@ -420,8 +420,8 @@ class Sync {
420
420
  throw new errors.InvalidParameterError(`Bad parameter: dest_remote_server_id must be of type Int, received ${getType(params.dest_remote_server_id)}`)
421
421
  }
422
422
 
423
- if (params.interval && !isInt(params.interval)) {
424
- throw new errors.InvalidParameterError(`Bad parameter: interval must be of type Int, received ${getType(params.interval)}`)
423
+ if (params.interval && !isString(params.interval)) {
424
+ throw new errors.InvalidParameterError(`Bad parameter: interval must be of type String, received ${getType(params.interval)}`)
425
425
  }
426
426
 
427
427
  if (params.trigger && !isString(params.trigger)) {