docspring 4.2.0 → 4.4.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.
Files changed (197) hide show
  1. package/AGENTS.md +2 -2
  2. package/README.md +26 -6
  3. package/dist/ApiClient.js +3 -3
  4. package/dist/RequestSchemas.js +1171 -134
  5. package/dist/RequestValidator.js +4 -0
  6. package/dist/api/Client.js +1406 -248
  7. package/dist/index.js +196 -0
  8. package/dist/model/AddTemplateFieldsRequest.js +4 -4
  9. package/dist/model/AiFieldNamingLanguage.js +1 -1
  10. package/dist/model/AuthenticationCheck.js +2 -2
  11. package/dist/model/BarcodeSymbology.js +1 -1
  12. package/dist/model/CheckCharacter.js +1 -1
  13. package/dist/model/CombinedFieldType.js +1 -1
  14. package/dist/model/CombinedPdf.js +2 -2
  15. package/dist/model/CombinedPdfFiles.js +2 -2
  16. package/dist/model/CombinedPdfList.js +2 -2
  17. package/dist/model/CombinedPdfSource.js +3 -3
  18. package/dist/model/CombinedPdfSourceInput.js +3 -3
  19. package/dist/model/CombinedPdfSourcePdf.js +2 -2
  20. package/dist/model/CombinedPdfSourceType.js +1 -1
  21. package/dist/model/CombinedPdfState.js +1 -1
  22. package/dist/model/CopyTemplateRequest.js +2 -2
  23. package/dist/model/CreateAccountEmailActionRequest.js +306 -0
  24. package/dist/model/CreateCombinedPdfRequest.js +2 -2
  25. package/dist/model/CreateCustomFileFromUploadRequest.js +2 -2
  26. package/dist/model/CreateEmailActionRequest.js +280 -0
  27. package/dist/model/CreateEmailDomainRequest.js +114 -0
  28. package/dist/model/CreateFolderRequest.js +2 -2
  29. package/dist/model/CreateSignatureRequestEventRequest.js +2 -2
  30. package/dist/model/CreateSignatureRequestTokenRequest.js +2 -2
  31. package/dist/model/CreateSubmissionBatchRequest.js +5 -5
  32. package/dist/model/CreateSubmissionRequest.js +115 -7
  33. package/dist/model/CreateTemplatePreviewRequest.js +2 -2
  34. package/dist/model/CreateTemplateRequest.js +119 -14
  35. package/dist/model/CreateWebhookRequest.js +2 -2
  36. package/dist/model/CustomFile.js +2 -2
  37. package/dist/model/CustomFileList.js +2 -2
  38. package/dist/model/CustomFileSourcePdf.js +2 -2
  39. package/dist/model/DnsRecordType.js +64 -0
  40. package/dist/model/EmailAction.js +510 -0
  41. package/dist/model/EmailActionConditions.js +142 -0
  42. package/dist/model/EmailActionConditionsInput.js +142 -0
  43. package/dist/model/EmailActionCustomization.js +222 -0
  44. package/dist/model/EmailActionDelivery.js +59 -0
  45. package/dist/model/EmailActionFileFormats.js +69 -0
  46. package/dist/model/EmailActionList.js +132 -0
  47. package/dist/model/EmailActionSetting.js +119 -0
  48. package/dist/model/EmailActionSubmissionType.js +64 -0
  49. package/dist/model/EmailActionTestEmail.js +116 -0
  50. package/dist/model/EmailDomain.js +245 -0
  51. package/dist/model/EmailDomainDnsRecord.js +155 -0
  52. package/dist/model/EmailDomainDnsRecordPurpose.js +64 -0
  53. package/dist/model/EmailDomainList.js +132 -0
  54. package/dist/model/EmailDomainRecordState.js +64 -0
  55. package/dist/model/EmailDomainState.js +64 -0
  56. package/dist/model/ErrorCode.js +11 -1
  57. package/dist/model/ErrorDetail.js +2 -2
  58. package/dist/model/ErrorInfo.js +47 -8
  59. package/dist/model/ErrorResponse.js +2 -2
  60. package/dist/model/ExpirationInterval.js +1 -1
  61. package/dist/model/Field.js +5 -5
  62. package/dist/model/FieldComparisonCondition.js +2 -2
  63. package/dist/model/FieldComparisonOperator.js +1 -1
  64. package/dist/model/FieldDependency.js +2 -2
  65. package/dist/model/FieldDependencyInput.js +2 -2
  66. package/dist/model/FieldDisplayType.js +1 -1
  67. package/dist/model/FieldEqualsCondition.js +2 -2
  68. package/dist/model/FieldEqualsOperator.js +1 -1
  69. package/dist/model/FieldGroup.js +6 -6
  70. package/dist/model/FieldGroupInput.js +3 -3
  71. package/dist/model/FieldGroupType.js +1 -1
  72. package/dist/model/FieldInCondition.js +2 -2
  73. package/dist/model/FieldInput.js +4 -4
  74. package/dist/model/FieldOverride.js +2 -2
  75. package/dist/model/FieldPresenceCondition.js +2 -2
  76. package/dist/model/FieldPresenceOperator.js +1 -1
  77. package/dist/model/FieldRangeCondition.js +2 -2
  78. package/dist/model/FieldReimportState.js +1 -1
  79. package/dist/model/FieldSetupLogic.js +1 -1
  80. package/dist/model/FieldSetupNaming.js +1 -1
  81. package/dist/model/FieldSetupSource.js +1 -1
  82. package/dist/model/FieldType.js +1 -1
  83. package/dist/model/Folder.js +2 -2
  84. package/dist/model/FolderList.js +2 -2
  85. package/dist/model/GenerateFilesFormat.js +16 -1
  86. package/dist/model/GenerateSubmissionFilesRequest.js +4 -4
  87. package/dist/model/GeneratedFile.js +7 -7
  88. package/dist/model/GeneratedFileState.js +1 -1
  89. package/dist/model/HtmlEngineOptions.js +4 -4
  90. package/dist/model/HtmlEngineOptionsInput.js +3 -3
  91. package/dist/model/ImageGravity.js +1 -1
  92. package/dist/model/ImageScaleType.js +1 -1
  93. package/dist/model/ModelCodeLanguage.js +7 -2
  94. package/dist/model/MoveFolderRequest.js +2 -2
  95. package/dist/model/MoveTemplateRequest.js +2 -2
  96. package/dist/model/NumberConditionType.js +1 -1
  97. package/dist/model/OutputFormat.js +11 -1
  98. package/dist/model/PageFormat.js +1 -1
  99. package/dist/model/PageImage.js +2 -2
  100. package/dist/model/PageImages.js +2 -2
  101. package/dist/model/PredefinedField.js +2 -2
  102. package/dist/model/PredefinedFieldInput.js +2 -2
  103. package/dist/model/PublishTemplateVersionRequest.js +2 -2
  104. package/dist/model/RemoveTemplateFieldsRequest.js +2 -2
  105. package/dist/model/RenameFolderRequest.js +2 -2
  106. package/dist/model/ReorderTemplateFieldsRequest.js +2 -2
  107. package/dist/model/RestoreTemplateVersionRequest.js +2 -2
  108. package/dist/model/SendAccountEmailActionTestEmailRequest.js +91 -0
  109. package/dist/model/ShapeType.js +1 -1
  110. package/dist/model/SignatureRequest.js +53 -8
  111. package/dist/model/SignatureRequestAuthSecondFactorType.js +1 -1
  112. package/dist/model/SignatureRequestAuthType.js +1 -1
  113. package/dist/model/SignatureRequestEmailAttachments.js +59 -0
  114. package/dist/model/SignatureRequestEmailStatus.js +89 -0
  115. package/dist/model/SignatureRequestEvent.js +2 -2
  116. package/dist/model/SignatureRequestEventType.js +12 -2
  117. package/dist/model/SignatureRequestInput.js +25 -9
  118. package/dist/model/SignatureRequestMessageType.js +1 -1
  119. package/dist/model/SignatureRequestReminders.js +121 -0
  120. package/dist/model/SignatureRequestState.js +1 -1
  121. package/dist/model/SignatureRequestToken.js +2 -2
  122. package/dist/model/SignatureRequestTokenType.js +1 -1
  123. package/dist/model/SigningOrder.js +59 -0
  124. package/dist/model/StringConditionType.js +37 -2
  125. package/dist/model/Submission.js +31 -19
  126. package/dist/model/SubmissionAction.js +28 -13
  127. package/dist/model/SubmissionActionState.js +1 -1
  128. package/dist/model/SubmissionActionType.js +1 -1
  129. package/dist/model/SubmissionBatch.js +9 -9
  130. package/dist/model/SubmissionBatchState.js +1 -1
  131. package/dist/model/SubmissionFiles.js +20 -2
  132. package/dist/model/SubmissionInput.js +7 -7
  133. package/dist/model/SubmissionList.js +2 -2
  134. package/dist/model/SubmissionSource.js +1 -1
  135. package/dist/model/SubmissionSourcePdf.js +2 -2
  136. package/dist/model/SubmissionState.js +1 -1
  137. package/dist/model/SubmissionSummary.js +8 -8
  138. package/dist/model/SubmissionValidation.js +2 -2
  139. package/dist/model/Template.js +149 -26
  140. package/dist/model/TemplateActor.js +2 -2
  141. package/dist/model/TemplateActorType.js +1 -1
  142. package/dist/model/TemplateDefaults.js +2 -2
  143. package/dist/model/TemplateDefaultsInput.js +2 -2
  144. package/dist/model/TemplateDiff.js +6 -6
  145. package/dist/model/TemplateDiffSummary.js +2 -2
  146. package/dist/model/TemplateDocument.js +23 -23
  147. package/dist/model/TemplateDocumentState.js +12 -2
  148. package/dist/model/TemplateDocumentSummary.js +11 -11
  149. package/dist/model/TemplateFieldChange.js +2 -2
  150. package/dist/model/TemplateFieldChanges.js +2 -2
  151. package/dist/model/TemplateFieldDependency.js +2 -2
  152. package/dist/model/TemplateFieldDependencyAction.js +1 -1
  153. package/dist/model/TemplateFieldDependencyCondition.js +2 -2
  154. package/dist/model/TemplateFieldDependencyConditionInput.js +2 -2
  155. package/dist/model/TemplateFieldDependencyInput.js +2 -2
  156. package/dist/model/TemplateFieldDependencyMatch.js +1 -1
  157. package/dist/model/TemplateFieldDependencyOperator.js +1 -1
  158. package/dist/model/TemplateFieldLogicStatus.js +1 -1
  159. package/dist/model/TemplateFieldMove.js +2 -2
  160. package/dist/model/TemplateFields.js +2 -2
  161. package/dist/model/TemplateFormMode.js +1 -1
  162. package/dist/model/TemplateModelCode.js +2 -2
  163. package/dist/model/TemplatePageAiError.js +1 -1
  164. package/dist/model/TemplatePageAiNamingStatus.js +1 -1
  165. package/dist/model/TemplatePageFieldsStatus.js +1 -1
  166. package/dist/model/TemplatePageImageStatus.js +1 -1
  167. package/dist/model/TemplatePageImages.js +2 -2
  168. package/dist/model/TemplatePageProcessingStatus.js +2 -2
  169. package/dist/model/TemplatePreview.js +5 -5
  170. package/dist/model/TemplatePreviewState.js +1 -1
  171. package/dist/model/TemplateSourcePdf.js +3 -3
  172. package/dist/model/TemplateSummary.js +24 -12
  173. package/dist/model/TemplateSummaryList.js +2 -2
  174. package/dist/model/TemplateType.js +12 -2
  175. package/dist/model/TemplateVersion.js +2 -2
  176. package/dist/model/TemplateVersionType.js +1 -1
  177. package/dist/model/TextAlignment.js +1 -1
  178. package/dist/model/TextOverflow.js +1 -1
  179. package/dist/model/TextVerticalAlignment.js +1 -1
  180. package/dist/model/Typeface.js +1 -1
  181. package/dist/model/UpdateAccountEmailActionRequest.js +306 -0
  182. package/dist/model/UpdateEmailActionCustomizationRequest.js +258 -0
  183. package/dist/model/UpdateEmailActionRequest.js +280 -0
  184. package/dist/model/UpdateSignatureRequestRequest.js +2 -2
  185. package/dist/model/UpdateTemplateDocumentRequest.js +8 -8
  186. package/dist/model/UpdateTemplateFieldsRequest.js +2 -2
  187. package/dist/model/UpdateTemplateRequest.js +113 -8
  188. package/dist/model/UpdateWebhookRequest.js +2 -2
  189. package/dist/model/UploadMethod.js +1 -1
  190. package/dist/model/UploadPresign.js +2 -2
  191. package/dist/model/UrlSourcePdf.js +2 -2
  192. package/dist/model/ValidateSubmissionRequest.js +115 -7
  193. package/dist/model/Webhook.js +2 -2
  194. package/dist/model/WebhookEventType.js +11 -1
  195. package/dist/model/WebhookList.js +2 -2
  196. package/dist/model/WebhookMode.js +1 -1
  197. package/package.json +2 -2
@@ -0,0 +1,258 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports["default"] = void 0;
7
+ var _ApiClient = _interopRequireDefault(require("../ApiClient"));
8
+ var _EmailActionConditionsInput = _interopRequireDefault(require("./EmailActionConditionsInput"));
9
+ var _EmailActionDelivery = _interopRequireDefault(require("./EmailActionDelivery"));
10
+ var _EmailActionFileFormats = _interopRequireDefault(require("./EmailActionFileFormats"));
11
+ var _EmailActionSubmissionType = _interopRequireDefault(require("./EmailActionSubmissionType"));
12
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
13
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
14
+ function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
15
+ function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }
16
+ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
17
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
18
+ function _toPrimitive(t, e) { if ("object" != _typeof(t) || !t) return t; var r; if ("undefined" != typeof Symbol && void 0 !== (r = t[Symbol.toPrimitive])) { var i = r.call(t, e || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === e ? String : Number)(t); } /**
19
+ * DocSpring API
20
+ * Use DocSpring's API to fill PDF forms, generate PDFs and Word documents from HTML or Word templates, merge PDFs, and request legally binding e-signatures.
21
+ *
22
+ * The version of the OpenAPI document: v2
23
+ *
24
+ *
25
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
26
+ * https://openapi-generator.tech
27
+ * Do not edit the class manually.
28
+ *
29
+ */
30
+ /**
31
+ * The UpdateEmailActionCustomizationRequest model module.
32
+ * @module model/UpdateEmailActionCustomizationRequest
33
+ * @version 4.4.0
34
+ */
35
+ var UpdateEmailActionCustomizationRequest = /*#__PURE__*/function () {
36
+ /**
37
+ * Constructs a new <code>UpdateEmailActionCustomizationRequest</code>.
38
+ * The template's changes to the account email action, replacing any it had. Each setting you send is changed for this template, and the ones you leave out follow the account email action. `enabled: false` stops it sending for this template; left out, it sends.
39
+ * @alias module:model/UpdateEmailActionCustomizationRequest
40
+ */
41
+ function UpdateEmailActionCustomizationRequest() {
42
+ _classCallCheck(this, UpdateEmailActionCustomizationRequest);
43
+ UpdateEmailActionCustomizationRequest.initialize(this);
44
+ }
45
+
46
+ /**
47
+ * Initializes the fields of this object.
48
+ * This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
49
+ * Only for internal use.
50
+ */
51
+ return _createClass(UpdateEmailActionCustomizationRequest, null, [{
52
+ key: "initialize",
53
+ value: function initialize(obj) {}
54
+
55
+ /**
56
+ * Constructs a <code>UpdateEmailActionCustomizationRequest</code> from a plain JavaScript object, optionally creating a new instance.
57
+ * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
58
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
59
+ * @param {module:model/UpdateEmailActionCustomizationRequest} obj Optional instance to populate.
60
+ * @return {module:model/UpdateEmailActionCustomizationRequest} The populated <code>UpdateEmailActionCustomizationRequest</code> instance.
61
+ */
62
+ }, {
63
+ key: "constructFromObject",
64
+ value: function constructFromObject(data, obj) {
65
+ if (data) {
66
+ obj = obj || new UpdateEmailActionCustomizationRequest();
67
+ if (data.hasOwnProperty('enabled')) {
68
+ obj['enabled'] = _ApiClient["default"].convertToType(data['enabled'], 'Boolean');
69
+ }
70
+ if (data.hasOwnProperty('to')) {
71
+ obj['to'] = _ApiClient["default"].convertToType(data['to'], ['String']);
72
+ }
73
+ if (data.hasOwnProperty('cc')) {
74
+ obj['cc'] = _ApiClient["default"].convertToType(data['cc'], ['String']);
75
+ }
76
+ if (data.hasOwnProperty('bcc')) {
77
+ obj['bcc'] = _ApiClient["default"].convertToType(data['bcc'], ['String']);
78
+ }
79
+ if (data.hasOwnProperty('from_name')) {
80
+ obj['from_name'] = _ApiClient["default"].convertToType(data['from_name'], 'String');
81
+ }
82
+ if (data.hasOwnProperty('from_address')) {
83
+ obj['from_address'] = _ApiClient["default"].convertToType(data['from_address'], 'String');
84
+ }
85
+ if (data.hasOwnProperty('reply_to')) {
86
+ obj['reply_to'] = _ApiClient["default"].convertToType(data['reply_to'], 'String');
87
+ }
88
+ if (data.hasOwnProperty('subject')) {
89
+ obj['subject'] = _ApiClient["default"].convertToType(data['subject'], 'String');
90
+ }
91
+ if (data.hasOwnProperty('message')) {
92
+ obj['message'] = _ApiClient["default"].convertToType(data['message'], 'String');
93
+ }
94
+ if (data.hasOwnProperty('file_name')) {
95
+ obj['file_name'] = _ApiClient["default"].convertToType(data['file_name'], 'String');
96
+ }
97
+ if (data.hasOwnProperty('file_formats')) {
98
+ obj['file_formats'] = _ApiClient["default"].convertToType(data['file_formats'], _EmailActionFileFormats["default"]);
99
+ }
100
+ if (data.hasOwnProperty('delivery')) {
101
+ obj['delivery'] = _ApiClient["default"].convertToType(data['delivery'], _EmailActionDelivery["default"]);
102
+ }
103
+ if (data.hasOwnProperty('max_attachment_mb')) {
104
+ obj['max_attachment_mb'] = _ApiClient["default"].convertToType(data['max_attachment_mb'], 'Number');
105
+ }
106
+ if (data.hasOwnProperty('submission_type')) {
107
+ obj['submission_type'] = _ApiClient["default"].convertToType(data['submission_type'], _EmailActionSubmissionType["default"]);
108
+ }
109
+ if (data.hasOwnProperty('send_when')) {
110
+ obj['send_when'] = _ApiClient["default"].convertToType(data['send_when'], _EmailActionConditionsInput["default"]);
111
+ }
112
+ }
113
+ return obj;
114
+ }
115
+
116
+ /**
117
+ * Validates the JSON data with respect to <code>UpdateEmailActionCustomizationRequest</code>.
118
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
119
+ * @return {boolean} to indicate whether the JSON data is valid with respect to <code>UpdateEmailActionCustomizationRequest</code>.
120
+ */
121
+ }, {
122
+ key: "validateJSON",
123
+ value: function validateJSON(data) {
124
+ // ensure the json data is an array
125
+ if (!Array.isArray(data['to'])) {
126
+ throw new Error("Expected the field `to` to be an array in the JSON data but got " + data['to']);
127
+ }
128
+ // ensure the json data is an array
129
+ if (!Array.isArray(data['cc'])) {
130
+ throw new Error("Expected the field `cc` to be an array in the JSON data but got " + data['cc']);
131
+ }
132
+ // ensure the json data is an array
133
+ if (!Array.isArray(data['bcc'])) {
134
+ throw new Error("Expected the field `bcc` to be an array in the JSON data but got " + data['bcc']);
135
+ }
136
+ // ensure the json data is a string
137
+ if (data['from_name'] && !(typeof data['from_name'] === 'string' || data['from_name'] instanceof String)) {
138
+ throw new Error("Expected the field `from_name` to be a primitive type in the JSON string but got " + data['from_name']);
139
+ }
140
+ // ensure the json data is a string
141
+ if (data['from_address'] && !(typeof data['from_address'] === 'string' || data['from_address'] instanceof String)) {
142
+ throw new Error("Expected the field `from_address` to be a primitive type in the JSON string but got " + data['from_address']);
143
+ }
144
+ // ensure the json data is a string
145
+ if (data['reply_to'] && !(typeof data['reply_to'] === 'string' || data['reply_to'] instanceof String)) {
146
+ throw new Error("Expected the field `reply_to` to be a primitive type in the JSON string but got " + data['reply_to']);
147
+ }
148
+ // ensure the json data is a string
149
+ if (data['subject'] && !(typeof data['subject'] === 'string' || data['subject'] instanceof String)) {
150
+ throw new Error("Expected the field `subject` to be a primitive type in the JSON string but got " + data['subject']);
151
+ }
152
+ // ensure the json data is a string
153
+ if (data['message'] && !(typeof data['message'] === 'string' || data['message'] instanceof String)) {
154
+ throw new Error("Expected the field `message` to be a primitive type in the JSON string but got " + data['message']);
155
+ }
156
+ // ensure the json data is a string
157
+ if (data['file_name'] && !(typeof data['file_name'] === 'string' || data['file_name'] instanceof String)) {
158
+ throw new Error("Expected the field `file_name` to be a primitive type in the JSON string but got " + data['file_name']);
159
+ }
160
+ // validate the optional field `send_when`
161
+ if (data['send_when']) {
162
+ // data not null
163
+ _EmailActionConditionsInput["default"].validateJSON(data['send_when']);
164
+ }
165
+ return true;
166
+ }
167
+ }]);
168
+ }();
169
+ /**
170
+ * Whether it sends emails. DocSpring turns an email action off after 3 days of failed emails, or straight away when one of the addresses in `to`, `cc` or `bcc` (not one from a field or metadata) bounces or marks an email as spam.
171
+ * @member {Boolean} enabled
172
+ */
173
+ UpdateEmailActionCustomizationRequest.prototype['enabled'] = undefined;
174
+
175
+ /**
176
+ * Who gets each email: email addresses, and tags for an address that each submission gives, from one of the template's text or email fields (`{{ data.client_email }}`, or `{{ data["client email"] }}` for a name with spaces) or from its metadata (`{{ metadata.agent_email }}`, or `{{ metadata.agent.email }}` for a value in an object). A tag whose value is blank or isn't a valid address is skipped for that submission, and so is a field an account email action names that the template doesn't have. `{{ signer.email }}` sends each of the submission's signers their own email, to them alone, and everyone else in `to`, `cc` and `bcc` one email together, without the signers. An email needs at least one entry in `to`, `cc` or `bcc`, and at most 10 across them.
177
+ * @member {Array.<String>} to
178
+ */
179
+ UpdateEmailActionCustomizationRequest.prototype['to'] = undefined;
180
+
181
+ /**
182
+ * Who is copied on each email, as in `to` (but not `{{ signer.email }}`).
183
+ * @member {Array.<String>} cc
184
+ */
185
+ UpdateEmailActionCustomizationRequest.prototype['cc'] = undefined;
186
+
187
+ /**
188
+ * Who is blind-copied on each email, as in `to` (but not `{{ signer.email }}`).
189
+ * @member {Array.<String>} bcc
190
+ */
191
+ UpdateEmailActionCustomizationRequest.prototype['bcc'] = undefined;
192
+
193
+ /**
194
+ * The sender's name. Null uses your account's name. From DocSpring's shared address, the name is followed by "via DocSpring".
195
+ * @member {String} from_name
196
+ */
197
+ UpdateEmailActionCustomizationRequest.prototype['from_name'] = undefined;
198
+
199
+ /**
200
+ * The sender's address, at one of your verified email domains. Null sends from DocSpring's shared address.
201
+ * @member {String} from_address
202
+ */
203
+ UpdateEmailActionCustomizationRequest.prototype['from_address'] = undefined;
204
+
205
+ /**
206
+ * Where replies go: a team member's email address, or an address at one of your verified email domains. Null sends without a reply address.
207
+ * @member {String} reply_to
208
+ */
209
+ UpdateEmailActionCustomizationRequest.prototype['reply_to'] = undefined;
210
+
211
+ /**
212
+ * The subject line, a Liquid template with the variables `account.name`, `template.name`, `template.id`, `submission.id`, the submission's values as `data.<field name>` (`data["field name"]` for a name with spaces) and its metadata as `metadata.<key>`, such as `Your {{ template.name }}`. Null uses the template's name followed by the file it sends, such as "Lease PDF", or by "files" when it sends several.
213
+ * @member {String} subject
214
+ */
215
+ UpdateEmailActionCustomizationRequest.prototype['subject'] = undefined;
216
+
217
+ /**
218
+ * The email's text, a Liquid template with the same variables as `subject`. `if`, `unless` and `case` tags work. Line breaks are kept. Null uses a short message that says the files are attached or ready to download.
219
+ * @member {String} message
220
+ */
221
+ UpdateEmailActionCustomizationRequest.prototype['message'] = undefined;
222
+
223
+ /**
224
+ * The attached files' name, a Liquid template with the same variables as `subject`, such as `{{ data.last_name }} lease`. Each file's extension (`.pdf`, `.docx` or `.odt`) is added. Null uses the submission's `pdf_filename` metadata when it has one, and otherwise the template's name. A download link's files have the names their other downloads have: the submission's `pdf_filename`, or its ID.
225
+ * @member {String} file_name
226
+ */
227
+ UpdateEmailActionCustomizationRequest.prototype['file_name'] = undefined;
228
+
229
+ /**
230
+ * Which of the submission's files the email sends: `all` sends every file the submission made (its PDF, and a Word template's Word document and OpenDocument file when it made them), and `docx`, `odt` or `pdf` sends only that file. A submission that made none of them sends nothing, and its email shows as skipped. Only Word templates make Word documents and OpenDocument files, so another template's email action takes `pdf` or `all`.
231
+ * @member {module:model/EmailActionFileFormats} file_formats
232
+ */
233
+ UpdateEmailActionCustomizationRequest.prototype['file_formats'] = undefined;
234
+
235
+ /**
236
+ * `attachment` attaches the files, or sends a download link when together they're larger than `max_attachment_mb`. `link` sends a download link, which works for 7 days. Accounts with a BAA start with `link`.
237
+ * @member {module:model/EmailActionDelivery} delivery
238
+ */
239
+ UpdateEmailActionCustomizationRequest.prototype['delivery'] = undefined;
240
+
241
+ /**
242
+ * With `delivery` `attachment`, files larger than this many megabytes in all (1 MB is 1,000,000 bytes) are sent as a download link instead. Emailing a file makes it about 38% larger, and many company mail servers refuse emails over 10 MB, so the default is 7. Raise it only when every recipient's mail server accepts larger emails, such as Microsoft 365 (up to 36 MB) or Gmail (50 MB).
243
+ * @member {Number} max_attachment_mb
244
+ */
245
+ UpdateEmailActionCustomizationRequest.prototype['max_attachment_mb'] = undefined;
246
+
247
+ /**
248
+ * Which submissions send emails: `live`, `test` or `all`. Test submissions only email your team's members, and skip every other recipient.
249
+ * @member {module:model/EmailActionSubmissionType} submission_type
250
+ */
251
+ UpdateEmailActionCustomizationRequest.prototype['submission_type'] = undefined;
252
+
253
+ /**
254
+ * Sends the email only when the submission's values meet these conditions, which work as a conditional logic rule's do. The values are the ones the PDF has: formulas worked out, and blank for a field that a rule hides. A field the template doesn't have (in an account email action's conditions) counts as blank. A submission that doesn't meet them sends nothing, and its email shows as skipped. Null sends for every submission.
255
+ * @member {module:model/EmailActionConditionsInput} send_when
256
+ */
257
+ UpdateEmailActionCustomizationRequest.prototype['send_when'] = undefined;
258
+ var _default = exports["default"] = UpdateEmailActionCustomizationRequest;
@@ -0,0 +1,280 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports["default"] = void 0;
7
+ var _ApiClient = _interopRequireDefault(require("../ApiClient"));
8
+ var _EmailActionConditionsInput = _interopRequireDefault(require("./EmailActionConditionsInput"));
9
+ var _EmailActionDelivery = _interopRequireDefault(require("./EmailActionDelivery"));
10
+ var _EmailActionFileFormats = _interopRequireDefault(require("./EmailActionFileFormats"));
11
+ var _EmailActionSubmissionType = _interopRequireDefault(require("./EmailActionSubmissionType"));
12
+ function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
13
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
14
+ function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
15
+ function _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }
16
+ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
17
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
18
+ function _toPrimitive(t, e) { if ("object" != _typeof(t) || !t) return t; var r; if ("undefined" != typeof Symbol && void 0 !== (r = t[Symbol.toPrimitive])) { var i = r.call(t, e || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === e ? String : Number)(t); } /**
19
+ * DocSpring API
20
+ * Use DocSpring's API to fill PDF forms, generate PDFs and Word documents from HTML or Word templates, merge PDFs, and request legally binding e-signatures.
21
+ *
22
+ * The version of the OpenAPI document: v2
23
+ *
24
+ *
25
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
26
+ * https://openapi-generator.tech
27
+ * Do not edit the class manually.
28
+ *
29
+ */
30
+ /**
31
+ * The UpdateEmailActionRequest model module.
32
+ * @module model/UpdateEmailActionRequest
33
+ * @version 4.4.0
34
+ */
35
+ var UpdateEmailActionRequest = /*#__PURE__*/function () {
36
+ /**
37
+ * Constructs a new <code>UpdateEmailActionRequest</code>.
38
+ * The settings to change. Properties left out keep their values.
39
+ * @alias module:model/UpdateEmailActionRequest
40
+ */
41
+ function UpdateEmailActionRequest() {
42
+ _classCallCheck(this, UpdateEmailActionRequest);
43
+ UpdateEmailActionRequest.initialize(this);
44
+ }
45
+
46
+ /**
47
+ * Initializes the fields of this object.
48
+ * This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
49
+ * Only for internal use.
50
+ */
51
+ return _createClass(UpdateEmailActionRequest, null, [{
52
+ key: "initialize",
53
+ value: function initialize(obj) {}
54
+
55
+ /**
56
+ * Constructs a <code>UpdateEmailActionRequest</code> from a plain JavaScript object, optionally creating a new instance.
57
+ * Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
58
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
59
+ * @param {module:model/UpdateEmailActionRequest} obj Optional instance to populate.
60
+ * @return {module:model/UpdateEmailActionRequest} The populated <code>UpdateEmailActionRequest</code> instance.
61
+ */
62
+ }, {
63
+ key: "constructFromObject",
64
+ value: function constructFromObject(data, obj) {
65
+ if (data) {
66
+ obj = obj || new UpdateEmailActionRequest();
67
+ if (data.hasOwnProperty('name')) {
68
+ obj['name'] = _ApiClient["default"].convertToType(data['name'], 'String');
69
+ }
70
+ if (data.hasOwnProperty('enabled')) {
71
+ obj['enabled'] = _ApiClient["default"].convertToType(data['enabled'], 'Boolean');
72
+ }
73
+ if (data.hasOwnProperty('to')) {
74
+ obj['to'] = _ApiClient["default"].convertToType(data['to'], ['String']);
75
+ }
76
+ if (data.hasOwnProperty('cc')) {
77
+ obj['cc'] = _ApiClient["default"].convertToType(data['cc'], ['String']);
78
+ }
79
+ if (data.hasOwnProperty('bcc')) {
80
+ obj['bcc'] = _ApiClient["default"].convertToType(data['bcc'], ['String']);
81
+ }
82
+ if (data.hasOwnProperty('from_name')) {
83
+ obj['from_name'] = _ApiClient["default"].convertToType(data['from_name'], 'String');
84
+ }
85
+ if (data.hasOwnProperty('from_address')) {
86
+ obj['from_address'] = _ApiClient["default"].convertToType(data['from_address'], 'String');
87
+ }
88
+ if (data.hasOwnProperty('reply_to')) {
89
+ obj['reply_to'] = _ApiClient["default"].convertToType(data['reply_to'], 'String');
90
+ }
91
+ if (data.hasOwnProperty('subject')) {
92
+ obj['subject'] = _ApiClient["default"].convertToType(data['subject'], 'String');
93
+ }
94
+ if (data.hasOwnProperty('message')) {
95
+ obj['message'] = _ApiClient["default"].convertToType(data['message'], 'String');
96
+ }
97
+ if (data.hasOwnProperty('file_name')) {
98
+ obj['file_name'] = _ApiClient["default"].convertToType(data['file_name'], 'String');
99
+ }
100
+ if (data.hasOwnProperty('file_formats')) {
101
+ obj['file_formats'] = _ApiClient["default"].convertToType(data['file_formats'], _EmailActionFileFormats["default"]);
102
+ }
103
+ if (data.hasOwnProperty('delivery')) {
104
+ obj['delivery'] = _ApiClient["default"].convertToType(data['delivery'], _EmailActionDelivery["default"]);
105
+ }
106
+ if (data.hasOwnProperty('max_attachment_mb')) {
107
+ obj['max_attachment_mb'] = _ApiClient["default"].convertToType(data['max_attachment_mb'], 'Number');
108
+ }
109
+ if (data.hasOwnProperty('submission_type')) {
110
+ obj['submission_type'] = _ApiClient["default"].convertToType(data['submission_type'], _EmailActionSubmissionType["default"]);
111
+ }
112
+ if (data.hasOwnProperty('send_when')) {
113
+ obj['send_when'] = _ApiClient["default"].convertToType(data['send_when'], _EmailActionConditionsInput["default"]);
114
+ }
115
+ if (data.hasOwnProperty('failure_notifications_enabled')) {
116
+ obj['failure_notifications_enabled'] = _ApiClient["default"].convertToType(data['failure_notifications_enabled'], 'Boolean');
117
+ }
118
+ }
119
+ return obj;
120
+ }
121
+
122
+ /**
123
+ * Validates the JSON data with respect to <code>UpdateEmailActionRequest</code>.
124
+ * @param {Object} data The plain JavaScript object bearing properties of interest.
125
+ * @return {boolean} to indicate whether the JSON data is valid with respect to <code>UpdateEmailActionRequest</code>.
126
+ */
127
+ }, {
128
+ key: "validateJSON",
129
+ value: function validateJSON(data) {
130
+ // ensure the json data is a string
131
+ if (data['name'] && !(typeof data['name'] === 'string' || data['name'] instanceof String)) {
132
+ throw new Error("Expected the field `name` to be a primitive type in the JSON string but got " + data['name']);
133
+ }
134
+ // ensure the json data is an array
135
+ if (!Array.isArray(data['to'])) {
136
+ throw new Error("Expected the field `to` to be an array in the JSON data but got " + data['to']);
137
+ }
138
+ // ensure the json data is an array
139
+ if (!Array.isArray(data['cc'])) {
140
+ throw new Error("Expected the field `cc` to be an array in the JSON data but got " + data['cc']);
141
+ }
142
+ // ensure the json data is an array
143
+ if (!Array.isArray(data['bcc'])) {
144
+ throw new Error("Expected the field `bcc` to be an array in the JSON data but got " + data['bcc']);
145
+ }
146
+ // ensure the json data is a string
147
+ if (data['from_name'] && !(typeof data['from_name'] === 'string' || data['from_name'] instanceof String)) {
148
+ throw new Error("Expected the field `from_name` to be a primitive type in the JSON string but got " + data['from_name']);
149
+ }
150
+ // ensure the json data is a string
151
+ if (data['from_address'] && !(typeof data['from_address'] === 'string' || data['from_address'] instanceof String)) {
152
+ throw new Error("Expected the field `from_address` to be a primitive type in the JSON string but got " + data['from_address']);
153
+ }
154
+ // ensure the json data is a string
155
+ if (data['reply_to'] && !(typeof data['reply_to'] === 'string' || data['reply_to'] instanceof String)) {
156
+ throw new Error("Expected the field `reply_to` to be a primitive type in the JSON string but got " + data['reply_to']);
157
+ }
158
+ // ensure the json data is a string
159
+ if (data['subject'] && !(typeof data['subject'] === 'string' || data['subject'] instanceof String)) {
160
+ throw new Error("Expected the field `subject` to be a primitive type in the JSON string but got " + data['subject']);
161
+ }
162
+ // ensure the json data is a string
163
+ if (data['message'] && !(typeof data['message'] === 'string' || data['message'] instanceof String)) {
164
+ throw new Error("Expected the field `message` to be a primitive type in the JSON string but got " + data['message']);
165
+ }
166
+ // ensure the json data is a string
167
+ if (data['file_name'] && !(typeof data['file_name'] === 'string' || data['file_name'] instanceof String)) {
168
+ throw new Error("Expected the field `file_name` to be a primitive type in the JSON string but got " + data['file_name']);
169
+ }
170
+ // validate the optional field `send_when`
171
+ if (data['send_when']) {
172
+ // data not null
173
+ _EmailActionConditionsInput["default"].validateJSON(data['send_when']);
174
+ }
175
+ return true;
176
+ }
177
+ }]);
178
+ }();
179
+ /**
180
+ * A name for the email action, shown in the dashboard. Null shows its recipients instead.
181
+ * @member {String} name
182
+ */
183
+ UpdateEmailActionRequest.prototype['name'] = undefined;
184
+
185
+ /**
186
+ * Whether it sends emails. DocSpring turns an email action off after 3 days of failed emails, or straight away when one of the addresses in `to`, `cc` or `bcc` (not one from a field or metadata) bounces or marks an email as spam.
187
+ * @member {Boolean} enabled
188
+ */
189
+ UpdateEmailActionRequest.prototype['enabled'] = undefined;
190
+
191
+ /**
192
+ * Who gets each email: email addresses, and tags for an address that each submission gives, from one of the template's text or email fields (`{{ data.client_email }}`, or `{{ data["client email"] }}` for a name with spaces) or from its metadata (`{{ metadata.agent_email }}`, or `{{ metadata.agent.email }}` for a value in an object). A tag whose value is blank or isn't a valid address is skipped for that submission, and so is a field an account email action names that the template doesn't have. `{{ signer.email }}` sends each of the submission's signers their own email, to them alone, and everyone else in `to`, `cc` and `bcc` one email together, without the signers. An email needs at least one entry in `to`, `cc` or `bcc`, and at most 10 across them.
193
+ * @member {Array.<String>} to
194
+ */
195
+ UpdateEmailActionRequest.prototype['to'] = undefined;
196
+
197
+ /**
198
+ * Who is copied on each email, as in `to` (but not `{{ signer.email }}`).
199
+ * @member {Array.<String>} cc
200
+ */
201
+ UpdateEmailActionRequest.prototype['cc'] = undefined;
202
+
203
+ /**
204
+ * Who is blind-copied on each email, as in `to` (but not `{{ signer.email }}`).
205
+ * @member {Array.<String>} bcc
206
+ */
207
+ UpdateEmailActionRequest.prototype['bcc'] = undefined;
208
+
209
+ /**
210
+ * The sender's name. Null uses your account's name. From DocSpring's shared address, the name is followed by "via DocSpring".
211
+ * @member {String} from_name
212
+ */
213
+ UpdateEmailActionRequest.prototype['from_name'] = undefined;
214
+
215
+ /**
216
+ * The sender's address, at one of your verified email domains. Null sends from DocSpring's shared address.
217
+ * @member {String} from_address
218
+ */
219
+ UpdateEmailActionRequest.prototype['from_address'] = undefined;
220
+
221
+ /**
222
+ * Where replies go: a team member's email address, or an address at one of your verified email domains. Null sends without a reply address.
223
+ * @member {String} reply_to
224
+ */
225
+ UpdateEmailActionRequest.prototype['reply_to'] = undefined;
226
+
227
+ /**
228
+ * The subject line, a Liquid template with the variables `account.name`, `template.name`, `template.id`, `submission.id`, the submission's values as `data.<field name>` (`data["field name"]` for a name with spaces) and its metadata as `metadata.<key>`, such as `Your {{ template.name }}`. Null uses the template's name followed by the file it sends, such as "Lease PDF", or by "files" when it sends several.
229
+ * @member {String} subject
230
+ */
231
+ UpdateEmailActionRequest.prototype['subject'] = undefined;
232
+
233
+ /**
234
+ * The email's text, a Liquid template with the same variables as `subject`. `if`, `unless` and `case` tags work. Line breaks are kept. Null uses a short message that says the files are attached or ready to download.
235
+ * @member {String} message
236
+ */
237
+ UpdateEmailActionRequest.prototype['message'] = undefined;
238
+
239
+ /**
240
+ * The attached files' name, a Liquid template with the same variables as `subject`, such as `{{ data.last_name }} lease`. Each file's extension (`.pdf`, `.docx` or `.odt`) is added. Null uses the submission's `pdf_filename` metadata when it has one, and otherwise the template's name. A download link's files have the names their other downloads have: the submission's `pdf_filename`, or its ID.
241
+ * @member {String} file_name
242
+ */
243
+ UpdateEmailActionRequest.prototype['file_name'] = undefined;
244
+
245
+ /**
246
+ * Which of the submission's files the email sends: `all` sends every file the submission made (its PDF, and a Word template's Word document and OpenDocument file when it made them), and `docx`, `odt` or `pdf` sends only that file. A submission that made none of them sends nothing, and its email shows as skipped. Only Word templates make Word documents and OpenDocument files, so another template's email action takes `pdf` or `all`.
247
+ * @member {module:model/EmailActionFileFormats} file_formats
248
+ */
249
+ UpdateEmailActionRequest.prototype['file_formats'] = undefined;
250
+
251
+ /**
252
+ * `attachment` attaches the files, or sends a download link when together they're larger than `max_attachment_mb`. `link` sends a download link, which works for 7 days. Accounts with a BAA start with `link`.
253
+ * @member {module:model/EmailActionDelivery} delivery
254
+ */
255
+ UpdateEmailActionRequest.prototype['delivery'] = undefined;
256
+
257
+ /**
258
+ * With `delivery` `attachment`, files larger than this many megabytes in all (1 MB is 1,000,000 bytes) are sent as a download link instead. Emailing a file makes it about 38% larger, and many company mail servers refuse emails over 10 MB, so the default is 7. Raise it only when every recipient's mail server accepts larger emails, such as Microsoft 365 (up to 36 MB) or Gmail (50 MB).
259
+ * @member {Number} max_attachment_mb
260
+ */
261
+ UpdateEmailActionRequest.prototype['max_attachment_mb'] = undefined;
262
+
263
+ /**
264
+ * Which submissions send emails: `live`, `test` or `all`. Test submissions only email your team's members, and skip every other recipient.
265
+ * @member {module:model/EmailActionSubmissionType} submission_type
266
+ */
267
+ UpdateEmailActionRequest.prototype['submission_type'] = undefined;
268
+
269
+ /**
270
+ * Sends the email only when the submission's values meet these conditions, which work as a conditional logic rule's do. The values are the ones the PDF has: formulas worked out, and blank for a field that a rule hides. A field the template doesn't have (in an account email action's conditions) counts as blank. A submission that doesn't meet them sends nothing, and its email shows as skipped. Null sends for every submission.
271
+ * @member {module:model/EmailActionConditionsInput} send_when
272
+ */
273
+ UpdateEmailActionRequest.prototype['send_when'] = undefined;
274
+
275
+ /**
276
+ * Whether the account's owner gets an email when the email action's emails keep failing.
277
+ * @member {Boolean} failure_notifications_enabled
278
+ */
279
+ UpdateEmailActionRequest.prototype['failure_notifications_enabled'] = undefined;
280
+ var _default = exports["default"] = UpdateEmailActionRequest;
@@ -15,7 +15,7 @@ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r),
15
15
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
16
16
  function _toPrimitive(t, e) { if ("object" != _typeof(t) || !t) return t; var r; if ("undefined" != typeof Symbol && void 0 !== (r = t[Symbol.toPrimitive])) { var i = r.call(t, e || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === e ? String : Number)(t); } /**
17
17
  * DocSpring API
18
- * Use DocSpring's API to programmatically fill out PDF forms, convert HTML to PDFs, merge PDFs, or request legally binding e-signatures.
18
+ * Use DocSpring's API to fill PDF forms, generate PDFs and Word documents from HTML or Word templates, merge PDFs, and request legally binding e-signatures.
19
19
  *
20
20
  * The version of the OpenAPI document: v2
21
21
  *
@@ -28,7 +28,7 @@ function _toPrimitive(t, e) { if ("object" != _typeof(t) || !t) return t; var r;
28
28
  /**
29
29
  * The UpdateSignatureRequestRequest model module.
30
30
  * @module model/UpdateSignatureRequestRequest
31
- * @version 4.2.0
31
+ * @version 4.4.0
32
32
  */
33
33
  var UpdateSignatureRequestRequest = /*#__PURE__*/function () {
34
34
  /**
@@ -13,7 +13,7 @@ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r),
13
13
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
14
14
  function _toPrimitive(t, e) { if ("object" != _typeof(t) || !t) return t; var r; if ("undefined" != typeof Symbol && void 0 !== (r = t[Symbol.toPrimitive])) { var i = r.call(t, e || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === e ? String : Number)(t); } /**
15
15
  * DocSpring API
16
- * Use DocSpring's API to programmatically fill out PDF forms, convert HTML to PDFs, merge PDFs, or request legally binding e-signatures.
16
+ * Use DocSpring's API to fill PDF forms, generate PDFs and Word documents from HTML or Word templates, merge PDFs, and request legally binding e-signatures.
17
17
  *
18
18
  * The version of the OpenAPI document: v2
19
19
  *
@@ -26,12 +26,12 @@ function _toPrimitive(t, e) { if ("object" != _typeof(t) || !t) return t; var r;
26
26
  /**
27
27
  * The UpdateTemplateDocumentRequest model module.
28
28
  * @module model/UpdateTemplateDocumentRequest
29
- * @version 4.2.0
29
+ * @version 4.4.0
30
30
  */
31
31
  var UpdateTemplateDocumentRequest = /*#__PURE__*/function () {
32
32
  /**
33
33
  * Constructs a new <code>UpdateTemplateDocumentRequest</code>.
34
- * The new PDF, as one of `cache_id`, `document_url` and `document_base64`.
34
+ * The new PDF, or a Word template's new Word document, as one of `cache_id`, `document_url` and `document_base64`.
35
35
  * @alias module:model/UpdateTemplateDocumentRequest
36
36
  */
37
37
  function UpdateTemplateDocumentRequest() {
@@ -108,31 +108,31 @@ var UpdateTemplateDocumentRequest = /*#__PURE__*/function () {
108
108
  }]);
109
109
  }();
110
110
  /**
111
- * The `fields.key` of the new PDF, uploaded with the presigned upload (GET /uploads/presign).
111
+ * The `fields.key` of the new PDF or Word document (.docx or .odt), uploaded with the presigned upload (GET /uploads/presign).
112
112
  * @member {String} cache_id
113
113
  */
114
114
  UpdateTemplateDocumentRequest.prototype['cache_id'] = undefined;
115
115
 
116
116
  /**
117
- * An https:// link to the template's PDF (up to 100 MB), instead of `cache_id`. DocSpring downloads it after responding, following redirects to other https:// links: the template's `document.state` is `downloading` until then (sync.api hosts wait for it). If it can't be downloaded, the state is `download_failed` and `document.error_message` says why.
117
+ * An https:// link to the template's document, instead of `cache_id`: a PDF template's PDF (up to 100 MB) or a Word template's Word document (.docx or .odt, up to 50 MB). DocSpring downloads it after responding, following redirects to other https:// links: the template's `document.state` is `downloading` until then, and `converting` while an .odt is converted (sync.api hosts wait for both). If it can't be downloaded, the state is `download_failed` and `document.error_message` says why.
118
118
  * @member {String} document_url
119
119
  */
120
120
  UpdateTemplateDocumentRequest.prototype['document_url'] = undefined;
121
121
 
122
122
  /**
123
- * The template's PDF, encoded as base64 (a `data:` URI works too), instead of `cache_id`. Up to 7 MB before it's encoded: send a larger file with `cache_id` or `document_url`.
123
+ * The template's document (a PDF, or a Word template's Word document), encoded as base64 (a `data:` URI works too), instead of `cache_id`. Line breaks and spaces in it are ignored. Up to 7 MB before it's encoded: send a larger file with `cache_id` or `document_url`.
124
124
  * @member {String} document_base64
125
125
  */
126
126
  UpdateTemplateDocumentRequest.prototype['document_base64'] = undefined;
127
127
 
128
128
  /**
129
- * The PDF's file name, for a `cache_id` (presigned uploads don't send one) or `document_base64`. A `document_url`'s is the last part of its path unless you set it.
129
+ * The file's name, for a `cache_id` (presigned uploads don't send one) or `document_base64`. A `document_url`'s is the last part of its path unless you set it.
130
130
  * @member {String} filename
131
131
  */
132
132
  UpdateTemplateDocumentRequest.prototype['filename'] = undefined;
133
133
 
134
134
  /**
135
- * Replace all of the template's fields with the fillable fields in the new PDF, once DocSpring has processed it (`document.field_reimport_state`). As on a first upload, the default typeface, font size, bold and color are taken from the PDF's fields; the template's other settings are kept. If the PDF has no fillable fields, the template keeps its fields. A locked template can't re-import its fields.
135
+ * Replace all of the template's fields with the fillable fields in the new PDF, once DocSpring has processed it (`document.field_reimport_state`). As on a first upload, the default typeface, font size, bold and color are taken from the PDF's fields; the template's other settings are kept. If the PDF has no fillable fields, the template keeps its fields. A locked template can't re-import its fields. Only for PDF templates: a Word template adds a field for each new tag.
136
136
  * @member {Boolean} reimport_fields
137
137
  */
138
138
  UpdateTemplateDocumentRequest.prototype['reimport_fields'] = undefined;
@@ -17,7 +17,7 @@ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r),
17
17
  function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
18
18
  function _toPrimitive(t, e) { if ("object" != _typeof(t) || !t) return t; var r; if ("undefined" != typeof Symbol && void 0 !== (r = t[Symbol.toPrimitive])) { var i = r.call(t, e || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === e ? String : Number)(t); } /**
19
19
  * DocSpring API
20
- * Use DocSpring's API to programmatically fill out PDF forms, convert HTML to PDFs, merge PDFs, or request legally binding e-signatures.
20
+ * Use DocSpring's API to fill PDF forms, generate PDFs and Word documents from HTML or Word templates, merge PDFs, and request legally binding e-signatures.
21
21
  *
22
22
  * The version of the OpenAPI document: v2
23
23
  *
@@ -30,7 +30,7 @@ function _toPrimitive(t, e) { if ("object" != _typeof(t) || !t) return t; var r;
30
30
  /**
31
31
  * The UpdateTemplateFieldsRequest model module.
32
32
  * @module model/UpdateTemplateFieldsRequest
33
- * @version 4.2.0
33
+ * @version 4.4.0
34
34
  */
35
35
  var UpdateTemplateFieldsRequest = /*#__PURE__*/function () {
36
36
  /**