docspring 3.3.0 → 4.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +79 -19
- package/README.md +74 -63
- package/dist/ApiClient.js +63 -28
- package/dist/RequestSchemas.js +3452 -0
- package/dist/RequestValidator.js +494 -0
- package/dist/api/Client.js +1769 -921
- package/dist/index.js +847 -154
- package/dist/model/AddTemplateFieldsRequest.js +132 -0
- package/dist/model/AiFieldNamingLanguage.js +64 -0
- package/dist/model/{CreateWebhookData.js → AuthenticationCheck.js} +32 -28
- package/dist/model/BarcodeSymbology.js +89 -0
- package/dist/model/CheckCharacter.js +74 -0
- package/dist/model/CombinedFieldType.js +59 -0
- package/dist/model/CombinedPdf.js +294 -0
- package/dist/model/{MoveFolderData.js → CombinedPdfFiles.js} +27 -27
- package/dist/model/CombinedPdfList.js +132 -0
- package/dist/model/{ForbiddenErrorResponse.js → CombinedPdfSource.js} +59 -73
- package/dist/model/CombinedPdfSourceInput.js +270 -0
- package/dist/model/CombinedPdfSourcePdf.js +130 -0
- package/dist/model/CombinedPdfSourceType.js +74 -0
- package/dist/model/CombinedPdfState.js +74 -0
- package/dist/model/{CopyTemplateOptions.js → CopyTemplateRequest.js} +26 -22
- package/dist/model/{CombinePdfsData.js → CreateCombinedPdfRequest.js} +69 -53
- package/dist/model/{CreateCustomFileData.js → CreateCustomFileFromUploadRequest.js} +25 -23
- package/dist/model/{CreateFolderData.js → CreateFolderRequest.js} +47 -28
- package/dist/model/{CreateCustomFileResponse.js → CreateSignatureRequestEventRequest.js} +49 -73
- package/dist/model/CreateSignatureRequestTokenRequest.js +88 -0
- package/dist/model/CreateSubmissionBatchRequest.js +192 -0
- package/dist/model/CreateSubmissionRequest.js +226 -0
- package/dist/model/CreateTemplateRequest.js +613 -0
- package/dist/model/CreateWebhookRequest.js +234 -0
- package/dist/model/CustomFile.js +67 -16
- package/dist/model/CustomFileList.js +132 -0
- package/dist/model/CustomFileSourcePdf.js +130 -0
- package/dist/model/ErrorCode.js +154 -0
- package/dist/model/{CreateSubmissionResponse.js → ErrorDetail.js} +65 -75
- package/dist/model/ErrorInfo.js +211 -0
- package/dist/model/ErrorResponse.js +12 -41
- package/dist/model/ExpirationInterval.js +64 -0
- package/dist/model/Field.js +1230 -0
- package/dist/model/FieldComparisonCondition.js +137 -0
- package/dist/model/FieldComparisonOperator.js +69 -0
- package/dist/model/FieldDependency.js +154 -0
- package/dist/model/FieldDependencyInput.js +154 -0
- package/dist/model/FieldDisplayType.js +79 -0
- package/dist/model/{MultipleErrorsResponse.js → FieldEqualsCondition.js} +48 -52
- package/dist/model/FieldEqualsOperator.js +59 -0
- package/dist/model/FieldGroup.js +206 -0
- package/dist/model/FieldGroupInput.js +180 -0
- package/dist/model/FieldGroupType.js +59 -0
- package/dist/model/{SuccessMultipleErrorsResponse.js → FieldInCondition.js} +54 -53
- package/dist/model/FieldInput.js +1012 -0
- package/dist/model/FieldOverride.js +722 -0
- package/dist/model/FieldPresenceCondition.js +126 -0
- package/dist/model/FieldPresenceOperator.js +59 -0
- package/dist/model/FieldRangeCondition.js +148 -0
- package/dist/model/FieldReimportState.js +69 -0
- package/dist/model/FieldSetupLogic.js +59 -0
- package/dist/model/FieldSetupNaming.js +59 -0
- package/dist/model/FieldSetupSource.js +64 -0
- package/dist/model/FieldType.js +124 -0
- package/dist/model/Folder.js +38 -11
- package/dist/model/FolderList.js +132 -0
- package/dist/model/GenerateFilesFormat.js +54 -0
- package/dist/model/GenerateSubmissionFilesRequest.js +115 -0
- package/dist/model/GeneratedFile.js +214 -0
- package/dist/model/GeneratedFileState.js +64 -0
- package/dist/model/HtmlEngineOptions.js +230 -0
- package/dist/model/HtmlEngineOptionsInput.js +193 -0
- package/dist/model/ImageGravity.js +94 -0
- package/dist/model/ImageScaleType.js +64 -0
- package/dist/model/ModelCodeLanguage.js +94 -0
- package/dist/model/{UpdatePdfTemplate.js → MoveFolderRequest.js} +34 -28
- package/dist/model/{MoveTemplateData.js → MoveTemplateRequest.js} +25 -35
- package/dist/model/NumberConditionType.js +79 -0
- package/dist/model/OutputFormat.js +59 -0
- package/dist/model/PageFormat.js +114 -0
- package/dist/model/PageImage.js +220 -0
- package/dist/model/{TemplateDeleteResponse.js → PageImages.js} +57 -70
- package/dist/model/PredefinedField.js +183 -0
- package/dist/model/PredefinedFieldInput.js +183 -0
- package/dist/model/{PublishVersionData.js → PublishTemplateVersionRequest.js} +33 -33
- package/dist/model/{AddFieldsData.js → RemoveTemplateFieldsRequest.js} +32 -30
- package/dist/model/{RenameFolderData.js → RenameFolderRequest.js} +25 -23
- package/dist/model/ReorderTemplateFieldsRequest.js +114 -0
- package/dist/model/{RestoreVersionData.js → RestoreTemplateVersionRequest.js} +25 -23
- package/dist/model/ShapeType.js +79 -0
- package/dist/model/{SubmissionDataRequestShow.js → SignatureRequest.js} +165 -240
- package/dist/model/SignatureRequestAuthSecondFactorType.js +79 -0
- package/dist/model/SignatureRequestAuthType.js +84 -0
- package/dist/model/{SubmissionDataRequestEvent.js → SignatureRequestEvent.js} +67 -149
- package/dist/model/SignatureRequestEventType.js +79 -0
- package/dist/model/SignatureRequestInput.js +278 -0
- package/dist/model/SignatureRequestMessageType.js +94 -0
- package/dist/model/SignatureRequestState.js +64 -0
- package/dist/model/SignatureRequestToken.js +195 -0
- package/dist/model/SignatureRequestTokenType.js +59 -0
- package/dist/model/StringConditionType.js +74 -0
- package/dist/model/Submission.js +198 -341
- package/dist/model/SubmissionAction.js +30 -115
- package/dist/model/SubmissionActionState.js +69 -0
- package/dist/model/SubmissionActionType.js +84 -0
- package/dist/model/SubmissionBatch.js +74 -55
- package/dist/model/SubmissionBatchState.js +64 -0
- package/dist/model/SubmissionFiles.js +117 -0
- package/dist/model/SubmissionInput.js +218 -0
- package/dist/model/{ListSubmissionsResponse.js → SubmissionList.js} +35 -42
- package/dist/model/SubmissionSource.js +69 -0
- package/dist/model/SubmissionSourcePdf.js +130 -0
- package/dist/model/SubmissionState.js +114 -0
- package/dist/model/{SubmissionBatchData.js → SubmissionValidation.js} +46 -48
- package/dist/model/Template.js +359 -560
- package/dist/model/TemplateActor.js +171 -0
- package/dist/model/TemplateActorType.js +64 -0
- package/dist/model/TemplateDefaults.js +307 -0
- package/dist/model/TemplateDefaultsInput.js +305 -0
- package/dist/model/TemplateDiff.js +206 -0
- package/dist/model/TemplateDiffSummary.js +165 -0
- package/dist/model/TemplateDocument.js +280 -0
- package/dist/model/TemplateDocumentState.js +84 -0
- package/dist/model/TemplateFieldChange.js +146 -0
- package/dist/model/TemplateFieldChanges.js +196 -0
- package/dist/model/{CreatePdfSubmissionData.js → TemplateFieldDependency.js} +70 -89
- package/dist/model/TemplateFieldDependencyAction.js +64 -0
- package/dist/model/{TemplatePublishVersionResponse.js → TemplateFieldDependencyCondition.js} +51 -61
- package/dist/model/TemplateFieldDependencyConditionInput.js +304 -0
- package/dist/model/TemplateFieldDependencyInput.js +182 -0
- package/dist/model/TemplateFieldDependencyMatch.js +59 -0
- package/dist/model/TemplateFieldDependencyOperator.js +99 -0
- package/dist/model/TemplateFieldLogicStatus.js +74 -0
- package/dist/model/{CreatePdfTemplate.js → TemplateFieldMove.js} +52 -28
- package/dist/model/TemplateFields.js +147 -0
- package/dist/model/TemplateFormMode.js +64 -0
- package/dist/model/{TemplateModelCodeResponse.js → TemplateModelCode.js} +34 -86
- package/dist/model/TemplatePageAiError.js +69 -0
- package/dist/model/TemplatePageAiNamingStatus.js +59 -0
- package/dist/model/TemplatePageFieldsStatus.js +74 -0
- package/dist/model/TemplatePageImageStatus.js +59 -0
- package/dist/model/TemplatePageImages.js +158 -0
- package/dist/model/TemplatePageProcessingStatus.js +162 -0
- package/dist/model/{SubmissionDataRequestToken.js → TemplateSourcePdf.js} +52 -56
- package/dist/model/TemplateSummary.js +560 -0
- package/dist/model/{SuccessErrorResponse.js → TemplateSummaryList.js} +43 -55
- package/dist/model/TemplateType.js +59 -0
- package/dist/model/{Submission422Response.js → TemplateVersion.js} +60 -63
- package/dist/model/TemplateVersionType.js +64 -0
- package/dist/model/TextAlignment.js +69 -0
- package/dist/model/TextOverflow.js +59 -0
- package/dist/model/TextVerticalAlignment.js +64 -0
- package/dist/model/Typeface.js +134 -0
- package/dist/model/UpdateSignatureRequestRequest.js +183 -0
- package/dist/model/UpdateTemplateDocumentRequest.js +139 -0
- package/dist/model/UpdateTemplateFieldsRequest.js +132 -0
- package/dist/model/UpdateTemplateRequest.js +523 -0
- package/dist/model/UpdateWebhookRequest.js +209 -0
- package/dist/model/UploadMethod.js +54 -0
- package/dist/model/{UploadPresignResponse.js → UploadPresign.js} +53 -58
- package/dist/model/UrlSourcePdf.js +130 -0
- package/dist/model/ValidateSubmissionRequest.js +226 -0
- package/dist/model/Webhook.js +58 -73
- package/dist/model/WebhookEventType.js +174 -0
- package/dist/model/WebhookList.js +132 -0
- package/dist/model/WebhookMode.js +59 -0
- package/package.json +1 -1
- package/dist/model/BatchGeneratePdfs201Response.js +0 -194
- package/dist/model/CombinedSubmission.js +0 -313
- package/dist/model/CombinedSubmissionAction.js +0 -268
- package/dist/model/CreateCombinedSubmissionResponse.js +0 -180
- package/dist/model/CreateHtmlTemplate.js +0 -108
- package/dist/model/CreateSubmissionDataRequestData.js +0 -314
- package/dist/model/CreateSubmissionDataRequestEventRequest.js +0 -239
- package/dist/model/CreateSubmissionDataRequestEventResponse.js +0 -167
- package/dist/model/CreateSubmissionDataRequestResponse.js +0 -167
- package/dist/model/CreateSubmissionDataRequestTokenResponse.js +0 -167
- package/dist/model/ErrorOrMultipleErrorsResponse.js +0 -153
- package/dist/model/JsonSchema.js +0 -205
- package/dist/model/SubmissionBatchWithSubmissions.js +0 -228
- package/dist/model/SubmissionDataRequest.js +0 -496
- package/dist/model/SubmissionPreview.js +0 -509
- package/dist/model/TemplateAddFieldsResponse.js +0 -156
- package/dist/model/TemplatePreview.js +0 -796
- package/dist/model/UpdateHtmlTemplate.js +0 -108
- package/dist/model/UpdateSubmissionDataRequestData.js +0 -311
- package/dist/model/UpdateWebhookData.js +0 -108
package/dist/model/Submission.js
CHANGED
|
@@ -5,8 +5,14 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports["default"] = void 0;
|
|
7
7
|
var _ApiClient = _interopRequireDefault(require("../ApiClient"));
|
|
8
|
+
var _ErrorDetail = _interopRequireDefault(require("./ErrorDetail"));
|
|
9
|
+
var _OutputFormat = _interopRequireDefault(require("./OutputFormat"));
|
|
10
|
+
var _SignatureRequest = _interopRequireDefault(require("./SignatureRequest"));
|
|
8
11
|
var _SubmissionAction = _interopRequireDefault(require("./SubmissionAction"));
|
|
9
|
-
var
|
|
12
|
+
var _SubmissionFiles = _interopRequireDefault(require("./SubmissionFiles"));
|
|
13
|
+
var _SubmissionSource = _interopRequireDefault(require("./SubmissionSource"));
|
|
14
|
+
var _SubmissionState = _interopRequireDefault(require("./SubmissionState"));
|
|
15
|
+
var _TemplateType = _interopRequireDefault(require("./TemplateType"));
|
|
10
16
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
|
|
11
17
|
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); }
|
|
12
18
|
function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t["return"] || t["return"](); } finally { if (u) throw o; } } }; }
|
|
@@ -18,9 +24,9 @@ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r),
|
|
|
18
24
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
19
25
|
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); } /**
|
|
20
26
|
* DocSpring API
|
|
21
|
-
* Use DocSpring's API to programmatically fill out PDF forms, convert HTML to PDFs, merge PDFs, or request legally binding e-signatures.
|
|
27
|
+
* Use DocSpring's API to programmatically fill out PDF forms, convert HTML to PDFs, merge PDFs, or request legally binding e-signatures.
|
|
22
28
|
*
|
|
23
|
-
* The version of the OpenAPI document:
|
|
29
|
+
* The version of the OpenAPI document: v2
|
|
24
30
|
*
|
|
25
31
|
*
|
|
26
32
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -31,41 +37,43 @@ function _toPrimitive(t, e) { if ("object" != _typeof(t) || !t) return t; var r;
|
|
|
31
37
|
/**
|
|
32
38
|
* The Submission model module.
|
|
33
39
|
* @module model/Submission
|
|
34
|
-
* @version
|
|
40
|
+
* @version 4.1.0
|
|
35
41
|
*/
|
|
36
42
|
var Submission = /*#__PURE__*/function () {
|
|
37
43
|
/**
|
|
38
44
|
* Constructs a new <code>Submission</code>.
|
|
45
|
+
* Data submitted to a template, and the PDF generated from it.
|
|
39
46
|
* @alias module:model/Submission
|
|
40
47
|
* @extends Object
|
|
41
|
-
* @param
|
|
42
|
-
* @param
|
|
43
|
-
* @param
|
|
44
|
-
* @param
|
|
45
|
-
* @param
|
|
46
|
-
* @param
|
|
47
|
-
* @param
|
|
48
|
-
* @param
|
|
49
|
-
* @param
|
|
50
|
-
* @param
|
|
51
|
-
* @param
|
|
52
|
-
* @param
|
|
53
|
-
* @param
|
|
54
|
-
* @param
|
|
55
|
-
* @param
|
|
56
|
-
* @param
|
|
57
|
-
* @param truncated_text {Object}
|
|
58
|
-
* @param
|
|
59
|
-
* @param
|
|
60
|
-
* @param
|
|
61
|
-
* @param
|
|
62
|
-
* @param
|
|
63
|
-
* @param
|
|
64
|
-
* @param
|
|
48
|
+
* @param id {String} The submission's ID.
|
|
49
|
+
* @param template_id {String} Null once the template has been permanently deleted.
|
|
50
|
+
* @param template_type {module:model/TemplateType} The template's type: `pdf` or `html`.
|
|
51
|
+
* @param template_version {String} The published version of the template the submission used. Null for the draft.
|
|
52
|
+
* @param batch_id {String} The ID of the batch the submission was created in.
|
|
53
|
+
* @param source {module:model/SubmissionSource} `api`: created with the API. `web`: a web form. `reprocess`: a copy of another submission, made to generate its PDF again.
|
|
54
|
+
* @param state {module:model/SubmissionState} `pending` until the PDF has been generated, then `processed`. `waiting_for_signature_requests` until every signature request is completed. `insufficient_credits`: waiting for credits; `error_message` says whether the PDF is generated once you add them. `account_suspended`: waiting for the account to be reactivated, for up to 30 days. Waiting ends in `error` if it's discarded or takes over 30 days. Every other state is final, with no PDF: `invalid_data` (the data doesn't match the template's fields: see `data_errors`), `declined` (a signature request was declined), and the states where generating the PDF failed, which have an `error_message`: `syntax_error` (a mistake in an HTML template's Liquid or SCSS), `image_download_failed` or `image_processing_failed` (an image in the data or the template couldn't be downloaded or read) and `error` (anything else). Older submissions can also be `license_revoked` or `accidental`.
|
|
55
|
+
* @param test {Boolean} Test PDFs have a watermark and are free. Live PDFs use credits. Submissions made with a test API token are always test submissions.
|
|
56
|
+
* @param editable {Boolean} `true` keeps the PDF's text and check fields fillable, and `false` flattens every field. Left out, the template decides: its `editable_submissions` setting, or each field's own Editable option. A response shows the template's setting when the request left this out. Can't be `true` with `signature_requests`.
|
|
57
|
+
* @param data {Object.<String, Object>} The submission's data, with the values entered in completed signature requests. Lists leave it out (null) unless you pass `include_data=true`. Empty once the submission has expired.
|
|
58
|
+
* @param data_errors {Array.<module:model/ErrorDetail>} Why the data doesn't match the template's fields, when `state` is `invalid_data`: the same details as the 422 response that recorded it, with pointers into the request that created the submission (`/data/name`). Cleared once the submission has expired.
|
|
59
|
+
* @param error_message {String} Why the PDF couldn't be generated, when `state` is `error`.
|
|
60
|
+
* @param metadata {Object.<String, Object>} Your own data about the submission, such as an ID from your app. It isn't printed on the PDF.
|
|
61
|
+
* @param has_password {Boolean} Whether the PDF needs a password to open (`password`).
|
|
62
|
+
* @param signature_requests {Array.<module:model/SignatureRequest>} The people asked to sign the submission (and fill in their fields), in order.
|
|
63
|
+
* @param actions {Array.<module:model/SubmissionAction>} The uploads of the submission's PDF to your storage (account integrations).
|
|
64
|
+
* @param truncated_text {Object.<String, Array.<String>>} The text of each field that didn't fit in it, by field name. Left out (null) with `data`, and empty once the submission has expired.
|
|
65
|
+
* @param output_formats {Array.<module:model/OutputFormat>} What the submission makes: `pdf`, and `png` (an image of each page of the PDF, up to 100 pages) when you ask for it. Default `["pdf"]`. POST /submissions/{submission_id}/generate_files adds `png` to a processed submission.
|
|
66
|
+
* @param files {module:model/SubmissionFiles} The generated files: `pdf` once the submission has been processed, `png` (the images of the PDF's pages, when `output_formats` has it: `files.png.pages[0]` is page 1), `audit_trail` once its signature requests are completed, and `preview` once a preview PDF has been generated. Empty once the submission has expired.
|
|
67
|
+
* @param preview_generated_at {Date} When the preview PDF was generated. Null if there is no preview.
|
|
68
|
+
* @param expired {Boolean} An expired submission's data, metadata, password and PDF have been deleted.
|
|
69
|
+
* @param expires_at {Date} When the submission expires. Null if it's kept until you delete it.
|
|
70
|
+
* @param processed_at {Date} When the PDF was generated. Null until then.
|
|
71
|
+
* @param created_at {Date} When the submission was created.
|
|
72
|
+
* @param updated_at {Date} When the submission was last updated.
|
|
65
73
|
*/
|
|
66
|
-
function Submission(
|
|
74
|
+
function Submission(id, template_id, template_type, template_version, batch_id, source, state, test, editable, data, data_errors, error_message, metadata, has_password, signature_requests, actions, truncated_text, output_formats, files, preview_generated_at, expired, expires_at, processed_at, created_at, updated_at) {
|
|
67
75
|
_classCallCheck(this, Submission);
|
|
68
|
-
Submission.initialize(this,
|
|
76
|
+
Submission.initialize(this, id, template_id, template_type, template_version, batch_id, source, state, test, editable, data, data_errors, error_message, metadata, has_password, signature_requests, actions, truncated_text, output_formats, files, preview_generated_at, expired, expires_at, processed_at, created_at, updated_at);
|
|
69
77
|
}
|
|
70
78
|
|
|
71
79
|
/**
|
|
@@ -75,31 +83,32 @@ var Submission = /*#__PURE__*/function () {
|
|
|
75
83
|
*/
|
|
76
84
|
return _createClass(Submission, null, [{
|
|
77
85
|
key: "initialize",
|
|
78
|
-
value: function initialize(obj,
|
|
79
|
-
obj['batch_id'] = batch_id;
|
|
80
|
-
obj['data_requests'] = data_requests;
|
|
81
|
-
obj['editable'] = editable;
|
|
82
|
-
obj['error_message'] = error_message;
|
|
83
|
-
obj['expired'] = expired;
|
|
84
|
-
obj['expires_at'] = expires_at;
|
|
86
|
+
value: function initialize(obj, id, template_id, template_type, template_version, batch_id, source, state, test, editable, data, data_errors, error_message, metadata, has_password, signature_requests, actions, truncated_text, output_formats, files, preview_generated_at, expired, expires_at, processed_at, created_at, updated_at) {
|
|
85
87
|
obj['id'] = id;
|
|
86
|
-
obj['json_schema_errors'] = json_schema_errors;
|
|
87
|
-
obj['metadata'] = metadata;
|
|
88
|
-
obj['password'] = password;
|
|
89
|
-
obj['processed_at'] = processed_at;
|
|
90
|
-
obj['state'] = state;
|
|
91
88
|
obj['template_id'] = template_id;
|
|
92
89
|
obj['template_type'] = template_type;
|
|
93
90
|
obj['template_version'] = template_version;
|
|
91
|
+
obj['batch_id'] = batch_id;
|
|
92
|
+
obj['source'] = source;
|
|
93
|
+
obj['state'] = state;
|
|
94
94
|
obj['test'] = test;
|
|
95
|
+
obj['editable'] = editable;
|
|
96
|
+
obj['data'] = data;
|
|
97
|
+
obj['data_errors'] = data_errors;
|
|
98
|
+
obj['error_message'] = error_message;
|
|
99
|
+
obj['metadata'] = metadata;
|
|
100
|
+
obj['has_password'] = has_password;
|
|
101
|
+
obj['signature_requests'] = signature_requests;
|
|
102
|
+
obj['actions'] = actions;
|
|
95
103
|
obj['truncated_text'] = truncated_text;
|
|
96
|
-
obj['
|
|
97
|
-
obj['
|
|
98
|
-
obj['permanent_download_url'] = permanent_download_url;
|
|
99
|
-
obj['preview_download_url'] = preview_download_url;
|
|
104
|
+
obj['output_formats'] = output_formats;
|
|
105
|
+
obj['files'] = files;
|
|
100
106
|
obj['preview_generated_at'] = preview_generated_at;
|
|
101
|
-
obj['
|
|
102
|
-
obj['
|
|
107
|
+
obj['expired'] = expired;
|
|
108
|
+
obj['expires_at'] = expires_at;
|
|
109
|
+
obj['processed_at'] = processed_at;
|
|
110
|
+
obj['created_at'] = created_at;
|
|
111
|
+
obj['updated_at'] = updated_at;
|
|
103
112
|
}
|
|
104
113
|
|
|
105
114
|
/**
|
|
@@ -115,86 +124,86 @@ var Submission = /*#__PURE__*/function () {
|
|
|
115
124
|
if (data) {
|
|
116
125
|
obj = obj || new Submission();
|
|
117
126
|
_ApiClient["default"].constructFromObject(data, obj, 'Object');
|
|
118
|
-
if (data.hasOwnProperty('batch_id')) {
|
|
119
|
-
obj['batch_id'] = _ApiClient["default"].convertToType(data['batch_id'], 'String');
|
|
120
|
-
}
|
|
121
|
-
if (data.hasOwnProperty('data_requests')) {
|
|
122
|
-
obj['data_requests'] = _ApiClient["default"].convertToType(data['data_requests'], [_SubmissionDataRequest["default"]]);
|
|
123
|
-
}
|
|
124
|
-
if (data.hasOwnProperty('editable')) {
|
|
125
|
-
obj['editable'] = _ApiClient["default"].convertToType(data['editable'], 'Boolean');
|
|
126
|
-
}
|
|
127
|
-
if (data.hasOwnProperty('error_message')) {
|
|
128
|
-
obj['error_message'] = _ApiClient["default"].convertToType(data['error_message'], 'String');
|
|
129
|
-
}
|
|
130
|
-
if (data.hasOwnProperty('expired')) {
|
|
131
|
-
obj['expired'] = _ApiClient["default"].convertToType(data['expired'], 'Boolean');
|
|
132
|
-
}
|
|
133
|
-
if (data.hasOwnProperty('expires_at')) {
|
|
134
|
-
obj['expires_at'] = _ApiClient["default"].convertToType(data['expires_at'], 'String');
|
|
135
|
-
}
|
|
136
127
|
if (data.hasOwnProperty('id')) {
|
|
137
128
|
obj['id'] = _ApiClient["default"].convertToType(data['id'], 'String');
|
|
138
129
|
}
|
|
139
|
-
if (data.hasOwnProperty('json_schema_errors')) {
|
|
140
|
-
obj['json_schema_errors'] = _ApiClient["default"].convertToType(data['json_schema_errors'], ['String']);
|
|
141
|
-
}
|
|
142
|
-
if (data.hasOwnProperty('metadata')) {
|
|
143
|
-
obj['metadata'] = _ApiClient["default"].convertToType(data['metadata'], Object);
|
|
144
|
-
}
|
|
145
|
-
if (data.hasOwnProperty('password')) {
|
|
146
|
-
obj['password'] = _ApiClient["default"].convertToType(data['password'], 'String');
|
|
147
|
-
}
|
|
148
|
-
if (data.hasOwnProperty('processed_at')) {
|
|
149
|
-
obj['processed_at'] = _ApiClient["default"].convertToType(data['processed_at'], 'String');
|
|
150
|
-
}
|
|
151
|
-
if (data.hasOwnProperty('state')) {
|
|
152
|
-
obj['state'] = _ApiClient["default"].convertToType(data['state'], 'String');
|
|
153
|
-
}
|
|
154
130
|
if (data.hasOwnProperty('template_id')) {
|
|
155
131
|
obj['template_id'] = _ApiClient["default"].convertToType(data['template_id'], 'String');
|
|
156
132
|
}
|
|
157
133
|
if (data.hasOwnProperty('template_type')) {
|
|
158
|
-
obj['template_type'] = _ApiClient["default"].convertToType(data['template_type'],
|
|
134
|
+
obj['template_type'] = _ApiClient["default"].convertToType(data['template_type'], _TemplateType["default"]);
|
|
159
135
|
}
|
|
160
136
|
if (data.hasOwnProperty('template_version')) {
|
|
161
137
|
obj['template_version'] = _ApiClient["default"].convertToType(data['template_version'], 'String');
|
|
162
138
|
}
|
|
139
|
+
if (data.hasOwnProperty('batch_id')) {
|
|
140
|
+
obj['batch_id'] = _ApiClient["default"].convertToType(data['batch_id'], 'String');
|
|
141
|
+
}
|
|
142
|
+
if (data.hasOwnProperty('source')) {
|
|
143
|
+
obj['source'] = _ApiClient["default"].convertToType(data['source'], _SubmissionSource["default"]);
|
|
144
|
+
}
|
|
145
|
+
if (data.hasOwnProperty('state')) {
|
|
146
|
+
obj['state'] = _ApiClient["default"].convertToType(data['state'], _SubmissionState["default"]);
|
|
147
|
+
}
|
|
163
148
|
if (data.hasOwnProperty('test')) {
|
|
164
149
|
obj['test'] = _ApiClient["default"].convertToType(data['test'], 'Boolean');
|
|
165
150
|
}
|
|
166
|
-
if (data.hasOwnProperty('
|
|
167
|
-
obj['
|
|
151
|
+
if (data.hasOwnProperty('editable')) {
|
|
152
|
+
obj['editable'] = _ApiClient["default"].convertToType(data['editable'], 'Boolean');
|
|
168
153
|
}
|
|
169
|
-
if (data.hasOwnProperty('
|
|
170
|
-
obj['
|
|
154
|
+
if (data.hasOwnProperty('data')) {
|
|
155
|
+
obj['data'] = _ApiClient["default"].convertToType(data['data'], {
|
|
156
|
+
'String': Object
|
|
157
|
+
});
|
|
171
158
|
}
|
|
172
|
-
if (data.hasOwnProperty('
|
|
173
|
-
obj['
|
|
159
|
+
if (data.hasOwnProperty('data_errors')) {
|
|
160
|
+
obj['data_errors'] = _ApiClient["default"].convertToType(data['data_errors'], [_ErrorDetail["default"]]);
|
|
174
161
|
}
|
|
175
|
-
if (data.hasOwnProperty('
|
|
176
|
-
obj['
|
|
162
|
+
if (data.hasOwnProperty('error_message')) {
|
|
163
|
+
obj['error_message'] = _ApiClient["default"].convertToType(data['error_message'], 'String');
|
|
177
164
|
}
|
|
178
|
-
if (data.hasOwnProperty('
|
|
179
|
-
obj['
|
|
165
|
+
if (data.hasOwnProperty('metadata')) {
|
|
166
|
+
obj['metadata'] = _ApiClient["default"].convertToType(data['metadata'], {
|
|
167
|
+
'String': Object
|
|
168
|
+
});
|
|
180
169
|
}
|
|
181
|
-
if (data.hasOwnProperty('
|
|
182
|
-
obj['
|
|
170
|
+
if (data.hasOwnProperty('has_password')) {
|
|
171
|
+
obj['has_password'] = _ApiClient["default"].convertToType(data['has_password'], 'Boolean');
|
|
183
172
|
}
|
|
184
|
-
if (data.hasOwnProperty('
|
|
185
|
-
obj['
|
|
173
|
+
if (data.hasOwnProperty('signature_requests')) {
|
|
174
|
+
obj['signature_requests'] = _ApiClient["default"].convertToType(data['signature_requests'], [_SignatureRequest["default"]]);
|
|
186
175
|
}
|
|
187
176
|
if (data.hasOwnProperty('actions')) {
|
|
188
177
|
obj['actions'] = _ApiClient["default"].convertToType(data['actions'], [_SubmissionAction["default"]]);
|
|
189
178
|
}
|
|
190
|
-
if (data.hasOwnProperty('
|
|
191
|
-
obj['
|
|
179
|
+
if (data.hasOwnProperty('truncated_text')) {
|
|
180
|
+
obj['truncated_text'] = _ApiClient["default"].convertToType(data['truncated_text'], {
|
|
181
|
+
'String': ['String']
|
|
182
|
+
});
|
|
192
183
|
}
|
|
193
|
-
if (data.hasOwnProperty('
|
|
194
|
-
obj['
|
|
184
|
+
if (data.hasOwnProperty('output_formats')) {
|
|
185
|
+
obj['output_formats'] = _ApiClient["default"].convertToType(data['output_formats'], [_OutputFormat["default"]]);
|
|
195
186
|
}
|
|
196
|
-
if (data.hasOwnProperty('
|
|
197
|
-
obj['
|
|
187
|
+
if (data.hasOwnProperty('files')) {
|
|
188
|
+
obj['files'] = _ApiClient["default"].convertToType(data['files'], _SubmissionFiles["default"]);
|
|
189
|
+
}
|
|
190
|
+
if (data.hasOwnProperty('preview_generated_at')) {
|
|
191
|
+
obj['preview_generated_at'] = _ApiClient["default"].convertToType(data['preview_generated_at'], 'Date');
|
|
192
|
+
}
|
|
193
|
+
if (data.hasOwnProperty('expired')) {
|
|
194
|
+
obj['expired'] = _ApiClient["default"].convertToType(data['expired'], 'Boolean');
|
|
195
|
+
}
|
|
196
|
+
if (data.hasOwnProperty('expires_at')) {
|
|
197
|
+
obj['expires_at'] = _ApiClient["default"].convertToType(data['expires_at'], 'Date');
|
|
198
|
+
}
|
|
199
|
+
if (data.hasOwnProperty('processed_at')) {
|
|
200
|
+
obj['processed_at'] = _ApiClient["default"].convertToType(data['processed_at'], 'Date');
|
|
201
|
+
}
|
|
202
|
+
if (data.hasOwnProperty('created_at')) {
|
|
203
|
+
obj['created_at'] = _ApiClient["default"].convertToType(data['created_at'], 'Date');
|
|
204
|
+
}
|
|
205
|
+
if (data.hasOwnProperty('updated_at')) {
|
|
206
|
+
obj['updated_at'] = _ApiClient["default"].convertToType(data['updated_at'], 'Date');
|
|
198
207
|
}
|
|
199
208
|
}
|
|
200
209
|
return obj;
|
|
@@ -224,346 +233,194 @@ var Submission = /*#__PURE__*/function () {
|
|
|
224
233
|
} finally {
|
|
225
234
|
_iterator.f();
|
|
226
235
|
}
|
|
227
|
-
if (data['batch_id'] && !(typeof data['batch_id'] === 'string' || data['batch_id'] instanceof String)) {
|
|
228
|
-
throw new Error("Expected the field `batch_id` to be a primitive type in the JSON string but got " + data['batch_id']);
|
|
229
|
-
}
|
|
230
|
-
// ensure the json data is an array
|
|
231
|
-
if (!Array.isArray(data['data_requests'])) {
|
|
232
|
-
throw new Error("Expected the field `data_requests` to be an array in the JSON data but got " + data['data_requests']);
|
|
233
|
-
}
|
|
234
|
-
// ensure the json data is a string
|
|
235
|
-
if (data['error_message'] && !(typeof data['error_message'] === 'string' || data['error_message'] instanceof String)) {
|
|
236
|
-
throw new Error("Expected the field `error_message` to be a primitive type in the JSON string but got " + data['error_message']);
|
|
237
|
-
}
|
|
238
|
-
// ensure the json data is a string
|
|
239
|
-
if (data['expires_at'] && !(typeof data['expires_at'] === 'string' || data['expires_at'] instanceof String)) {
|
|
240
|
-
throw new Error("Expected the field `expires_at` to be a primitive type in the JSON string but got " + data['expires_at']);
|
|
241
|
-
}
|
|
242
|
-
// ensure the json data is a string
|
|
243
236
|
if (data['id'] && !(typeof data['id'] === 'string' || data['id'] instanceof String)) {
|
|
244
237
|
throw new Error("Expected the field `id` to be a primitive type in the JSON string but got " + data['id']);
|
|
245
238
|
}
|
|
246
|
-
// ensure the json data is an array
|
|
247
|
-
if (!Array.isArray(data['json_schema_errors'])) {
|
|
248
|
-
throw new Error("Expected the field `json_schema_errors` to be an array in the JSON data but got " + data['json_schema_errors']);
|
|
249
|
-
}
|
|
250
|
-
// ensure the json data is a string
|
|
251
|
-
if (data['password'] && !(typeof data['password'] === 'string' || data['password'] instanceof String)) {
|
|
252
|
-
throw new Error("Expected the field `password` to be a primitive type in the JSON string but got " + data['password']);
|
|
253
|
-
}
|
|
254
|
-
// ensure the json data is a string
|
|
255
|
-
if (data['processed_at'] && !(typeof data['processed_at'] === 'string' || data['processed_at'] instanceof String)) {
|
|
256
|
-
throw new Error("Expected the field `processed_at` to be a primitive type in the JSON string but got " + data['processed_at']);
|
|
257
|
-
}
|
|
258
|
-
// ensure the json data is a string
|
|
259
|
-
if (data['state'] && !(typeof data['state'] === 'string' || data['state'] instanceof String)) {
|
|
260
|
-
throw new Error("Expected the field `state` to be a primitive type in the JSON string but got " + data['state']);
|
|
261
|
-
}
|
|
262
239
|
// ensure the json data is a string
|
|
263
240
|
if (data['template_id'] && !(typeof data['template_id'] === 'string' || data['template_id'] instanceof String)) {
|
|
264
241
|
throw new Error("Expected the field `template_id` to be a primitive type in the JSON string but got " + data['template_id']);
|
|
265
242
|
}
|
|
266
243
|
// ensure the json data is a string
|
|
267
|
-
if (data['template_type'] && !(typeof data['template_type'] === 'string' || data['template_type'] instanceof String)) {
|
|
268
|
-
throw new Error("Expected the field `template_type` to be a primitive type in the JSON string but got " + data['template_type']);
|
|
269
|
-
}
|
|
270
|
-
// ensure the json data is a string
|
|
271
244
|
if (data['template_version'] && !(typeof data['template_version'] === 'string' || data['template_version'] instanceof String)) {
|
|
272
245
|
throw new Error("Expected the field `template_version` to be a primitive type in the JSON string but got " + data['template_version']);
|
|
273
246
|
}
|
|
274
247
|
// ensure the json data is a string
|
|
275
|
-
if (data['
|
|
276
|
-
throw new Error("Expected the field `
|
|
277
|
-
}
|
|
278
|
-
// ensure the json data is a string
|
|
279
|
-
if (data['download_url'] && !(typeof data['download_url'] === 'string' || data['download_url'] instanceof String)) {
|
|
280
|
-
throw new Error("Expected the field `download_url` to be a primitive type in the JSON string but got " + data['download_url']);
|
|
281
|
-
}
|
|
282
|
-
// ensure the json data is a string
|
|
283
|
-
if (data['permanent_download_url'] && !(typeof data['permanent_download_url'] === 'string' || data['permanent_download_url'] instanceof String)) {
|
|
284
|
-
throw new Error("Expected the field `permanent_download_url` to be a primitive type in the JSON string but got " + data['permanent_download_url']);
|
|
248
|
+
if (data['batch_id'] && !(typeof data['batch_id'] === 'string' || data['batch_id'] instanceof String)) {
|
|
249
|
+
throw new Error("Expected the field `batch_id` to be a primitive type in the JSON string but got " + data['batch_id']);
|
|
285
250
|
}
|
|
286
|
-
// ensure the json data is
|
|
287
|
-
if (
|
|
288
|
-
throw new Error("Expected the field `
|
|
251
|
+
// ensure the json data is an array
|
|
252
|
+
if (!Array.isArray(data['data_errors'])) {
|
|
253
|
+
throw new Error("Expected the field `data_errors` to be an array in the JSON data but got " + data['data_errors']);
|
|
289
254
|
}
|
|
290
255
|
// ensure the json data is a string
|
|
291
|
-
if (data['
|
|
292
|
-
throw new Error("Expected the field `
|
|
256
|
+
if (data['error_message'] && !(typeof data['error_message'] === 'string' || data['error_message'] instanceof String)) {
|
|
257
|
+
throw new Error("Expected the field `error_message` to be a primitive type in the JSON string but got " + data['error_message']);
|
|
293
258
|
}
|
|
294
|
-
// ensure the json data is
|
|
295
|
-
if (
|
|
296
|
-
throw new Error("Expected the field `
|
|
259
|
+
// ensure the json data is an array
|
|
260
|
+
if (!Array.isArray(data['signature_requests'])) {
|
|
261
|
+
throw new Error("Expected the field `signature_requests` to be an array in the JSON data but got " + data['signature_requests']);
|
|
297
262
|
}
|
|
298
263
|
// ensure the json data is an array
|
|
299
264
|
if (!Array.isArray(data['actions'])) {
|
|
300
265
|
throw new Error("Expected the field `actions` to be an array in the JSON data but got " + data['actions']);
|
|
301
266
|
}
|
|
302
|
-
// ensure the json data is
|
|
303
|
-
if (
|
|
304
|
-
throw new Error("Expected the field `
|
|
305
|
-
}
|
|
306
|
-
// ensure the json data is a string
|
|
307
|
-
if (data['referrer'] && !(typeof data['referrer'] === 'string' || data['referrer'] instanceof String)) {
|
|
308
|
-
throw new Error("Expected the field `referrer` to be a primitive type in the JSON string but got " + data['referrer']);
|
|
267
|
+
// ensure the json data is an array
|
|
268
|
+
if (!Array.isArray(data['output_formats'])) {
|
|
269
|
+
throw new Error("Expected the field `output_formats` to be an array in the JSON data but got " + data['output_formats']);
|
|
309
270
|
}
|
|
310
271
|
return true;
|
|
311
272
|
}
|
|
312
273
|
}]);
|
|
313
274
|
}();
|
|
314
|
-
Submission.RequiredProperties = ["
|
|
275
|
+
Submission.RequiredProperties = ["id", "template_id", "template_type", "template_version", "batch_id", "source", "state", "test", "editable", "data", "data_errors", "error_message", "metadata", "has_password", "signature_requests", "actions", "truncated_text", "output_formats", "files", "preview_generated_at", "expired", "expires_at", "processed_at", "created_at", "updated_at"];
|
|
315
276
|
|
|
316
277
|
/**
|
|
317
|
-
*
|
|
278
|
+
* The submission's ID.
|
|
279
|
+
* @member {String} id
|
|
318
280
|
*/
|
|
319
|
-
Submission.prototype['
|
|
281
|
+
Submission.prototype['id'] = undefined;
|
|
320
282
|
|
|
321
283
|
/**
|
|
322
|
-
*
|
|
284
|
+
* Null once the template has been permanently deleted.
|
|
285
|
+
* @member {String} template_id
|
|
323
286
|
*/
|
|
324
|
-
Submission.prototype['
|
|
287
|
+
Submission.prototype['template_id'] = undefined;
|
|
325
288
|
|
|
326
289
|
/**
|
|
327
|
-
*
|
|
290
|
+
* The template's type: `pdf` or `html`.
|
|
291
|
+
* @member {module:model/TemplateType} template_type
|
|
328
292
|
*/
|
|
329
|
-
Submission.prototype['
|
|
293
|
+
Submission.prototype['template_type'] = undefined;
|
|
330
294
|
|
|
331
295
|
/**
|
|
332
|
-
*
|
|
296
|
+
* The published version of the template the submission used. Null for the draft.
|
|
297
|
+
* @member {String} template_version
|
|
333
298
|
*/
|
|
334
|
-
Submission.prototype['
|
|
299
|
+
Submission.prototype['template_version'] = undefined;
|
|
335
300
|
|
|
336
301
|
/**
|
|
337
|
-
*
|
|
302
|
+
* The ID of the batch the submission was created in.
|
|
303
|
+
* @member {String} batch_id
|
|
338
304
|
*/
|
|
339
|
-
Submission.prototype['
|
|
305
|
+
Submission.prototype['batch_id'] = undefined;
|
|
340
306
|
|
|
341
307
|
/**
|
|
342
|
-
*
|
|
308
|
+
* `api`: created with the API. `web`: a web form. `reprocess`: a copy of another submission, made to generate its PDF again.
|
|
309
|
+
* @member {module:model/SubmissionSource} source
|
|
343
310
|
*/
|
|
344
|
-
Submission.prototype['
|
|
311
|
+
Submission.prototype['source'] = undefined;
|
|
345
312
|
|
|
346
313
|
/**
|
|
347
|
-
*
|
|
314
|
+
* `pending` until the PDF has been generated, then `processed`. `waiting_for_signature_requests` until every signature request is completed. `insufficient_credits`: waiting for credits; `error_message` says whether the PDF is generated once you add them. `account_suspended`: waiting for the account to be reactivated, for up to 30 days. Waiting ends in `error` if it's discarded or takes over 30 days. Every other state is final, with no PDF: `invalid_data` (the data doesn't match the template's fields: see `data_errors`), `declined` (a signature request was declined), and the states where generating the PDF failed, which have an `error_message`: `syntax_error` (a mistake in an HTML template's Liquid or SCSS), `image_download_failed` or `image_processing_failed` (an image in the data or the template couldn't be downloaded or read) and `error` (anything else). Older submissions can also be `license_revoked` or `accidental`.
|
|
315
|
+
* @member {module:model/SubmissionState} state
|
|
348
316
|
*/
|
|
349
|
-
Submission.prototype['
|
|
317
|
+
Submission.prototype['state'] = undefined;
|
|
350
318
|
|
|
351
319
|
/**
|
|
352
|
-
*
|
|
320
|
+
* Test PDFs have a watermark and are free. Live PDFs use credits. Submissions made with a test API token are always test submissions.
|
|
321
|
+
* @member {Boolean} test
|
|
353
322
|
*/
|
|
354
|
-
Submission.prototype['
|
|
323
|
+
Submission.prototype['test'] = undefined;
|
|
355
324
|
|
|
356
325
|
/**
|
|
357
|
-
*
|
|
326
|
+
* `true` keeps the PDF's text and check fields fillable, and `false` flattens every field. Left out, the template decides: its `editable_submissions` setting, or each field's own Editable option. A response shows the template's setting when the request left this out. Can't be `true` with `signature_requests`.
|
|
327
|
+
* @member {Boolean} editable
|
|
358
328
|
*/
|
|
359
|
-
Submission.prototype['
|
|
329
|
+
Submission.prototype['editable'] = undefined;
|
|
360
330
|
|
|
361
331
|
/**
|
|
362
|
-
*
|
|
332
|
+
* The submission's data, with the values entered in completed signature requests. Lists leave it out (null) unless you pass `include_data=true`. Empty once the submission has expired.
|
|
333
|
+
* @member {Object.<String, Object>} data
|
|
363
334
|
*/
|
|
364
|
-
Submission.prototype['
|
|
335
|
+
Submission.prototype['data'] = undefined;
|
|
365
336
|
|
|
366
337
|
/**
|
|
367
|
-
*
|
|
338
|
+
* Why the data doesn't match the template's fields, when `state` is `invalid_data`: the same details as the 422 response that recorded it, with pointers into the request that created the submission (`/data/name`). Cleared once the submission has expired.
|
|
339
|
+
* @member {Array.<module:model/ErrorDetail>} data_errors
|
|
368
340
|
*/
|
|
369
|
-
Submission.prototype['
|
|
341
|
+
Submission.prototype['data_errors'] = undefined;
|
|
370
342
|
|
|
371
343
|
/**
|
|
372
|
-
*
|
|
344
|
+
* Why the PDF couldn't be generated, when `state` is `error`.
|
|
345
|
+
* @member {String} error_message
|
|
373
346
|
*/
|
|
374
|
-
Submission.prototype['
|
|
347
|
+
Submission.prototype['error_message'] = undefined;
|
|
375
348
|
|
|
376
349
|
/**
|
|
377
|
-
*
|
|
350
|
+
* Your own data about the submission, such as an ID from your app. It isn't printed on the PDF.
|
|
351
|
+
* @member {Object.<String, Object>} metadata
|
|
378
352
|
*/
|
|
379
|
-
Submission.prototype['
|
|
353
|
+
Submission.prototype['metadata'] = undefined;
|
|
380
354
|
|
|
381
355
|
/**
|
|
382
|
-
*
|
|
356
|
+
* Whether the PDF needs a password to open (`password`).
|
|
357
|
+
* @member {Boolean} has_password
|
|
383
358
|
*/
|
|
384
|
-
Submission.prototype['
|
|
359
|
+
Submission.prototype['has_password'] = undefined;
|
|
385
360
|
|
|
386
361
|
/**
|
|
387
|
-
*
|
|
362
|
+
* The people asked to sign the submission (and fill in their fields), in order.
|
|
363
|
+
* @member {Array.<module:model/SignatureRequest>} signature_requests
|
|
388
364
|
*/
|
|
389
|
-
Submission.prototype['
|
|
365
|
+
Submission.prototype['signature_requests'] = undefined;
|
|
390
366
|
|
|
391
367
|
/**
|
|
392
|
-
*
|
|
368
|
+
* The uploads of the submission's PDF to your storage (account integrations).
|
|
369
|
+
* @member {Array.<module:model/SubmissionAction>} actions
|
|
393
370
|
*/
|
|
394
|
-
Submission.prototype['
|
|
371
|
+
Submission.prototype['actions'] = undefined;
|
|
395
372
|
|
|
396
373
|
/**
|
|
397
|
-
*
|
|
374
|
+
* The text of each field that didn't fit in it, by field name. Left out (null) with `data`, and empty once the submission has expired.
|
|
375
|
+
* @member {Object.<String, Array.<String>>} truncated_text
|
|
398
376
|
*/
|
|
399
377
|
Submission.prototype['truncated_text'] = undefined;
|
|
400
378
|
|
|
401
379
|
/**
|
|
402
|
-
*
|
|
403
|
-
|
|
404
|
-
Submission.prototype['pdf_hash'] = undefined;
|
|
405
|
-
|
|
406
|
-
/**
|
|
407
|
-
* @member {String} download_url
|
|
380
|
+
* What the submission makes: `pdf`, and `png` (an image of each page of the PDF, up to 100 pages) when you ask for it. Default `["pdf"]`. POST /submissions/{submission_id}/generate_files adds `png` to a processed submission.
|
|
381
|
+
* @member {Array.<module:model/OutputFormat>} output_formats
|
|
408
382
|
*/
|
|
409
|
-
Submission.prototype['
|
|
383
|
+
Submission.prototype['output_formats'] = undefined;
|
|
410
384
|
|
|
411
385
|
/**
|
|
412
|
-
*
|
|
386
|
+
* The generated files: `pdf` once the submission has been processed, `png` (the images of the PDF's pages, when `output_formats` has it: `files.png.pages[0]` is page 1), `audit_trail` once its signature requests are completed, and `preview` once a preview PDF has been generated. Empty once the submission has expired.
|
|
387
|
+
* @member {module:model/SubmissionFiles} files
|
|
413
388
|
*/
|
|
414
|
-
Submission.prototype['
|
|
389
|
+
Submission.prototype['files'] = undefined;
|
|
415
390
|
|
|
416
391
|
/**
|
|
417
|
-
*
|
|
418
|
-
|
|
419
|
-
Submission.prototype['preview_download_url'] = undefined;
|
|
420
|
-
|
|
421
|
-
/**
|
|
422
|
-
* @member {String} preview_generated_at
|
|
392
|
+
* When the preview PDF was generated. Null if there is no preview.
|
|
393
|
+
* @member {Date} preview_generated_at
|
|
423
394
|
*/
|
|
424
395
|
Submission.prototype['preview_generated_at'] = undefined;
|
|
425
396
|
|
|
426
397
|
/**
|
|
427
|
-
*
|
|
428
|
-
|
|
429
|
-
Submission.prototype['audit_trail_download_url'] = undefined;
|
|
430
|
-
|
|
431
|
-
/**
|
|
432
|
-
* @member {Array.<module:model/SubmissionAction>} actions
|
|
433
|
-
*/
|
|
434
|
-
Submission.prototype['actions'] = undefined;
|
|
435
|
-
|
|
436
|
-
/**
|
|
437
|
-
* @member {module:model/Submission.SourceEnum} source
|
|
438
|
-
*/
|
|
439
|
-
Submission.prototype['source'] = undefined;
|
|
440
|
-
|
|
441
|
-
/**
|
|
442
|
-
* @member {String} referrer
|
|
398
|
+
* An expired submission's data, metadata, password and PDF have been deleted.
|
|
399
|
+
* @member {Boolean} expired
|
|
443
400
|
*/
|
|
444
|
-
Submission.prototype['
|
|
401
|
+
Submission.prototype['expired'] = undefined;
|
|
445
402
|
|
|
446
403
|
/**
|
|
447
|
-
*
|
|
404
|
+
* When the submission expires. Null if it's kept until you delete it.
|
|
405
|
+
* @member {Date} expires_at
|
|
448
406
|
*/
|
|
449
|
-
Submission.prototype['
|
|
407
|
+
Submission.prototype['expires_at'] = undefined;
|
|
450
408
|
|
|
451
409
|
/**
|
|
452
|
-
*
|
|
453
|
-
* @
|
|
454
|
-
* @readonly
|
|
410
|
+
* When the PDF was generated. Null until then.
|
|
411
|
+
* @member {Date} processed_at
|
|
455
412
|
*/
|
|
456
|
-
Submission['
|
|
457
|
-
/**
|
|
458
|
-
* value: "pending"
|
|
459
|
-
* @const
|
|
460
|
-
*/
|
|
461
|
-
"pending": "pending",
|
|
462
|
-
/**
|
|
463
|
-
* value: "processed"
|
|
464
|
-
* @const
|
|
465
|
-
*/
|
|
466
|
-
"processed": "processed",
|
|
467
|
-
/**
|
|
468
|
-
* value: "invalid_data"
|
|
469
|
-
* @const
|
|
470
|
-
*/
|
|
471
|
-
"invalid_data": "invalid_data",
|
|
472
|
-
/**
|
|
473
|
-
* value: "error"
|
|
474
|
-
* @const
|
|
475
|
-
*/
|
|
476
|
-
"error": "error",
|
|
477
|
-
/**
|
|
478
|
-
* value: "image_download_failed"
|
|
479
|
-
* @const
|
|
480
|
-
*/
|
|
481
|
-
"image_download_failed": "image_download_failed",
|
|
482
|
-
/**
|
|
483
|
-
* value: "image_processing_failed"
|
|
484
|
-
* @const
|
|
485
|
-
*/
|
|
486
|
-
"image_processing_failed": "image_processing_failed",
|
|
487
|
-
/**
|
|
488
|
-
* value: "waiting_for_data_requests"
|
|
489
|
-
* @const
|
|
490
|
-
*/
|
|
491
|
-
"waiting_for_data_requests": "waiting_for_data_requests",
|
|
492
|
-
/**
|
|
493
|
-
* value: "syntax_error"
|
|
494
|
-
* @const
|
|
495
|
-
*/
|
|
496
|
-
"syntax_error": "syntax_error",
|
|
497
|
-
/**
|
|
498
|
-
* value: "insufficient_credits"
|
|
499
|
-
* @const
|
|
500
|
-
*/
|
|
501
|
-
"insufficient_credits": "insufficient_credits",
|
|
502
|
-
/**
|
|
503
|
-
* value: "account_suspended"
|
|
504
|
-
* @const
|
|
505
|
-
*/
|
|
506
|
-
"account_suspended": "account_suspended",
|
|
507
|
-
/**
|
|
508
|
-
* value: "license_revoked"
|
|
509
|
-
* @const
|
|
510
|
-
*/
|
|
511
|
-
"license_revoked": "license_revoked",
|
|
512
|
-
/**
|
|
513
|
-
* value: "accidental"
|
|
514
|
-
* @const
|
|
515
|
-
*/
|
|
516
|
-
"accidental": "accidental",
|
|
517
|
-
/**
|
|
518
|
-
* value: "declined"
|
|
519
|
-
* @const
|
|
520
|
-
*/
|
|
521
|
-
"declined": "declined"
|
|
522
|
-
};
|
|
413
|
+
Submission.prototype['processed_at'] = undefined;
|
|
523
414
|
|
|
524
415
|
/**
|
|
525
|
-
*
|
|
526
|
-
* @
|
|
527
|
-
* @readonly
|
|
416
|
+
* When the submission was created.
|
|
417
|
+
* @member {Date} created_at
|
|
528
418
|
*/
|
|
529
|
-
Submission['
|
|
530
|
-
/**
|
|
531
|
-
* value: "pdf"
|
|
532
|
-
* @const
|
|
533
|
-
*/
|
|
534
|
-
"pdf": "pdf",
|
|
535
|
-
/**
|
|
536
|
-
* value: "html"
|
|
537
|
-
* @const
|
|
538
|
-
*/
|
|
539
|
-
"html": "html"
|
|
540
|
-
};
|
|
419
|
+
Submission.prototype['created_at'] = undefined;
|
|
541
420
|
|
|
542
421
|
/**
|
|
543
|
-
*
|
|
544
|
-
* @
|
|
545
|
-
* @readonly
|
|
422
|
+
* When the submission was last updated.
|
|
423
|
+
* @member {Date} updated_at
|
|
546
424
|
*/
|
|
547
|
-
Submission['
|
|
548
|
-
/**
|
|
549
|
-
* value: "api"
|
|
550
|
-
* @const
|
|
551
|
-
*/
|
|
552
|
-
"api": "api",
|
|
553
|
-
/**
|
|
554
|
-
* value: "web"
|
|
555
|
-
* @const
|
|
556
|
-
*/
|
|
557
|
-
"web": "web",
|
|
558
|
-
/**
|
|
559
|
-
* value: "reprocess"
|
|
560
|
-
* @const
|
|
561
|
-
*/
|
|
562
|
-
"reprocess": "reprocess",
|
|
563
|
-
/**
|
|
564
|
-
* value: "webhook"
|
|
565
|
-
* @const
|
|
566
|
-
*/
|
|
567
|
-
"webhook": "webhook"
|
|
568
|
-
};
|
|
425
|
+
Submission.prototype['updated_at'] = undefined;
|
|
569
426
|
var _default = exports["default"] = Submission;
|