boldsign 3.1.0 → 3.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (104) hide show
  1. package/.openapi-generator/FILES +11 -0
  2. package/README.md +17 -0
  3. package/api/apis.ts +1 -1
  4. package/api/documentApi.ts +262 -1
  5. package/api/groupContactsApi.ts +779 -0
  6. package/api/index.ts +3 -1
  7. package/boldsign-3.1.2.tgz +0 -0
  8. package/dist/api/apis.d.ts +1 -1
  9. package/dist/api/apis.js +1 -1
  10. package/dist/api/documentApi.d.ts +3 -1
  11. package/dist/api/documentApi.js +168 -0
  12. package/dist/api/documentApi.js.map +1 -1
  13. package/dist/api/groupContactsApi.d.ts +28 -0
  14. package/dist/api/groupContactsApi.js +507 -0
  15. package/dist/api/groupContactsApi.js.map +1 -0
  16. package/dist/api/index.d.ts +3 -2
  17. package/dist/api/index.js +4 -2
  18. package/dist/api/index.js.map +1 -1
  19. package/dist/examples/contactGroupDelete.d.ts +1 -0
  20. package/dist/examples/contactGroupDelete.js +27 -0
  21. package/dist/examples/contactGroupDelete.js.map +1 -0
  22. package/dist/examples/contactGroupGet.d.ts +1 -0
  23. package/dist/examples/contactGroupGet.js +27 -0
  24. package/dist/examples/contactGroupGet.js.map +1 -0
  25. package/dist/examples/contactGroupList.d.ts +1 -0
  26. package/dist/examples/contactGroupList.js +29 -0
  27. package/dist/examples/contactGroupList.js.map +1 -0
  28. package/dist/examples/contactGroupUpdate.d.ts +1 -0
  29. package/dist/examples/contactGroupUpdate.js +34 -0
  30. package/dist/examples/contactGroupUpdate.js.map +1 -0
  31. package/dist/examples/contactGroupsCreate.d.ts +1 -0
  32. package/dist/examples/contactGroupsCreate.js +35 -0
  33. package/dist/examples/contactGroupsCreate.js.map +1 -0
  34. package/dist/examples/documentCancelEditing.d.ts +1 -0
  35. package/dist/examples/documentCancelEditing.js +27 -0
  36. package/dist/examples/documentCancelEditing.js.map +1 -0
  37. package/dist/examples/documentCreateEmbeddedEditUrl.d.ts +1 -0
  38. package/dist/examples/documentCreateEmbeddedEditUrl.js +32 -0
  39. package/dist/examples/documentCreateEmbeddedEditUrl.js.map +1 -0
  40. package/dist/model/createGroupContactResponse.d.ts +15 -0
  41. package/dist/model/createGroupContactResponse.js +23 -0
  42. package/dist/model/createGroupContactResponse.js.map +1 -0
  43. package/dist/model/creators.d.ts +15 -0
  44. package/dist/model/creators.js +23 -0
  45. package/dist/model/creators.js.map +1 -0
  46. package/dist/model/embeddedDocumentEditJsonRequest.d.ts +51 -0
  47. package/dist/model/embeddedDocumentEditJsonRequest.js +97 -0
  48. package/dist/model/embeddedDocumentEditJsonRequest.js.map +1 -0
  49. package/dist/model/embeddedDocumentEdited.d.ts +14 -0
  50. package/dist/model/embeddedDocumentEdited.js +18 -0
  51. package/dist/model/embeddedDocumentEdited.js.map +1 -0
  52. package/dist/model/getGroupContactDetails.d.ts +20 -0
  53. package/dist/model/getGroupContactDetails.js +38 -0
  54. package/dist/model/getGroupContactDetails.js.map +1 -0
  55. package/dist/model/groupContact.d.ts +18 -0
  56. package/dist/model/groupContact.js +33 -0
  57. package/dist/model/groupContact.js.map +1 -0
  58. package/dist/model/groupContactDetails.d.ts +17 -0
  59. package/dist/model/groupContactDetails.js +28 -0
  60. package/dist/model/groupContactDetails.js.map +1 -0
  61. package/dist/model/groupContactsList.d.ts +17 -0
  62. package/dist/model/groupContactsList.js +23 -0
  63. package/dist/model/groupContactsList.js.map +1 -0
  64. package/dist/model/groupUser.d.ts +15 -0
  65. package/dist/model/groupUser.js +23 -0
  66. package/dist/model/groupUser.js.map +1 -0
  67. package/dist/model/index.d.ts +11 -1
  68. package/dist/model/index.js +36 -4
  69. package/dist/model/index.js.map +1 -1
  70. package/dist/model/updateGroupContact.d.ts +17 -0
  71. package/dist/model/updateGroupContact.js +28 -0
  72. package/dist/model/updateGroupContact.js.map +1 -0
  73. package/docs/CreateGroupContactResponse.md +12 -0
  74. package/docs/Creators.md +12 -0
  75. package/docs/DocumentApi.md +68 -0
  76. package/docs/EmbeddedDocumentEditJsonRequest.md +19 -0
  77. package/docs/EmbeddedDocumentEdited.md +11 -0
  78. package/docs/GetGroupContactDetails.md +15 -0
  79. package/docs/GroupContact.md +14 -0
  80. package/docs/GroupContactDetails.md +13 -0
  81. package/docs/GroupContactsApi.md +177 -0
  82. package/docs/GroupContactsList.md +12 -0
  83. package/docs/GroupUser.md +12 -0
  84. package/docs/UpdateGroupContact.md +13 -0
  85. package/examples/contactGroupDelete.ts +14 -0
  86. package/examples/contactGroupGet.ts +14 -0
  87. package/examples/contactGroupList.ts +16 -0
  88. package/examples/contactGroupUpdate.ts +21 -0
  89. package/examples/contactGroupsCreate.ts +24 -0
  90. package/examples/documentCancelEditing.ts +14 -0
  91. package/examples/documentCreateEmbeddedEditUrl.ts +19 -0
  92. package/model/createGroupContactResponse.ts +37 -0
  93. package/model/creators.ts +37 -0
  94. package/model/embeddedDocumentEditJsonRequest.ts +108 -0
  95. package/model/embeddedDocumentEdited.ts +31 -0
  96. package/model/getGroupContactDetails.ts +57 -0
  97. package/model/groupContact.ts +50 -0
  98. package/model/groupContactDetails.ts +44 -0
  99. package/model/groupContactsList.ts +39 -0
  100. package/model/groupUser.ts +37 -0
  101. package/model/index.ts +32 -0
  102. package/model/updateGroupContact.ts +44 -0
  103. package/package.json +1 -1
  104. package/boldsign-3.1.0.tgz +0 -0
@@ -7,6 +7,7 @@ api/brandingApi.ts
7
7
  api/contactsApi.ts
8
8
  api/customFieldApi.ts
9
9
  api/documentApi.ts
10
+ api/groupContactsApi.ts
10
11
  api/identityVerificationApi.ts
11
12
  api/index.ts
12
13
  api/planApi.ts
@@ -41,10 +42,12 @@ model/contactPageDetails.ts
41
42
  model/contactsDetails.ts
42
43
  model/contactsList.ts
43
44
  model/createContactResponse.ts
45
+ model/createGroupContactResponse.ts
44
46
  model/createSenderIdentityRequest.ts
45
47
  model/createTeamRequest.ts
46
48
  model/createTemplateRequest.ts
47
49
  model/createUser.ts
50
+ model/creators.ts
48
51
  model/customDomainSettings.ts
49
52
  model/customFieldCollection.ts
50
53
  model/customFieldMessage.ts
@@ -76,6 +79,8 @@ model/editTemplateRequest.ts
76
79
  model/editableDateFieldSettings.ts
77
80
  model/embeddedCreateTemplateRequest.ts
78
81
  model/embeddedCustomFieldCreated.ts
82
+ model/embeddedDocumentEditJsonRequest.ts
83
+ model/embeddedDocumentEdited.ts
79
84
  model/embeddedDocumentRequest.ts
80
85
  model/embeddedFileDetails.ts
81
86
  model/embeddedFileLink.ts
@@ -97,8 +102,13 @@ model/formField.ts
97
102
  model/formFieldPermission.ts
98
103
  model/formGroup.ts
99
104
  model/formulaFieldSettings.ts
105
+ model/getGroupContactDetails.ts
106
+ model/groupContact.ts
107
+ model/groupContactDetails.ts
108
+ model/groupContactsList.ts
100
109
  model/groupSigner.ts
101
110
  model/groupSignerSettings.ts
111
+ model/groupUser.ts
102
112
  model/idDocument.ts
103
113
  model/idReport.ts
104
114
  model/idVerificationDetails.ts
@@ -159,6 +169,7 @@ model/templateTag.ts
159
169
  model/templateTeamShare.ts
160
170
  model/textTagDefinition.ts
161
171
  model/textTagOffset.ts
172
+ model/updateGroupContact.ts
162
173
  model/updateUser.ts
163
174
  model/updateUserMetaData.ts
164
175
  model/userPageDetails.ts
package/README.md CHANGED
@@ -85,8 +85,10 @@ All URIs are relative to *https://api.boldsign.com*
85
85
  | *DocumentApi* | [**addAuthentication**](./docs/DocumentApi.md#addauthentication) | **PATCH** /v1/document/addAuthentication | The add authentication to recipient. |
86
86
  | *DocumentApi* | [**addTag**](./docs/DocumentApi.md#addtag) | **PATCH** /v1/document/addTags | Add the Tags in Documents. |
87
87
  | *DocumentApi* | [**behalfDocuments**](./docs/DocumentApi.md#behalfdocuments) | **GET** /v1/document/behalfList | Gets the behalf documents. |
88
+ | *DocumentApi* | [**cancelEditing**](./docs/DocumentApi.md#cancelediting) | **POST** /v1/document/cancelEditing | Cancels editing for a document that is currently in edit-mode. |
88
89
  | *DocumentApi* | [**changeAccessCode**](./docs/DocumentApi.md#changeaccesscode) | **PATCH** /v1/document/changeAccessCode | Changes the access code for the given document signer. |
89
90
  | *DocumentApi* | [**changeRecipient**](./docs/DocumentApi.md#changerecipient) | **PATCH** /v1/document/changeRecipient | Change recipient details of a document. |
91
+ | *DocumentApi* | [**createEmbeddedEditUrl**](./docs/DocumentApi.md#createembeddedediturl) | **POST** /v1/document/createEmbeddedEditUrl | Generates an embedded edit URL that allows the document editing process to be integrated into your application. |
90
92
  | *DocumentApi* | [**createEmbeddedRequestUrlDocument**](./docs/DocumentApi.md#createembeddedrequesturldocument) | **POST** /v1/document/createEmbeddedRequestUrl | Generates a send URL which embeds document sending process into your application. |
91
93
  | *DocumentApi* | [**deleteDocument**](./docs/DocumentApi.md#deletedocument) | **DELETE** /v1/document/delete | Delete the document. |
92
94
  | *DocumentApi* | [**deleteTag**](./docs/DocumentApi.md#deletetag) | **DELETE** /v1/document/deleteTags | Delete the Tags in Documents. |
@@ -105,6 +107,11 @@ All URIs are relative to *https://api.boldsign.com*
105
107
  | *DocumentApi* | [**revokeDocument**](./docs/DocumentApi.md#revokedocument) | **POST** /v1/document/revoke | Revoke the document. |
106
108
  | *DocumentApi* | [**sendDocument**](./docs/DocumentApi.md#senddocument) | **POST** /v1/document/send | Sends the document for sign. |
107
109
  | *DocumentApi* | [**teamDocuments**](./docs/DocumentApi.md#teamdocuments) | **GET** /v1/document/teamlist | Get user Team documents. |
110
+ | *GroupContactsApi* | [**createGroupContact**](./docs/GroupContactsApi.md#creategroupcontact) | **POST** /v1/contactGroups/create | Create a new Group Contact. |
111
+ | *GroupContactsApi* | [**deleteGroupContact**](./docs/GroupContactsApi.md#deletegroupcontact) | **DELETE** /v1/contactGroups/delete | Deletes a Group Contact. |
112
+ | *GroupContactsApi* | [**getGroupContact**](./docs/GroupContactsApi.md#getgroupcontact) | **GET** /v1/contactGroups/get | Get Summary of the Group Contact. |
113
+ | *GroupContactsApi* | [**groupContactList**](./docs/GroupContactsApi.md#groupcontactlist) | **GET** /v1/contactGroups/list | List Group Contacts. |
114
+ | *GroupContactsApi* | [**updateGroupContact**](./docs/GroupContactsApi.md#updategroupcontact) | **PUT** /v1/contactGroups/update | Update the Group Contact. |
108
115
  | *IdentityVerificationApi* | [**createEmbeddedVerificationUrl**](./docs/IdentityVerificationApi.md#createembeddedverificationurl) | **POST** /v1/identityVerification/createEmbeddedVerificationUrl | Generate a URL that embeds manual ID verification for the specified document signer into your application. |
109
116
  | *IdentityVerificationApi* | [**image**](./docs/IdentityVerificationApi.md#image) | **POST** /v1/identityVerification/image | Retrieve the uploaded ID verification document or selfie image for the specified document signer using the file ID. |
110
117
  | *IdentityVerificationApi* | [**report**](./docs/IdentityVerificationApi.md#report) | **POST** /v1/identityVerification/report | Retrieve the ID verification report for the specified document signer. |
@@ -172,10 +179,12 @@ All URIs are relative to *https://api.boldsign.com*
172
179
  - [ContactsDetails](./docs/ContactsDetails.md)
173
180
  - [ContactsList](./docs/ContactsList.md)
174
181
  - [CreateContactResponse](./docs/CreateContactResponse.md)
182
+ - [CreateGroupContactResponse](./docs/CreateGroupContactResponse.md)
175
183
  - [CreateSenderIdentityRequest](./docs/CreateSenderIdentityRequest.md)
176
184
  - [CreateTeamRequest](./docs/CreateTeamRequest.md)
177
185
  - [CreateTemplateRequest](./docs/CreateTemplateRequest.md)
178
186
  - [CreateUser](./docs/CreateUser.md)
187
+ - [Creators](./docs/Creators.md)
179
188
  - [CustomDomainSettings](./docs/CustomDomainSettings.md)
180
189
  - [CustomFieldCollection](./docs/CustomFieldCollection.md)
181
190
  - [CustomFieldMessage](./docs/CustomFieldMessage.md)
@@ -207,6 +216,8 @@ All URIs are relative to *https://api.boldsign.com*
207
216
  - [EditableDateFieldSettings](./docs/EditableDateFieldSettings.md)
208
217
  - [EmbeddedCreateTemplateRequest](./docs/EmbeddedCreateTemplateRequest.md)
209
218
  - [EmbeddedCustomFieldCreated](./docs/EmbeddedCustomFieldCreated.md)
219
+ - [EmbeddedDocumentEditJsonRequest](./docs/EmbeddedDocumentEditJsonRequest.md)
220
+ - [EmbeddedDocumentEdited](./docs/EmbeddedDocumentEdited.md)
210
221
  - [EmbeddedDocumentRequest](./docs/EmbeddedDocumentRequest.md)
211
222
  - [EmbeddedFileDetails](./docs/EmbeddedFileDetails.md)
212
223
  - [EmbeddedFileLink](./docs/EmbeddedFileLink.md)
@@ -228,8 +239,13 @@ All URIs are relative to *https://api.boldsign.com*
228
239
  - [FormFieldPermission](./docs/FormFieldPermission.md)
229
240
  - [FormGroup](./docs/FormGroup.md)
230
241
  - [FormulaFieldSettings](./docs/FormulaFieldSettings.md)
242
+ - [GetGroupContactDetails](./docs/GetGroupContactDetails.md)
243
+ - [GroupContact](./docs/GroupContact.md)
244
+ - [GroupContactDetails](./docs/GroupContactDetails.md)
245
+ - [GroupContactsList](./docs/GroupContactsList.md)
231
246
  - [GroupSigner](./docs/GroupSigner.md)
232
247
  - [GroupSignerSettings](./docs/GroupSignerSettings.md)
248
+ - [GroupUser](./docs/GroupUser.md)
233
249
  - [IdDocument](./docs/IdDocument.md)
234
250
  - [IdReport](./docs/IdReport.md)
235
251
  - [IdVerificationDetails](./docs/IdVerificationDetails.md)
@@ -288,6 +304,7 @@ All URIs are relative to *https://api.boldsign.com*
288
304
  - [TemplateTeamShare](./docs/TemplateTeamShare.md)
289
305
  - [TextTagDefinition](./docs/TextTagDefinition.md)
290
306
  - [TextTagOffset](./docs/TextTagOffset.md)
307
+ - [UpdateGroupContact](./docs/UpdateGroupContact.md)
291
308
  - [UpdateUser](./docs/UpdateUser.md)
292
309
  - [UpdateUserMetaData](./docs/UpdateUserMetaData.md)
293
310
  - [UserPageDetails](./docs/UserPageDetails.md)
package/api/apis.ts CHANGED
@@ -24,7 +24,7 @@ export const queryParamsSerializer = (params) => {
24
24
  return Qs.stringify(params, { arrayFormat: 'repeat' })
25
25
  }
26
26
 
27
- export const USER_AGENT = "boldsign-node-sdk/3.1.0";
27
+ export const USER_AGENT = "boldsign-node-sdk/3.1.2";
28
28
 
29
29
  /**
30
30
  * Generates an object containing form data.
@@ -15,7 +15,7 @@ import axios, { AxiosError, AxiosRequestConfig, AxiosResponse } from 'axios';
15
15
  import {
16
16
  ObjectSerializer, Authentication, VoidAuth, Interceptor,
17
17
  HttpBasicAuth, HttpBearerAuth, ApiKeyAuth, OAuth, RequestFile,
18
- AccessCodeDetail,AccessCodeDetails,BehalfDocumentRecords,ChangeRecipient,DocumentCreated,DocumentEdited,DocumentProperties,DocumentRecords,DocumentTags,EditDocumentRequest,EmbeddedDocumentRequest,EmbeddedSendCreated,EmbeddedSigningLink,ErrorResult,ExtendExpiry,PrefillFieldRequest,ReminderMessage,RemoveAuthentication,RevokeDocument,SendForSign,TeamDocumentRecords,
18
+ AccessCodeDetail,AccessCodeDetails,BehalfDocumentRecords,ChangeRecipient,DocumentCreated,DocumentEdited,DocumentProperties,DocumentRecords,DocumentTags,EditDocumentRequest,EmbeddedDocumentEditJsonRequest,EmbeddedDocumentEdited,EmbeddedDocumentRequest,EmbeddedSendCreated,EmbeddedSigningLink,ErrorResult,ExtendExpiry,PrefillFieldRequest,ReminderMessage,RemoveAuthentication,RevokeDocument,SendForSign,TeamDocumentRecords,
19
19
  } from '../model';
20
20
 
21
21
  import {
@@ -492,6 +492,122 @@ export class DocumentApi {
492
492
  }
493
493
 
494
494
 
495
+ reject(error);
496
+ });
497
+ });
498
+ });
499
+ }
500
+ /**
501
+ *
502
+ * @summary Cancels editing for a document that is currently in edit-mode.
503
+ * @param documentId The document id.
504
+ * @param onBehalfOf The onbehalfof email id.
505
+ * @param options
506
+ */
507
+ public async cancelEditing (documentId: string, onBehalfOf?: string, options: optionsI = {headers: {}}) : Promise<returnTypeI> {
508
+ const localVarPath = this.basePath + '/v1/document/cancelEditing';
509
+ let localVarQueryParameters: any = {};
510
+ let localVarHeaderParams: any = (<any>Object).assign({}, this._defaultHeaders);
511
+ const produces = ['application/json'];
512
+ // give precedence to 'application/json'
513
+ if (produces.indexOf('application/json') >= 0) {
514
+ localVarHeaderParams['content-type'] = 'application/json';
515
+ } else {
516
+ localVarHeaderParams['content-type'] = produces.join(',');
517
+ }
518
+ let localVarFormParams: any = {};
519
+ let localVarBodyParams: any = undefined;
520
+
521
+ // verify required parameter 'documentId' is not null or undefined
522
+ if (documentId === null || documentId === undefined) {
523
+ throw new Error('Required parameter documentId was null or undefined when calling cancelEditing.');
524
+ }
525
+
526
+ if (documentId !== undefined) {
527
+ localVarQueryParameters['documentId'] = ObjectSerializer.serialize(documentId, "string");
528
+ }
529
+
530
+ if (onBehalfOf !== undefined) {
531
+ localVarQueryParameters['onBehalfOf'] = ObjectSerializer.serialize(onBehalfOf, "string");
532
+ }
533
+
534
+ (<any>Object).assign(localVarHeaderParams, options.headers);
535
+
536
+ let localVarUseFormData = false;
537
+
538
+ let data = {};
539
+ if (localVarUseFormData) {
540
+ const formData = toFormData(localVarFormParams);
541
+ data = formData;
542
+ localVarHeaderParams = {
543
+ ...localVarHeaderParams,
544
+ ...formData.getHeaders(),
545
+ };
546
+ }
547
+
548
+ let localVarRequestOptions: AxiosRequestConfig = {
549
+ method: 'POST',
550
+ params: localVarQueryParameters,
551
+ headers: localVarHeaderParams,
552
+ url: localVarPath,
553
+ paramsSerializer: this._useQuerystring ? queryParamsSerializer : undefined,
554
+ maxContentLength: Infinity,
555
+ maxBodyLength: Infinity,
556
+ responseType: "json",
557
+ };
558
+
559
+ if (localVarRequestOptions.method !== 'GET') {
560
+ localVarRequestOptions.data = data;
561
+ }
562
+ let authenticationPromise = Promise.resolve();
563
+
564
+ if (this.authentications["X-API-KEY"].apiKey) {
565
+ authenticationPromise = authenticationPromise.then(() => this.authentications["X-API-KEY"].applyToRequest(localVarRequestOptions));
566
+ }
567
+ if (this.authentications["Bearer"].apiKey) {
568
+ authenticationPromise = authenticationPromise.then(() => this.authentications["Bearer"].applyToRequest(localVarRequestOptions));
569
+ }
570
+ authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
571
+
572
+ let interceptorPromise = authenticationPromise;
573
+ for (const interceptor of this.interceptors) {
574
+ interceptorPromise = interceptorPromise.then(() => interceptor(localVarRequestOptions));
575
+ }
576
+
577
+ return interceptorPromise.then(() => {
578
+ return new Promise<returnTypeI>((resolve, reject) => {
579
+ axios.request(localVarRequestOptions)
580
+ .then((response) => {
581
+ handleSuccessfulResponse(
582
+ resolve,
583
+ reject,
584
+ response,
585
+
586
+ );
587
+ }, (error: AxiosError) => {
588
+ if (error.response == null) {
589
+ reject(error);
590
+ return;
591
+ }
592
+
593
+ if (handleErrorCodeResponse(
594
+ reject,
595
+ error.response,
596
+ 400,
597
+ "ErrorResult",
598
+ )) {
599
+ return;
600
+ }
601
+ if (handleErrorCodeResponse(
602
+ reject,
603
+ error.response,
604
+ 401,
605
+ "ErrorResult",
606
+ )) {
607
+ return;
608
+ }
609
+
610
+
495
611
  reject(error);
496
612
  });
497
613
  });
@@ -754,6 +870,151 @@ export class DocumentApi {
754
870
  }
755
871
 
756
872
 
873
+ reject(error);
874
+ });
875
+ });
876
+ });
877
+ }
878
+ /**
879
+ *
880
+ * @summary Generates an embedded edit URL that allows the document editing process to be integrated into your application.
881
+ * @param documentId The document id.
882
+ * @param embeddedDocumentEditJsonRequest The embedded edit document request body.
883
+ * @param options
884
+ */
885
+ public async createEmbeddedEditUrl (documentId: string, embeddedDocumentEditJsonRequest?: EmbeddedDocumentEditJsonRequest, options: optionsI = {headers: {}}) : Promise<EmbeddedDocumentEdited> {
886
+ embeddedDocumentEditJsonRequest = deserializeIfNeeded(embeddedDocumentEditJsonRequest, "EmbeddedDocumentEditJsonRequest");
887
+ const localVarPath = this.basePath + '/v1/document/createEmbeddedEditUrl';
888
+ let localVarQueryParameters: any = {};
889
+ let localVarHeaderParams: any = (<any>Object).assign({}, this._defaultHeaders);
890
+ const produces = ['application/json'];
891
+ // give precedence to 'application/json'
892
+ if (produces.indexOf('application/json') >= 0) {
893
+ localVarHeaderParams['content-type'] = 'application/json';
894
+ } else {
895
+ localVarHeaderParams['content-type'] = produces.join(',');
896
+ }
897
+ let localVarFormParams: any = {};
898
+ let localVarBodyParams: any = undefined;
899
+
900
+ // verify required parameter 'documentId' is not null or undefined
901
+ if (documentId === null || documentId === undefined) {
902
+ throw new Error('Required parameter documentId was null or undefined when calling createEmbeddedEditUrl.');
903
+ }
904
+
905
+ if (documentId !== undefined) {
906
+ localVarQueryParameters['documentId'] = ObjectSerializer.serialize(documentId, "string");
907
+ }
908
+
909
+ (<any>Object).assign(localVarHeaderParams, options.headers);
910
+
911
+ let localVarUseFormData = false;
912
+
913
+ const result = generateFormData(embeddedDocumentEditJsonRequest, EmbeddedDocumentEditJsonRequest);
914
+ localVarUseFormData = result.localVarUseFormData;
915
+
916
+ let data = {};
917
+ if (localVarUseFormData) {
918
+ const formData = toFormData(result.data);
919
+ data = formData;
920
+ localVarHeaderParams = {
921
+ ...localVarHeaderParams,
922
+ ...formData.getHeaders(),
923
+ };
924
+ } else {
925
+ data = ObjectSerializer.serialize(
926
+ embeddedDocumentEditJsonRequest,
927
+ "EmbeddedDocumentEditJsonRequest"
928
+ );
929
+ }
930
+
931
+ let localVarRequestOptions: AxiosRequestConfig = {
932
+ method: 'POST',
933
+ params: localVarQueryParameters,
934
+ headers: localVarHeaderParams,
935
+ url: localVarPath,
936
+ paramsSerializer: this._useQuerystring ? queryParamsSerializer : undefined,
937
+ maxContentLength: Infinity,
938
+ maxBodyLength: Infinity,
939
+ responseType: "json",
940
+ };
941
+
942
+ if (localVarRequestOptions.method !== 'GET') {
943
+ localVarRequestOptions.data = data;
944
+ }
945
+ let authenticationPromise = Promise.resolve();
946
+
947
+ if (this.authentications["X-API-KEY"].apiKey) {
948
+ authenticationPromise = authenticationPromise.then(() => this.authentications["X-API-KEY"].applyToRequest(localVarRequestOptions));
949
+ }
950
+ if (this.authentications["Bearer"].apiKey) {
951
+ authenticationPromise = authenticationPromise.then(() => this.authentications["Bearer"].applyToRequest(localVarRequestOptions));
952
+ }
953
+ authenticationPromise = authenticationPromise.then(() => this.authentications.default.applyToRequest(localVarRequestOptions));
954
+
955
+ let interceptorPromise = authenticationPromise;
956
+ for (const interceptor of this.interceptors) {
957
+ interceptorPromise = interceptorPromise.then(() => interceptor(localVarRequestOptions));
958
+ }
959
+
960
+ return interceptorPromise.then(() => {
961
+ return new Promise<EmbeddedDocumentEdited>((resolve, reject) => {
962
+ axios.request(localVarRequestOptions)
963
+ .then((response) => {
964
+ handleSuccessfulResponse<EmbeddedDocumentEdited>(
965
+ resolve,
966
+ reject,
967
+ response,
968
+ "EmbeddedDocumentEdited",
969
+ );
970
+ }, (error: AxiosError) => {
971
+ if (error.response == null) {
972
+ reject(error);
973
+ return;
974
+ }
975
+
976
+ if (handleErrorCodeResponse(
977
+ reject,
978
+ error.response,
979
+ 201,
980
+ "EmbeddedDocumentEdited",
981
+ )) {
982
+ return;
983
+ }
984
+ if (handleErrorCodeResponse(
985
+ reject,
986
+ error.response,
987
+ 400,
988
+ "ErrorResult",
989
+ )) {
990
+ return;
991
+ }
992
+ if (handleErrorCodeResponse(
993
+ reject,
994
+ error.response,
995
+ 401,
996
+ "ErrorResult",
997
+ )) {
998
+ return;
999
+ }
1000
+ if (handleErrorCodeResponse(
1001
+ reject,
1002
+ error.response,
1003
+ 403,
1004
+ "ErrorResult",
1005
+ )) {
1006
+ return;
1007
+ }
1008
+ if (handleErrorCodeResponse(
1009
+ reject,
1010
+ error.response,
1011
+ 422,
1012
+ "ErrorResult",
1013
+ )) {
1014
+ return;
1015
+ }
1016
+
1017
+
757
1018
  reject(error);
758
1019
  });
759
1020
  });