docspring 3.3.0 → 4.0.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 +65 -63
- package/dist/ApiClient.js +63 -28
- package/dist/RequestSchemas.js +2297 -0
- package/dist/RequestValidator.js +494 -0
- package/dist/api/Client.js +1346 -948
- package/dist/index.js +651 -154
- 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/{TemplateDeleteResponse.js → CreateSignatureRequestEventRequest.js} +49 -74
- package/dist/model/CreateSignatureRequestTokenRequest.js +88 -0
- package/dist/model/{SubmissionBatchData.js → CreateSubmissionBatchRequest.js} +67 -42
- package/dist/model/CreateSubmissionRequest.js +212 -0
- package/dist/model/CreateTemplateRequest.js +545 -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/FieldComparisonCondition.js +137 -0
- package/dist/model/FieldComparisonOperator.js +69 -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/{SuccessMultipleErrorsResponse.js → FieldInCondition.js} +54 -53
- 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/Folder.js +38 -11
- package/dist/model/FolderList.js +132 -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/PageFormat.js +114 -0
- package/dist/model/{PublishVersionData.js → PublishTemplateVersionRequest.js} +33 -33
- package/dist/model/{RenameFolderData.js → RenameFolderRequest.js} +25 -23
- 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 +186 -345
- 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 +108 -0
- package/dist/model/SubmissionInput.js +204 -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/Template.js +310 -573
- 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/TemplateDocument.js +280 -0
- package/dist/model/TemplateDocumentState.js +74 -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/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/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 +136 -0
- package/dist/model/UpdateTemplateRequest.js +450 -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/{AddFieldsData.js → UrlSourcePdf.js} +49 -31
- 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/CreateCustomFileResponse.js +0 -167
- package/dist/model/CreateHtmlTemplate.js +0 -108
- package/dist/model/CreatePdfTemplate.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
|
@@ -0,0 +1,154 @@
|
|
|
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
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
|
|
9
|
+
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); }
|
|
10
|
+
function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
|
|
11
|
+
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); } }
|
|
12
|
+
function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
|
|
13
|
+
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
14
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
15
|
+
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); } /**
|
|
16
|
+
* DocSpring API
|
|
17
|
+
* Use DocSpring's API to programmatically fill out PDF forms, convert HTML to PDFs, merge PDFs, or request legally binding e-signatures.
|
|
18
|
+
*
|
|
19
|
+
* The version of the OpenAPI document: v2
|
|
20
|
+
*
|
|
21
|
+
*
|
|
22
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
23
|
+
* https://openapi-generator.tech
|
|
24
|
+
* Do not edit the class manually.
|
|
25
|
+
*
|
|
26
|
+
*/
|
|
27
|
+
/**
|
|
28
|
+
* Enum class ErrorCode.
|
|
29
|
+
* @enum {}
|
|
30
|
+
* @readonly
|
|
31
|
+
*/
|
|
32
|
+
var ErrorCode = exports["default"] = /*#__PURE__*/function () {
|
|
33
|
+
function ErrorCode() {
|
|
34
|
+
_classCallCheck(this, ErrorCode);
|
|
35
|
+
}
|
|
36
|
+
return _createClass(ErrorCode, null, [{
|
|
37
|
+
key: "constructFromObject",
|
|
38
|
+
value:
|
|
39
|
+
/**
|
|
40
|
+
* Returns a <code>ErrorCode</code> enum value from a Javascript object name.
|
|
41
|
+
* @param {Object} data The plain JavaScript object containing the name of the enum value.
|
|
42
|
+
* @return {module:model/ErrorCode} The enum <code>ErrorCode</code> value.
|
|
43
|
+
*/
|
|
44
|
+
function constructFromObject(object) {
|
|
45
|
+
// Any value, including one added to the API after this client was released
|
|
46
|
+
return object;
|
|
47
|
+
}
|
|
48
|
+
}]);
|
|
49
|
+
}();
|
|
50
|
+
/**
|
|
51
|
+
* value: "invalid_request"
|
|
52
|
+
* @const
|
|
53
|
+
*/
|
|
54
|
+
_defineProperty(ErrorCode, "invalid_request", "invalid_request");
|
|
55
|
+
/**
|
|
56
|
+
* value: "unauthorized"
|
|
57
|
+
* @const
|
|
58
|
+
*/
|
|
59
|
+
_defineProperty(ErrorCode, "unauthorized", "unauthorized");
|
|
60
|
+
/**
|
|
61
|
+
* value: "payment_required"
|
|
62
|
+
* @const
|
|
63
|
+
*/
|
|
64
|
+
_defineProperty(ErrorCode, "payment_required", "payment_required");
|
|
65
|
+
/**
|
|
66
|
+
* value: "insufficient_credits"
|
|
67
|
+
* @const
|
|
68
|
+
*/
|
|
69
|
+
_defineProperty(ErrorCode, "insufficient_credits", "insufficient_credits");
|
|
70
|
+
/**
|
|
71
|
+
* value: "forbidden"
|
|
72
|
+
* @const
|
|
73
|
+
*/
|
|
74
|
+
_defineProperty(ErrorCode, "forbidden", "forbidden");
|
|
75
|
+
/**
|
|
76
|
+
* value: "upgrade_required"
|
|
77
|
+
* @const
|
|
78
|
+
*/
|
|
79
|
+
_defineProperty(ErrorCode, "upgrade_required", "upgrade_required");
|
|
80
|
+
/**
|
|
81
|
+
* value: "account_suspended"
|
|
82
|
+
* @const
|
|
83
|
+
*/
|
|
84
|
+
_defineProperty(ErrorCode, "account_suspended", "account_suspended");
|
|
85
|
+
/**
|
|
86
|
+
* value: "not_found"
|
|
87
|
+
* @const
|
|
88
|
+
*/
|
|
89
|
+
_defineProperty(ErrorCode, "not_found", "not_found");
|
|
90
|
+
/**
|
|
91
|
+
* value: "method_not_allowed"
|
|
92
|
+
* @const
|
|
93
|
+
*/
|
|
94
|
+
_defineProperty(ErrorCode, "method_not_allowed", "method_not_allowed");
|
|
95
|
+
/**
|
|
96
|
+
* value: "conflict"
|
|
97
|
+
* @const
|
|
98
|
+
*/
|
|
99
|
+
_defineProperty(ErrorCode, "conflict", "conflict");
|
|
100
|
+
/**
|
|
101
|
+
* value: "gone"
|
|
102
|
+
* @const
|
|
103
|
+
*/
|
|
104
|
+
_defineProperty(ErrorCode, "gone", "gone");
|
|
105
|
+
/**
|
|
106
|
+
* value: "request_too_large"
|
|
107
|
+
* @const
|
|
108
|
+
*/
|
|
109
|
+
_defineProperty(ErrorCode, "request_too_large", "request_too_large");
|
|
110
|
+
/**
|
|
111
|
+
* value: "unsupported_media_type"
|
|
112
|
+
* @const
|
|
113
|
+
*/
|
|
114
|
+
_defineProperty(ErrorCode, "unsupported_media_type", "unsupported_media_type");
|
|
115
|
+
/**
|
|
116
|
+
* value: "validation_failed"
|
|
117
|
+
* @const
|
|
118
|
+
*/
|
|
119
|
+
_defineProperty(ErrorCode, "validation_failed", "validation_failed");
|
|
120
|
+
/**
|
|
121
|
+
* value: "invalid_data"
|
|
122
|
+
* @const
|
|
123
|
+
*/
|
|
124
|
+
_defineProperty(ErrorCode, "invalid_data", "invalid_data");
|
|
125
|
+
/**
|
|
126
|
+
* value: "rate_limited"
|
|
127
|
+
* @const
|
|
128
|
+
*/
|
|
129
|
+
_defineProperty(ErrorCode, "rate_limited", "rate_limited");
|
|
130
|
+
/**
|
|
131
|
+
* value: "internal_error"
|
|
132
|
+
* @const
|
|
133
|
+
*/
|
|
134
|
+
_defineProperty(ErrorCode, "internal_error", "internal_error");
|
|
135
|
+
/**
|
|
136
|
+
* value: "bad_gateway"
|
|
137
|
+
* @const
|
|
138
|
+
*/
|
|
139
|
+
_defineProperty(ErrorCode, "bad_gateway", "bad_gateway");
|
|
140
|
+
/**
|
|
141
|
+
* value: "service_unavailable"
|
|
142
|
+
* @const
|
|
143
|
+
*/
|
|
144
|
+
_defineProperty(ErrorCode, "service_unavailable", "service_unavailable");
|
|
145
|
+
/**
|
|
146
|
+
* value: "upstream_timeout"
|
|
147
|
+
* @const
|
|
148
|
+
*/
|
|
149
|
+
_defineProperty(ErrorCode, "upstream_timeout", "upstream_timeout");
|
|
150
|
+
/**
|
|
151
|
+
* value: "polling_timeout"
|
|
152
|
+
* @const
|
|
153
|
+
*/
|
|
154
|
+
_defineProperty(ErrorCode, "polling_timeout", "polling_timeout");
|
|
@@ -5,7 +5,6 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports["default"] = void 0;
|
|
7
7
|
var _ApiClient = _interopRequireDefault(require("../ApiClient"));
|
|
8
|
-
var _SubmissionPreview = _interopRequireDefault(require("./SubmissionPreview"));
|
|
9
8
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
|
|
10
9
|
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); }
|
|
11
10
|
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; } } }; }
|
|
@@ -17,9 +16,9 @@ function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r),
|
|
|
17
16
|
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
18
17
|
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
18
|
* 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.
|
|
19
|
+
* Use DocSpring's API to programmatically fill out PDF forms, convert HTML to PDFs, merge PDFs, or request legally binding e-signatures.
|
|
21
20
|
*
|
|
22
|
-
* The version of the OpenAPI document:
|
|
21
|
+
* The version of the OpenAPI document: v2
|
|
23
22
|
*
|
|
24
23
|
*
|
|
25
24
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -28,21 +27,22 @@ function _toPrimitive(t, e) { if ("object" != _typeof(t) || !t) return t; var r;
|
|
|
28
27
|
*
|
|
29
28
|
*/
|
|
30
29
|
/**
|
|
31
|
-
* The
|
|
32
|
-
* @module model/
|
|
33
|
-
* @version
|
|
30
|
+
* The ErrorDetail model module.
|
|
31
|
+
* @module model/ErrorDetail
|
|
32
|
+
* @version 4.0.0
|
|
34
33
|
*/
|
|
35
|
-
var
|
|
34
|
+
var ErrorDetail = /*#__PURE__*/function () {
|
|
36
35
|
/**
|
|
37
|
-
* Constructs a new <code>
|
|
38
|
-
*
|
|
36
|
+
* Constructs a new <code>ErrorDetail</code>.
|
|
37
|
+
* One problem with the request, such as a missing or invalid property.
|
|
38
|
+
* @alias module:model/ErrorDetail
|
|
39
39
|
* @extends Object
|
|
40
|
-
* @param
|
|
41
|
-
* @param
|
|
40
|
+
* @param code {String} What's wrong: `required`, `unknown_property`, `type`, `enum`, `format`, a JSON Schema keyword such as `minLength`, or a DocSpring code. New codes can be added.
|
|
41
|
+
* @param message {String} A human-readable explanation of the problem.
|
|
42
42
|
*/
|
|
43
|
-
function
|
|
44
|
-
_classCallCheck(this,
|
|
45
|
-
|
|
43
|
+
function ErrorDetail(code, message) {
|
|
44
|
+
_classCallCheck(this, ErrorDetail);
|
|
45
|
+
ErrorDetail.initialize(this, code, message);
|
|
46
46
|
}
|
|
47
47
|
|
|
48
48
|
/**
|
|
@@ -50,55 +50,55 @@ var CreateSubmissionResponse = /*#__PURE__*/function () {
|
|
|
50
50
|
* This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
|
|
51
51
|
* Only for internal use.
|
|
52
52
|
*/
|
|
53
|
-
return _createClass(
|
|
53
|
+
return _createClass(ErrorDetail, null, [{
|
|
54
54
|
key: "initialize",
|
|
55
|
-
value: function initialize(obj,
|
|
56
|
-
obj['
|
|
57
|
-
obj['
|
|
55
|
+
value: function initialize(obj, code, message) {
|
|
56
|
+
obj['code'] = code;
|
|
57
|
+
obj['message'] = message;
|
|
58
58
|
}
|
|
59
59
|
|
|
60
60
|
/**
|
|
61
|
-
* Constructs a <code>
|
|
61
|
+
* Constructs a <code>ErrorDetail</code> from a plain JavaScript object, optionally creating a new instance.
|
|
62
62
|
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
|
63
63
|
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
|
64
|
-
* @param {module:model/
|
|
65
|
-
* @return {module:model/
|
|
64
|
+
* @param {module:model/ErrorDetail} obj Optional instance to populate.
|
|
65
|
+
* @return {module:model/ErrorDetail} The populated <code>ErrorDetail</code> instance.
|
|
66
66
|
*/
|
|
67
67
|
}, {
|
|
68
68
|
key: "constructFromObject",
|
|
69
69
|
value: function constructFromObject(data, obj) {
|
|
70
70
|
if (data) {
|
|
71
|
-
obj = obj || new
|
|
71
|
+
obj = obj || new ErrorDetail();
|
|
72
72
|
_ApiClient["default"].constructFromObject(data, obj, 'Object');
|
|
73
|
-
if (data.hasOwnProperty('
|
|
74
|
-
obj['
|
|
73
|
+
if (data.hasOwnProperty('code')) {
|
|
74
|
+
obj['code'] = _ApiClient["default"].convertToType(data['code'], 'String');
|
|
75
75
|
}
|
|
76
|
-
if (data.hasOwnProperty('
|
|
77
|
-
obj['
|
|
76
|
+
if (data.hasOwnProperty('message')) {
|
|
77
|
+
obj['message'] = _ApiClient["default"].convertToType(data['message'], 'String');
|
|
78
78
|
}
|
|
79
|
-
if (data.hasOwnProperty('
|
|
80
|
-
obj['
|
|
79
|
+
if (data.hasOwnProperty('pointer')) {
|
|
80
|
+
obj['pointer'] = _ApiClient["default"].convertToType(data['pointer'], 'String');
|
|
81
81
|
}
|
|
82
|
-
if (data.hasOwnProperty('
|
|
83
|
-
obj['
|
|
82
|
+
if (data.hasOwnProperty('parameter')) {
|
|
83
|
+
obj['parameter'] = _ApiClient["default"].convertToType(data['parameter'], 'String');
|
|
84
84
|
}
|
|
85
|
-
if (data.hasOwnProperty('
|
|
86
|
-
obj['
|
|
85
|
+
if (data.hasOwnProperty('submission_id')) {
|
|
86
|
+
obj['submission_id'] = _ApiClient["default"].convertToType(data['submission_id'], 'String');
|
|
87
87
|
}
|
|
88
88
|
}
|
|
89
89
|
return obj;
|
|
90
90
|
}
|
|
91
91
|
|
|
92
92
|
/**
|
|
93
|
-
* Validates the JSON data with respect to <code>
|
|
93
|
+
* Validates the JSON data with respect to <code>ErrorDetail</code>.
|
|
94
94
|
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
|
95
|
-
* @return {boolean} to indicate whether the JSON data is valid with respect to <code>
|
|
95
|
+
* @return {boolean} to indicate whether the JSON data is valid with respect to <code>ErrorDetail</code>.
|
|
96
96
|
*/
|
|
97
97
|
}, {
|
|
98
98
|
key: "validateJSON",
|
|
99
99
|
value: function validateJSON(data) {
|
|
100
100
|
// check to make sure all required properties are present in the JSON string
|
|
101
|
-
var _iterator = _createForOfIteratorHelper(
|
|
101
|
+
var _iterator = _createForOfIteratorHelper(ErrorDetail.RequiredProperties),
|
|
102
102
|
_step;
|
|
103
103
|
try {
|
|
104
104
|
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
@@ -113,68 +113,58 @@ var CreateSubmissionResponse = /*#__PURE__*/function () {
|
|
|
113
113
|
} finally {
|
|
114
114
|
_iterator.f();
|
|
115
115
|
}
|
|
116
|
-
if (data['
|
|
117
|
-
throw new Error("Expected the field `
|
|
116
|
+
if (data['code'] && !(typeof data['code'] === 'string' || data['code'] instanceof String)) {
|
|
117
|
+
throw new Error("Expected the field `code` to be a primitive type in the JSON string but got " + data['code']);
|
|
118
118
|
}
|
|
119
119
|
// ensure the json data is a string
|
|
120
|
-
if (data['
|
|
121
|
-
throw new Error("Expected the field `
|
|
120
|
+
if (data['message'] && !(typeof data['message'] === 'string' || data['message'] instanceof String)) {
|
|
121
|
+
throw new Error("Expected the field `message` to be a primitive type in the JSON string but got " + data['message']);
|
|
122
122
|
}
|
|
123
|
-
// ensure the json data is
|
|
124
|
-
if (!
|
|
125
|
-
throw new Error("Expected the field `
|
|
123
|
+
// ensure the json data is a string
|
|
124
|
+
if (data['pointer'] && !(typeof data['pointer'] === 'string' || data['pointer'] instanceof String)) {
|
|
125
|
+
throw new Error("Expected the field `pointer` to be a primitive type in the JSON string but got " + data['pointer']);
|
|
126
126
|
}
|
|
127
127
|
// ensure the json data is a string
|
|
128
|
-
if (data['
|
|
129
|
-
throw new Error("Expected the field `
|
|
128
|
+
if (data['parameter'] && !(typeof data['parameter'] === 'string' || data['parameter'] instanceof String)) {
|
|
129
|
+
throw new Error("Expected the field `parameter` to be a primitive type in the JSON string but got " + data['parameter']);
|
|
130
|
+
}
|
|
131
|
+
// ensure the json data is a string
|
|
132
|
+
if (data['submission_id'] && !(typeof data['submission_id'] === 'string' || data['submission_id'] instanceof String)) {
|
|
133
|
+
throw new Error("Expected the field `submission_id` to be a primitive type in the JSON string but got " + data['submission_id']);
|
|
130
134
|
}
|
|
131
135
|
return true;
|
|
132
136
|
}
|
|
133
137
|
}]);
|
|
134
138
|
}();
|
|
135
|
-
|
|
139
|
+
ErrorDetail.RequiredProperties = ["code", "message"];
|
|
136
140
|
|
|
137
141
|
/**
|
|
138
|
-
*
|
|
139
|
-
|
|
140
|
-
CreateSubmissionResponse.prototype['status'] = undefined;
|
|
141
|
-
|
|
142
|
-
/**
|
|
143
|
-
* @member {module:model/SubmissionPreview} submission
|
|
142
|
+
* What's wrong: `required`, `unknown_property`, `type`, `enum`, `format`, a JSON Schema keyword such as `minLength`, or a DocSpring code. New codes can be added.
|
|
143
|
+
* @member {String} code
|
|
144
144
|
*/
|
|
145
|
-
|
|
145
|
+
ErrorDetail.prototype['code'] = undefined;
|
|
146
146
|
|
|
147
147
|
/**
|
|
148
|
-
*
|
|
148
|
+
* A human-readable explanation of the problem.
|
|
149
|
+
* @member {String} message
|
|
149
150
|
*/
|
|
150
|
-
|
|
151
|
+
ErrorDetail.prototype['message'] = undefined;
|
|
151
152
|
|
|
152
153
|
/**
|
|
153
|
-
*
|
|
154
|
+
* A JSON pointer to the value in the request body (RFC 6901). An empty string means the whole body. In a submission's `data_errors`, it points into the request that created the submission.
|
|
155
|
+
* @member {String} pointer
|
|
154
156
|
*/
|
|
155
|
-
|
|
157
|
+
ErrorDetail.prototype['pointer'] = undefined;
|
|
156
158
|
|
|
157
159
|
/**
|
|
158
|
-
*
|
|
159
|
-
* @member {String}
|
|
160
|
+
* The query parameter the detail is about.
|
|
161
|
+
* @member {String} parameter
|
|
160
162
|
*/
|
|
161
|
-
|
|
163
|
+
ErrorDetail.prototype['parameter'] = undefined;
|
|
162
164
|
|
|
163
165
|
/**
|
|
164
|
-
*
|
|
165
|
-
* @
|
|
166
|
-
* @readonly
|
|
166
|
+
* For a batch item that failed validation, the ID of the submission recorded for it.
|
|
167
|
+
* @member {String} submission_id
|
|
167
168
|
*/
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
* value: "success"
|
|
171
|
-
* @const
|
|
172
|
-
*/
|
|
173
|
-
"success": "success",
|
|
174
|
-
/**
|
|
175
|
-
* value: "error"
|
|
176
|
-
* @const
|
|
177
|
-
*/
|
|
178
|
-
"error": "error"
|
|
179
|
-
};
|
|
180
|
-
var _default = exports["default"] = CreateSubmissionResponse;
|
|
169
|
+
ErrorDetail.prototype['submission_id'] = undefined;
|
|
170
|
+
var _default = exports["default"] = ErrorDetail;
|
|
@@ -0,0 +1,211 @@
|
|
|
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 _ErrorCode = _interopRequireDefault(require("./ErrorCode"));
|
|
9
|
+
var _ErrorDetail = _interopRequireDefault(require("./ErrorDetail"));
|
|
10
|
+
function _interopRequireDefault(e) { return e && e.__esModule ? e : { "default": e }; }
|
|
11
|
+
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
|
+
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; } } }; }
|
|
13
|
+
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
14
|
+
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
15
|
+
function _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function"); }
|
|
16
|
+
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); } }
|
|
17
|
+
function _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", { writable: !1 }), e; }
|
|
18
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
19
|
+
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
|
+
* 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.
|
|
22
|
+
*
|
|
23
|
+
* The version of the OpenAPI document: v2
|
|
24
|
+
*
|
|
25
|
+
*
|
|
26
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
27
|
+
* https://openapi-generator.tech
|
|
28
|
+
* Do not edit the class manually.
|
|
29
|
+
*
|
|
30
|
+
*/
|
|
31
|
+
/**
|
|
32
|
+
* The ErrorInfo model module.
|
|
33
|
+
* @module model/ErrorInfo
|
|
34
|
+
* @version 4.0.0
|
|
35
|
+
*/
|
|
36
|
+
var ErrorInfo = /*#__PURE__*/function () {
|
|
37
|
+
/**
|
|
38
|
+
* Constructs a new <code>ErrorInfo</code>.
|
|
39
|
+
* What went wrong.
|
|
40
|
+
* @alias module:model/ErrorInfo
|
|
41
|
+
* @extends Object
|
|
42
|
+
* @param code {module:model/ErrorCode} A machine-readable error code. Clients should handle codes they don't know: new codes can be added. `invalid_data`: a submission's data doesn't match its template's fields. The submission is still recorded. `insufficient_credits` (402): your credit balance can't cover a live PDF. The record was saved and waits for credits in the `insufficient_credits` state: its ID is in `submission_id`, `submission_batch_id` or `combined_pdf_id`. `upgrade_required` (403): your plan doesn't include this, such as more templates or the embedded template editor. `account_suspended` (403): the account is suspended, so it can't create submissions. `polling_timeout`: on a sync.api host, the PDF wasn't ready in time. The record was created and is still being processed: its ID is in `submission_id`, `submission_batch_id`, `combined_pdf_id` or `template_id`. Without one of these IDs, the request itself got no answer in time, and the record may or may not have been created.
|
|
43
|
+
* @param message {String} A human-readable explanation, safe to show to developers.
|
|
44
|
+
* @param details {Array.<module:model/ErrorDetail>} What was wrong with each part of the request. Empty when the error isn't about one part of it.
|
|
45
|
+
* @param request_id {String} The ID of the request. Include it when you contact support.
|
|
46
|
+
*/
|
|
47
|
+
function ErrorInfo(code, message, details, request_id) {
|
|
48
|
+
_classCallCheck(this, ErrorInfo);
|
|
49
|
+
ErrorInfo.initialize(this, code, message, details, request_id);
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
/**
|
|
53
|
+
* Initializes the fields of this object.
|
|
54
|
+
* This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
|
|
55
|
+
* Only for internal use.
|
|
56
|
+
*/
|
|
57
|
+
return _createClass(ErrorInfo, null, [{
|
|
58
|
+
key: "initialize",
|
|
59
|
+
value: function initialize(obj, code, message, details, request_id) {
|
|
60
|
+
obj['code'] = code;
|
|
61
|
+
obj['message'] = message;
|
|
62
|
+
obj['details'] = details;
|
|
63
|
+
obj['request_id'] = request_id;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
/**
|
|
67
|
+
* Constructs a <code>ErrorInfo</code> from a plain JavaScript object, optionally creating a new instance.
|
|
68
|
+
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
|
69
|
+
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
|
70
|
+
* @param {module:model/ErrorInfo} obj Optional instance to populate.
|
|
71
|
+
* @return {module:model/ErrorInfo} The populated <code>ErrorInfo</code> instance.
|
|
72
|
+
*/
|
|
73
|
+
}, {
|
|
74
|
+
key: "constructFromObject",
|
|
75
|
+
value: function constructFromObject(data, obj) {
|
|
76
|
+
if (data) {
|
|
77
|
+
obj = obj || new ErrorInfo();
|
|
78
|
+
_ApiClient["default"].constructFromObject(data, obj, 'Object');
|
|
79
|
+
if (data.hasOwnProperty('code')) {
|
|
80
|
+
obj['code'] = _ApiClient["default"].convertToType(data['code'], _ErrorCode["default"]);
|
|
81
|
+
}
|
|
82
|
+
if (data.hasOwnProperty('message')) {
|
|
83
|
+
obj['message'] = _ApiClient["default"].convertToType(data['message'], 'String');
|
|
84
|
+
}
|
|
85
|
+
if (data.hasOwnProperty('details')) {
|
|
86
|
+
obj['details'] = _ApiClient["default"].convertToType(data['details'], [_ErrorDetail["default"]]);
|
|
87
|
+
}
|
|
88
|
+
if (data.hasOwnProperty('request_id')) {
|
|
89
|
+
obj['request_id'] = _ApiClient["default"].convertToType(data['request_id'], 'String');
|
|
90
|
+
}
|
|
91
|
+
if (data.hasOwnProperty('submission_id')) {
|
|
92
|
+
obj['submission_id'] = _ApiClient["default"].convertToType(data['submission_id'], 'String');
|
|
93
|
+
}
|
|
94
|
+
if (data.hasOwnProperty('submission_batch_id')) {
|
|
95
|
+
obj['submission_batch_id'] = _ApiClient["default"].convertToType(data['submission_batch_id'], 'String');
|
|
96
|
+
}
|
|
97
|
+
if (data.hasOwnProperty('combined_pdf_id')) {
|
|
98
|
+
obj['combined_pdf_id'] = _ApiClient["default"].convertToType(data['combined_pdf_id'], 'String');
|
|
99
|
+
}
|
|
100
|
+
if (data.hasOwnProperty('template_id')) {
|
|
101
|
+
obj['template_id'] = _ApiClient["default"].convertToType(data['template_id'], 'String');
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
return obj;
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
/**
|
|
108
|
+
* Validates the JSON data with respect to <code>ErrorInfo</code>.
|
|
109
|
+
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
|
110
|
+
* @return {boolean} to indicate whether the JSON data is valid with respect to <code>ErrorInfo</code>.
|
|
111
|
+
*/
|
|
112
|
+
}, {
|
|
113
|
+
key: "validateJSON",
|
|
114
|
+
value: function validateJSON(data) {
|
|
115
|
+
// check to make sure all required properties are present in the JSON string
|
|
116
|
+
var _iterator = _createForOfIteratorHelper(ErrorInfo.RequiredProperties),
|
|
117
|
+
_step;
|
|
118
|
+
try {
|
|
119
|
+
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
120
|
+
var property = _step.value;
|
|
121
|
+
if (!data.hasOwnProperty(property)) {
|
|
122
|
+
throw new Error("The required field `" + property + "` is not found in the JSON data: " + JSON.stringify(data));
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
// ensure the json data is a string
|
|
126
|
+
} catch (err) {
|
|
127
|
+
_iterator.e(err);
|
|
128
|
+
} finally {
|
|
129
|
+
_iterator.f();
|
|
130
|
+
}
|
|
131
|
+
if (data['message'] && !(typeof data['message'] === 'string' || data['message'] instanceof String)) {
|
|
132
|
+
throw new Error("Expected the field `message` to be a primitive type in the JSON string but got " + data['message']);
|
|
133
|
+
}
|
|
134
|
+
// ensure the json data is an array
|
|
135
|
+
if (!Array.isArray(data['details'])) {
|
|
136
|
+
throw new Error("Expected the field `details` to be an array in the JSON data but got " + data['details']);
|
|
137
|
+
}
|
|
138
|
+
// ensure the json data is a string
|
|
139
|
+
if (data['request_id'] && !(typeof data['request_id'] === 'string' || data['request_id'] instanceof String)) {
|
|
140
|
+
throw new Error("Expected the field `request_id` to be a primitive type in the JSON string but got " + data['request_id']);
|
|
141
|
+
}
|
|
142
|
+
// ensure the json data is a string
|
|
143
|
+
if (data['submission_id'] && !(typeof data['submission_id'] === 'string' || data['submission_id'] instanceof String)) {
|
|
144
|
+
throw new Error("Expected the field `submission_id` to be a primitive type in the JSON string but got " + data['submission_id']);
|
|
145
|
+
}
|
|
146
|
+
// ensure the json data is a string
|
|
147
|
+
if (data['submission_batch_id'] && !(typeof data['submission_batch_id'] === 'string' || data['submission_batch_id'] instanceof String)) {
|
|
148
|
+
throw new Error("Expected the field `submission_batch_id` to be a primitive type in the JSON string but got " + data['submission_batch_id']);
|
|
149
|
+
}
|
|
150
|
+
// ensure the json data is a string
|
|
151
|
+
if (data['combined_pdf_id'] && !(typeof data['combined_pdf_id'] === 'string' || data['combined_pdf_id'] instanceof String)) {
|
|
152
|
+
throw new Error("Expected the field `combined_pdf_id` to be a primitive type in the JSON string but got " + data['combined_pdf_id']);
|
|
153
|
+
}
|
|
154
|
+
// ensure the json data is a string
|
|
155
|
+
if (data['template_id'] && !(typeof data['template_id'] === 'string' || data['template_id'] instanceof String)) {
|
|
156
|
+
throw new Error("Expected the field `template_id` to be a primitive type in the JSON string but got " + data['template_id']);
|
|
157
|
+
}
|
|
158
|
+
return true;
|
|
159
|
+
}
|
|
160
|
+
}]);
|
|
161
|
+
}();
|
|
162
|
+
ErrorInfo.RequiredProperties = ["code", "message", "details", "request_id"];
|
|
163
|
+
|
|
164
|
+
/**
|
|
165
|
+
* A machine-readable error code. Clients should handle codes they don't know: new codes can be added. `invalid_data`: a submission's data doesn't match its template's fields. The submission is still recorded. `insufficient_credits` (402): your credit balance can't cover a live PDF. The record was saved and waits for credits in the `insufficient_credits` state: its ID is in `submission_id`, `submission_batch_id` or `combined_pdf_id`. `upgrade_required` (403): your plan doesn't include this, such as more templates or the embedded template editor. `account_suspended` (403): the account is suspended, so it can't create submissions. `polling_timeout`: on a sync.api host, the PDF wasn't ready in time. The record was created and is still being processed: its ID is in `submission_id`, `submission_batch_id`, `combined_pdf_id` or `template_id`. Without one of these IDs, the request itself got no answer in time, and the record may or may not have been created.
|
|
166
|
+
* @member {module:model/ErrorCode} code
|
|
167
|
+
*/
|
|
168
|
+
ErrorInfo.prototype['code'] = undefined;
|
|
169
|
+
|
|
170
|
+
/**
|
|
171
|
+
* A human-readable explanation, safe to show to developers.
|
|
172
|
+
* @member {String} message
|
|
173
|
+
*/
|
|
174
|
+
ErrorInfo.prototype['message'] = undefined;
|
|
175
|
+
|
|
176
|
+
/**
|
|
177
|
+
* What was wrong with each part of the request. Empty when the error isn't about one part of it.
|
|
178
|
+
* @member {Array.<module:model/ErrorDetail>} details
|
|
179
|
+
*/
|
|
180
|
+
ErrorInfo.prototype['details'] = undefined;
|
|
181
|
+
|
|
182
|
+
/**
|
|
183
|
+
* The ID of the request. Include it when you contact support.
|
|
184
|
+
* @member {String} request_id
|
|
185
|
+
*/
|
|
186
|
+
ErrorInfo.prototype['request_id'] = undefined;
|
|
187
|
+
|
|
188
|
+
/**
|
|
189
|
+
* When a submission's data fails validation, the submission is still recorded (state `invalid_data`) so you can see it in the dashboard. This is its ID. With `insufficient_credits`, the submission that waits for credits. With `polling_timeout`, the submission that's still being processed.
|
|
190
|
+
* @member {String} submission_id
|
|
191
|
+
*/
|
|
192
|
+
ErrorInfo.prototype['submission_id'] = undefined;
|
|
193
|
+
|
|
194
|
+
/**
|
|
195
|
+
* The ID of the recorded batch, when items in a batch fail validation. With `insufficient_credits`, the batch whose submissions wait for credits. With `polling_timeout`, the batch that's still being processed.
|
|
196
|
+
* @member {String} submission_batch_id
|
|
197
|
+
*/
|
|
198
|
+
ErrorInfo.prototype['submission_batch_id'] = undefined;
|
|
199
|
+
|
|
200
|
+
/**
|
|
201
|
+
* With `insufficient_credits`, the combined PDF that waits for credits. With `polling_timeout`, the combined PDF that's still being processed.
|
|
202
|
+
* @member {String} combined_pdf_id
|
|
203
|
+
*/
|
|
204
|
+
ErrorInfo.prototype['combined_pdf_id'] = undefined;
|
|
205
|
+
|
|
206
|
+
/**
|
|
207
|
+
* With `polling_timeout`, the template whose PDF is still being processed.
|
|
208
|
+
* @member {String} template_id
|
|
209
|
+
*/
|
|
210
|
+
ErrorInfo.prototype['template_id'] = undefined;
|
|
211
|
+
var _default = exports["default"] = ErrorInfo;
|