@openfilz-sdk/typescript 1.2.27 → 1.2.28

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 (160) hide show
  1. package/.openapi-generator/FILES +44 -0
  2. package/.openapi-generator/openfilz-api-generate-typescript-sdk.sha256 +1 -1
  3. package/README.md +43 -2
  4. package/api/esign-api.ts +719 -0
  5. package/api/esign-public-api.ts +622 -0
  6. package/api/esign-templates-api.ts +503 -0
  7. package/api.ts +3 -0
  8. package/dist/api/esign-api.d.ts +334 -0
  9. package/dist/api/esign-api.js +693 -0
  10. package/dist/api/esign-public-api.d.ts +282 -0
  11. package/dist/api/esign-public-api.js +595 -0
  12. package/dist/api/esign-templates-api.d.ts +234 -0
  13. package/dist/api/esign-templates-api.js +486 -0
  14. package/dist/api.d.ts +3 -0
  15. package/dist/api.js +3 -0
  16. package/dist/esm/api/esign-api.d.ts +334 -0
  17. package/dist/esm/api/esign-api.js +686 -0
  18. package/dist/esm/api/esign-public-api.d.ts +282 -0
  19. package/dist/esm/api/esign-public-api.js +588 -0
  20. package/dist/esm/api/esign-templates-api.d.ts +234 -0
  21. package/dist/esm/api/esign-templates-api.js +479 -0
  22. package/dist/esm/api.d.ts +3 -0
  23. package/dist/esm/api.js +3 -0
  24. package/dist/esm/models/apply-signature-request.d.ts +18 -0
  25. package/dist/esm/models/apply-signature-request.js +14 -0
  26. package/dist/esm/models/audit-log.d.ts +10 -0
  27. package/dist/esm/models/audit-log.js +10 -0
  28. package/dist/esm/models/create-signature-envelope-request.d.ts +24 -0
  29. package/dist/esm/models/create-signature-envelope-request.js +14 -0
  30. package/dist/esm/models/decline-signature-request.d.ts +14 -0
  31. package/dist/esm/models/decline-signature-request.js +14 -0
  32. package/dist/esm/models/index.d.ts +19 -0
  33. package/dist/esm/models/index.js +19 -0
  34. package/dist/esm/models/instantiate-template-request.d.ts +22 -0
  35. package/dist/esm/models/instantiate-template-request.js +14 -0
  36. package/dist/esm/models/public-signature-view.d.ts +57 -0
  37. package/dist/esm/models/public-signature-view.js +32 -0
  38. package/dist/esm/models/role-binding.d.ts +19 -0
  39. package/dist/esm/models/role-binding.js +14 -0
  40. package/dist/esm/models/search-by-audit-log-request.d.ts +10 -0
  41. package/dist/esm/models/search-by-audit-log-request.js +10 -0
  42. package/dist/esm/models/settings.d.ts +3 -0
  43. package/dist/esm/models/signature-envelope-dto.d.ts +40 -0
  44. package/dist/esm/models/signature-envelope-dto.js +21 -0
  45. package/dist/esm/models/signature-event-dto.d.ts +33 -0
  46. package/dist/esm/models/signature-event-dto.js +26 -0
  47. package/dist/esm/models/signature-field-dto.d.ts +44 -0
  48. package/dist/esm/models/signature-field-dto.js +27 -0
  49. package/dist/esm/models/signature-field-input.d.ts +39 -0
  50. package/dist/esm/models/signature-field-input.js +27 -0
  51. package/dist/esm/models/signature-field-placement.d.ts +18 -0
  52. package/dist/esm/models/signature-field-placement.js +14 -0
  53. package/dist/esm/models/signature-field-value.d.ts +16 -0
  54. package/dist/esm/models/signature-field-value.js +14 -0
  55. package/dist/esm/models/signature-recipient-dto.d.ts +45 -0
  56. package/dist/esm/models/signature-recipient-dto.js +28 -0
  57. package/dist/esm/models/signature-recipient-input.d.ts +36 -0
  58. package/dist/esm/models/signature-recipient-input.js +22 -0
  59. package/dist/esm/models/signature-template-dto.d.ts +27 -0
  60. package/dist/esm/models/signature-template-dto.js +14 -0
  61. package/dist/esm/models/signature-template-field.d.ts +40 -0
  62. package/dist/esm/models/signature-template-field.js +27 -0
  63. package/dist/esm/models/signature-template-request.d.ts +23 -0
  64. package/dist/esm/models/signature-template-request.js +14 -0
  65. package/dist/esm/models/signature-template-role.d.ts +28 -0
  66. package/dist/esm/models/signature-template-role.js +22 -0
  67. package/dist/esm/models/verify-otp-request.d.ts +14 -0
  68. package/dist/esm/models/verify-otp-request.js +14 -0
  69. package/dist/models/apply-signature-request.d.ts +18 -0
  70. package/dist/models/apply-signature-request.js +15 -0
  71. package/dist/models/audit-log.d.ts +10 -0
  72. package/dist/models/audit-log.js +10 -0
  73. package/dist/models/create-signature-envelope-request.d.ts +24 -0
  74. package/dist/models/create-signature-envelope-request.js +15 -0
  75. package/dist/models/decline-signature-request.d.ts +14 -0
  76. package/dist/models/decline-signature-request.js +15 -0
  77. package/dist/models/index.d.ts +19 -0
  78. package/dist/models/index.js +19 -0
  79. package/dist/models/instantiate-template-request.d.ts +22 -0
  80. package/dist/models/instantiate-template-request.js +15 -0
  81. package/dist/models/public-signature-view.d.ts +57 -0
  82. package/dist/models/public-signature-view.js +35 -0
  83. package/dist/models/role-binding.d.ts +19 -0
  84. package/dist/models/role-binding.js +15 -0
  85. package/dist/models/search-by-audit-log-request.d.ts +10 -0
  86. package/dist/models/search-by-audit-log-request.js +10 -0
  87. package/dist/models/settings.d.ts +3 -0
  88. package/dist/models/signature-envelope-dto.d.ts +40 -0
  89. package/dist/models/signature-envelope-dto.js +24 -0
  90. package/dist/models/signature-event-dto.d.ts +33 -0
  91. package/dist/models/signature-event-dto.js +29 -0
  92. package/dist/models/signature-field-dto.d.ts +44 -0
  93. package/dist/models/signature-field-dto.js +30 -0
  94. package/dist/models/signature-field-input.d.ts +39 -0
  95. package/dist/models/signature-field-input.js +30 -0
  96. package/dist/models/signature-field-placement.d.ts +18 -0
  97. package/dist/models/signature-field-placement.js +15 -0
  98. package/dist/models/signature-field-value.d.ts +16 -0
  99. package/dist/models/signature-field-value.js +15 -0
  100. package/dist/models/signature-recipient-dto.d.ts +45 -0
  101. package/dist/models/signature-recipient-dto.js +31 -0
  102. package/dist/models/signature-recipient-input.d.ts +36 -0
  103. package/dist/models/signature-recipient-input.js +25 -0
  104. package/dist/models/signature-template-dto.d.ts +27 -0
  105. package/dist/models/signature-template-dto.js +15 -0
  106. package/dist/models/signature-template-field.d.ts +40 -0
  107. package/dist/models/signature-template-field.js +30 -0
  108. package/dist/models/signature-template-request.d.ts +23 -0
  109. package/dist/models/signature-template-request.js +15 -0
  110. package/dist/models/signature-template-role.d.ts +28 -0
  111. package/dist/models/signature-template-role.js +25 -0
  112. package/dist/models/verify-otp-request.d.ts +14 -0
  113. package/dist/models/verify-otp-request.js +15 -0
  114. package/docs/ApplySignatureRequest.md +26 -0
  115. package/docs/CreateSignatureEnvelopeRequest.md +38 -0
  116. package/docs/DeclineSignatureRequest.md +20 -0
  117. package/docs/ESignApi.md +463 -0
  118. package/docs/ESignPublicApi.md +382 -0
  119. package/docs/ESignTemplatesApi.md +315 -0
  120. package/docs/InstantiateTemplateRequest.md +34 -0
  121. package/docs/PublicSignatureView.md +60 -0
  122. package/docs/RoleBinding.md +30 -0
  123. package/docs/Settings.md +6 -0
  124. package/docs/SignatureEnvelopeDTO.md +52 -0
  125. package/docs/SignatureEventDTO.md +30 -0
  126. package/docs/SignatureFieldDTO.md +46 -0
  127. package/docs/SignatureFieldInput.md +36 -0
  128. package/docs/SignatureFieldPlacement.md +28 -0
  129. package/docs/SignatureFieldValue.md +24 -0
  130. package/docs/SignatureRecipientDTO.md +44 -0
  131. package/docs/SignatureRecipientInput.md +38 -0
  132. package/docs/SignatureTemplateDTO.md +42 -0
  133. package/docs/SignatureTemplateField.md +38 -0
  134. package/docs/SignatureTemplateRequest.md +34 -0
  135. package/docs/SignatureTemplateRole.md +26 -0
  136. package/docs/VerifyOtpRequest.md +20 -0
  137. package/models/apply-signature-request.ts +26 -0
  138. package/models/audit-log.ts +10 -0
  139. package/models/create-signature-envelope-request.ts +32 -0
  140. package/models/decline-signature-request.ts +20 -0
  141. package/models/index.ts +19 -0
  142. package/models/instantiate-template-request.ts +30 -0
  143. package/models/public-signature-view.ts +70 -0
  144. package/models/role-binding.ts +25 -0
  145. package/models/search-by-audit-log-request.ts +10 -0
  146. package/models/settings.ts +3 -0
  147. package/models/signature-envelope-dto.ts +51 -0
  148. package/models/signature-event-dto.ts +42 -0
  149. package/models/signature-field-dto.ts +51 -0
  150. package/models/signature-field-input.ts +46 -0
  151. package/models/signature-field-placement.ts +24 -0
  152. package/models/signature-field-value.ts +22 -0
  153. package/models/signature-recipient-dto.ts +58 -0
  154. package/models/signature-recipient-input.ts +50 -0
  155. package/models/signature-template-dto.ts +37 -0
  156. package/models/signature-template-field.ts +47 -0
  157. package/models/signature-template-request.ts +33 -0
  158. package/models/signature-template-role.ts +38 -0
  159. package/models/verify-otp-request.ts +20 -0
  160. package/package.json +1 -1
@@ -0,0 +1,622 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * openfilz-api
5
+ * API for Document Management System
6
+ *
7
+ * The version of the OpenAPI document: 1.0.0
8
+ *
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+
15
+
16
+ import type { Configuration } from '../configuration';
17
+ import type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios';
18
+ import globalAxios from 'axios';
19
+ // Some imports not used depending on template conditions
20
+ // @ts-ignore
21
+ import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction, replaceWithSerializableTypeIfNeeded } from '../common';
22
+ // @ts-ignore
23
+ import { BASE_PATH, COLLECTION_FORMATS, type RequestArgs, BaseAPI, RequiredError, operationServerMap } from '../base';
24
+ // @ts-ignore
25
+ import type { ApplySignatureRequest } from '../models';
26
+ // @ts-ignore
27
+ import type { DeclineSignatureRequest } from '../models';
28
+ // @ts-ignore
29
+ import type { PublicSignatureView } from '../models';
30
+ // @ts-ignore
31
+ import type { VerifyOtpRequest } from '../models';
32
+ /**
33
+ * ESignPublicApi - axios parameter creator
34
+ */
35
+ export const ESignPublicApiAxiosParamCreator = function (configuration?: Configuration) {
36
+ return {
37
+ /**
38
+ *
39
+ * @summary Decline to sign (voids the envelope)
40
+ * @param {string} token
41
+ * @param {DeclineSignatureRequest} [declineSignatureRequest]
42
+ * @param {*} [options] Override http request option.
43
+ * @throws {RequiredError}
44
+ */
45
+ decline: async (token: string, declineSignatureRequest?: DeclineSignatureRequest, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
46
+ // verify required parameter 'token' is not null or undefined
47
+ assertParamExists('decline', 'token', token)
48
+ const localVarPath = `/api/v1/public/signatures/decline`;
49
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
50
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
51
+ let baseOptions;
52
+ if (configuration) {
53
+ baseOptions = configuration.baseOptions;
54
+ }
55
+
56
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
57
+ const localVarHeaderParameter = {} as any;
58
+ const localVarQueryParameter = {} as any;
59
+
60
+ // authentication keycloak_auth required
61
+ // http bearer authentication required
62
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
63
+
64
+ if (token !== undefined) {
65
+ localVarQueryParameter['token'] = token;
66
+ }
67
+
68
+ localVarHeaderParameter['Content-Type'] = 'application/json';
69
+ localVarHeaderParameter['Accept'] = 'application/json';
70
+
71
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
72
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
73
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
74
+ localVarRequestOptions.data = serializeDataIfNeeded(declineSignatureRequest, localVarRequestOptions, configuration)
75
+
76
+ return {
77
+ url: toPathString(localVarUrlObj),
78
+ options: localVarRequestOptions,
79
+ };
80
+ },
81
+ /**
82
+ *
83
+ * @summary Stream the source PDF for signing
84
+ * @param {string} token
85
+ * @param {*} [options] Override http request option.
86
+ * @throws {RequiredError}
87
+ */
88
+ document: async (token: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
89
+ // verify required parameter 'token' is not null or undefined
90
+ assertParamExists('document', 'token', token)
91
+ const localVarPath = `/api/v1/public/signatures/document`;
92
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
93
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
94
+ let baseOptions;
95
+ if (configuration) {
96
+ baseOptions = configuration.baseOptions;
97
+ }
98
+
99
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
100
+ const localVarHeaderParameter = {} as any;
101
+ const localVarQueryParameter = {} as any;
102
+
103
+ // authentication keycloak_auth required
104
+ // http bearer authentication required
105
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
106
+
107
+ if (token !== undefined) {
108
+ localVarQueryParameter['token'] = token;
109
+ }
110
+
111
+ localVarHeaderParameter['Accept'] = 'application/pdf';
112
+
113
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
114
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
115
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
116
+
117
+ return {
118
+ url: toPathString(localVarUrlObj),
119
+ options: localVarRequestOptions,
120
+ };
121
+ },
122
+ /**
123
+ *
124
+ * @summary Record that the recipient opened the document
125
+ * @param {string} token
126
+ * @param {string} [userAgent]
127
+ * @param {*} [options] Override http request option.
128
+ * @throws {RequiredError}
129
+ */
130
+ markViewed: async (token: string, userAgent?: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
131
+ // verify required parameter 'token' is not null or undefined
132
+ assertParamExists('markViewed', 'token', token)
133
+ const localVarPath = `/api/v1/public/signatures/viewed`;
134
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
135
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
136
+ let baseOptions;
137
+ if (configuration) {
138
+ baseOptions = configuration.baseOptions;
139
+ }
140
+
141
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
142
+ const localVarHeaderParameter = {} as any;
143
+ const localVarQueryParameter = {} as any;
144
+
145
+ // authentication keycloak_auth required
146
+ // http bearer authentication required
147
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
148
+
149
+ if (token !== undefined) {
150
+ localVarQueryParameter['token'] = token;
151
+ }
152
+
153
+ localVarHeaderParameter['Accept'] = 'application/json';
154
+
155
+ if (userAgent != null) {
156
+ localVarHeaderParameter['User-Agent'] = String(userAgent);
157
+ }
158
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
159
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
160
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
161
+
162
+ return {
163
+ url: toPathString(localVarUrlObj),
164
+ options: localVarRequestOptions,
165
+ };
166
+ },
167
+ /**
168
+ *
169
+ * @summary Send a one-time access code to the recipient (EMAIL_OTP / SMS_OTP)
170
+ * @param {string} token
171
+ * @param {*} [options] Override http request option.
172
+ * @throws {RequiredError}
173
+ */
174
+ requestOtp: async (token: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
175
+ // verify required parameter 'token' is not null or undefined
176
+ assertParamExists('requestOtp', 'token', token)
177
+ const localVarPath = `/api/v1/public/signatures/otp/request`;
178
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
179
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
180
+ let baseOptions;
181
+ if (configuration) {
182
+ baseOptions = configuration.baseOptions;
183
+ }
184
+
185
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
186
+ const localVarHeaderParameter = {} as any;
187
+ const localVarQueryParameter = {} as any;
188
+
189
+ // authentication keycloak_auth required
190
+ // http bearer authentication required
191
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
192
+
193
+ if (token !== undefined) {
194
+ localVarQueryParameter['token'] = token;
195
+ }
196
+
197
+
198
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
199
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
200
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
201
+
202
+ return {
203
+ url: toPathString(localVarUrlObj),
204
+ options: localVarRequestOptions,
205
+ };
206
+ },
207
+ /**
208
+ *
209
+ * @summary Submit the recipient\'s fields and sign
210
+ * @param {string} token
211
+ * @param {ApplySignatureRequest} applySignatureRequest
212
+ * @param {string} [userAgent]
213
+ * @param {*} [options] Override http request option.
214
+ * @throws {RequiredError}
215
+ */
216
+ sign: async (token: string, applySignatureRequest: ApplySignatureRequest, userAgent?: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
217
+ // verify required parameter 'token' is not null or undefined
218
+ assertParamExists('sign', 'token', token)
219
+ // verify required parameter 'applySignatureRequest' is not null or undefined
220
+ assertParamExists('sign', 'applySignatureRequest', applySignatureRequest)
221
+ const localVarPath = `/api/v1/public/signatures/sign`;
222
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
223
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
224
+ let baseOptions;
225
+ if (configuration) {
226
+ baseOptions = configuration.baseOptions;
227
+ }
228
+
229
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
230
+ const localVarHeaderParameter = {} as any;
231
+ const localVarQueryParameter = {} as any;
232
+
233
+ // authentication keycloak_auth required
234
+ // http bearer authentication required
235
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
236
+
237
+ if (token !== undefined) {
238
+ localVarQueryParameter['token'] = token;
239
+ }
240
+
241
+ localVarHeaderParameter['Content-Type'] = 'application/json';
242
+ localVarHeaderParameter['Accept'] = 'application/json';
243
+
244
+ if (userAgent != null) {
245
+ localVarHeaderParameter['User-Agent'] = String(userAgent);
246
+ }
247
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
248
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
249
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
250
+ localVarRequestOptions.data = serializeDataIfNeeded(applySignatureRequest, localVarRequestOptions, configuration)
251
+
252
+ return {
253
+ url: toPathString(localVarUrlObj),
254
+ options: localVarRequestOptions,
255
+ };
256
+ },
257
+ /**
258
+ *
259
+ * @summary Verify the one-time access code
260
+ * @param {string} token
261
+ * @param {VerifyOtpRequest} verifyOtpRequest
262
+ * @param {*} [options] Override http request option.
263
+ * @throws {RequiredError}
264
+ */
265
+ verifyOtp: async (token: string, verifyOtpRequest: VerifyOtpRequest, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
266
+ // verify required parameter 'token' is not null or undefined
267
+ assertParamExists('verifyOtp', 'token', token)
268
+ // verify required parameter 'verifyOtpRequest' is not null or undefined
269
+ assertParamExists('verifyOtp', 'verifyOtpRequest', verifyOtpRequest)
270
+ const localVarPath = `/api/v1/public/signatures/otp/verify`;
271
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
272
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
273
+ let baseOptions;
274
+ if (configuration) {
275
+ baseOptions = configuration.baseOptions;
276
+ }
277
+
278
+ const localVarRequestOptions = { method: 'POST', ...baseOptions, ...options};
279
+ const localVarHeaderParameter = {} as any;
280
+ const localVarQueryParameter = {} as any;
281
+
282
+ // authentication keycloak_auth required
283
+ // http bearer authentication required
284
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
285
+
286
+ if (token !== undefined) {
287
+ localVarQueryParameter['token'] = token;
288
+ }
289
+
290
+ localVarHeaderParameter['Content-Type'] = 'application/json';
291
+ localVarHeaderParameter['Accept'] = 'application/json';
292
+
293
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
294
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
295
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
296
+ localVarRequestOptions.data = serializeDataIfNeeded(verifyOtpRequest, localVarRequestOptions, configuration)
297
+
298
+ return {
299
+ url: toPathString(localVarUrlObj),
300
+ options: localVarRequestOptions,
301
+ };
302
+ },
303
+ /**
304
+ *
305
+ * @summary Resolve a signing token to its envelope view
306
+ * @param {string} token
307
+ * @param {*} [options] Override http request option.
308
+ * @throws {RequiredError}
309
+ */
310
+ view: async (token: string, options: RawAxiosRequestConfig = {}): Promise<RequestArgs> => {
311
+ // verify required parameter 'token' is not null or undefined
312
+ assertParamExists('view', 'token', token)
313
+ const localVarPath = `/api/v1/public/signatures`;
314
+ // use dummy base URL string because the URL constructor only accepts absolute URLs.
315
+ const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
316
+ let baseOptions;
317
+ if (configuration) {
318
+ baseOptions = configuration.baseOptions;
319
+ }
320
+
321
+ const localVarRequestOptions = { method: 'GET', ...baseOptions, ...options};
322
+ const localVarHeaderParameter = {} as any;
323
+ const localVarQueryParameter = {} as any;
324
+
325
+ // authentication keycloak_auth required
326
+ // http bearer authentication required
327
+ await setBearerAuthToObject(localVarHeaderParameter, configuration)
328
+
329
+ if (token !== undefined) {
330
+ localVarQueryParameter['token'] = token;
331
+ }
332
+
333
+ localVarHeaderParameter['Accept'] = 'application/json';
334
+
335
+ setSearchParams(localVarUrlObj, localVarQueryParameter);
336
+ let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
337
+ localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...options.headers};
338
+
339
+ return {
340
+ url: toPathString(localVarUrlObj),
341
+ options: localVarRequestOptions,
342
+ };
343
+ },
344
+ }
345
+ };
346
+
347
+ /**
348
+ * ESignPublicApi - functional programming interface
349
+ */
350
+ export const ESignPublicApiFp = function(configuration?: Configuration) {
351
+ const localVarAxiosParamCreator = ESignPublicApiAxiosParamCreator(configuration)
352
+ return {
353
+ /**
354
+ *
355
+ * @summary Decline to sign (voids the envelope)
356
+ * @param {string} token
357
+ * @param {DeclineSignatureRequest} [declineSignatureRequest]
358
+ * @param {*} [options] Override http request option.
359
+ * @throws {RequiredError}
360
+ */
361
+ async decline(token: string, declineSignatureRequest?: DeclineSignatureRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<PublicSignatureView>> {
362
+ const localVarAxiosArgs = await localVarAxiosParamCreator.decline(token, declineSignatureRequest, options);
363
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
364
+ const localVarOperationServerBasePath = operationServerMap['ESignPublicApi.decline']?.[localVarOperationServerIndex]?.url;
365
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
366
+ },
367
+ /**
368
+ *
369
+ * @summary Stream the source PDF for signing
370
+ * @param {string} token
371
+ * @param {*} [options] Override http request option.
372
+ * @throws {RequiredError}
373
+ */
374
+ async document(token: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<File>> {
375
+ const localVarAxiosArgs = await localVarAxiosParamCreator.document(token, options);
376
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
377
+ const localVarOperationServerBasePath = operationServerMap['ESignPublicApi.document']?.[localVarOperationServerIndex]?.url;
378
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
379
+ },
380
+ /**
381
+ *
382
+ * @summary Record that the recipient opened the document
383
+ * @param {string} token
384
+ * @param {string} [userAgent]
385
+ * @param {*} [options] Override http request option.
386
+ * @throws {RequiredError}
387
+ */
388
+ async markViewed(token: string, userAgent?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<PublicSignatureView>> {
389
+ const localVarAxiosArgs = await localVarAxiosParamCreator.markViewed(token, userAgent, options);
390
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
391
+ const localVarOperationServerBasePath = operationServerMap['ESignPublicApi.markViewed']?.[localVarOperationServerIndex]?.url;
392
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
393
+ },
394
+ /**
395
+ *
396
+ * @summary Send a one-time access code to the recipient (EMAIL_OTP / SMS_OTP)
397
+ * @param {string} token
398
+ * @param {*} [options] Override http request option.
399
+ * @throws {RequiredError}
400
+ */
401
+ async requestOtp(token: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
402
+ const localVarAxiosArgs = await localVarAxiosParamCreator.requestOtp(token, options);
403
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
404
+ const localVarOperationServerBasePath = operationServerMap['ESignPublicApi.requestOtp']?.[localVarOperationServerIndex]?.url;
405
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
406
+ },
407
+ /**
408
+ *
409
+ * @summary Submit the recipient\'s fields and sign
410
+ * @param {string} token
411
+ * @param {ApplySignatureRequest} applySignatureRequest
412
+ * @param {string} [userAgent]
413
+ * @param {*} [options] Override http request option.
414
+ * @throws {RequiredError}
415
+ */
416
+ async sign(token: string, applySignatureRequest: ApplySignatureRequest, userAgent?: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<PublicSignatureView>> {
417
+ const localVarAxiosArgs = await localVarAxiosParamCreator.sign(token, applySignatureRequest, userAgent, options);
418
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
419
+ const localVarOperationServerBasePath = operationServerMap['ESignPublicApi.sign']?.[localVarOperationServerIndex]?.url;
420
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
421
+ },
422
+ /**
423
+ *
424
+ * @summary Verify the one-time access code
425
+ * @param {string} token
426
+ * @param {VerifyOtpRequest} verifyOtpRequest
427
+ * @param {*} [options] Override http request option.
428
+ * @throws {RequiredError}
429
+ */
430
+ async verifyOtp(token: string, verifyOtpRequest: VerifyOtpRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<PublicSignatureView>> {
431
+ const localVarAxiosArgs = await localVarAxiosParamCreator.verifyOtp(token, verifyOtpRequest, options);
432
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
433
+ const localVarOperationServerBasePath = operationServerMap['ESignPublicApi.verifyOtp']?.[localVarOperationServerIndex]?.url;
434
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
435
+ },
436
+ /**
437
+ *
438
+ * @summary Resolve a signing token to its envelope view
439
+ * @param {string} token
440
+ * @param {*} [options] Override http request option.
441
+ * @throws {RequiredError}
442
+ */
443
+ async view(token: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<PublicSignatureView>> {
444
+ const localVarAxiosArgs = await localVarAxiosParamCreator.view(token, options);
445
+ const localVarOperationServerIndex = configuration?.serverIndex ?? 0;
446
+ const localVarOperationServerBasePath = operationServerMap['ESignPublicApi.view']?.[localVarOperationServerIndex]?.url;
447
+ return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
448
+ },
449
+ }
450
+ };
451
+
452
+ /**
453
+ * ESignPublicApi - factory interface
454
+ */
455
+ export const ESignPublicApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) {
456
+ const localVarFp = ESignPublicApiFp(configuration)
457
+ return {
458
+ /**
459
+ *
460
+ * @summary Decline to sign (voids the envelope)
461
+ * @param {string} token
462
+ * @param {DeclineSignatureRequest} [declineSignatureRequest]
463
+ * @param {*} [options] Override http request option.
464
+ * @throws {RequiredError}
465
+ */
466
+ decline(token: string, declineSignatureRequest?: DeclineSignatureRequest, options?: RawAxiosRequestConfig): AxiosPromise<PublicSignatureView> {
467
+ return localVarFp.decline(token, declineSignatureRequest, options).then((request) => request(axios, basePath));
468
+ },
469
+ /**
470
+ *
471
+ * @summary Stream the source PDF for signing
472
+ * @param {string} token
473
+ * @param {*} [options] Override http request option.
474
+ * @throws {RequiredError}
475
+ */
476
+ document(token: string, options?: RawAxiosRequestConfig): AxiosPromise<File> {
477
+ return localVarFp.document(token, options).then((request) => request(axios, basePath));
478
+ },
479
+ /**
480
+ *
481
+ * @summary Record that the recipient opened the document
482
+ * @param {string} token
483
+ * @param {string} [userAgent]
484
+ * @param {*} [options] Override http request option.
485
+ * @throws {RequiredError}
486
+ */
487
+ markViewed(token: string, userAgent?: string, options?: RawAxiosRequestConfig): AxiosPromise<PublicSignatureView> {
488
+ return localVarFp.markViewed(token, userAgent, options).then((request) => request(axios, basePath));
489
+ },
490
+ /**
491
+ *
492
+ * @summary Send a one-time access code to the recipient (EMAIL_OTP / SMS_OTP)
493
+ * @param {string} token
494
+ * @param {*} [options] Override http request option.
495
+ * @throws {RequiredError}
496
+ */
497
+ requestOtp(token: string, options?: RawAxiosRequestConfig): AxiosPromise<void> {
498
+ return localVarFp.requestOtp(token, options).then((request) => request(axios, basePath));
499
+ },
500
+ /**
501
+ *
502
+ * @summary Submit the recipient\'s fields and sign
503
+ * @param {string} token
504
+ * @param {ApplySignatureRequest} applySignatureRequest
505
+ * @param {string} [userAgent]
506
+ * @param {*} [options] Override http request option.
507
+ * @throws {RequiredError}
508
+ */
509
+ sign(token: string, applySignatureRequest: ApplySignatureRequest, userAgent?: string, options?: RawAxiosRequestConfig): AxiosPromise<PublicSignatureView> {
510
+ return localVarFp.sign(token, applySignatureRequest, userAgent, options).then((request) => request(axios, basePath));
511
+ },
512
+ /**
513
+ *
514
+ * @summary Verify the one-time access code
515
+ * @param {string} token
516
+ * @param {VerifyOtpRequest} verifyOtpRequest
517
+ * @param {*} [options] Override http request option.
518
+ * @throws {RequiredError}
519
+ */
520
+ verifyOtp(token: string, verifyOtpRequest: VerifyOtpRequest, options?: RawAxiosRequestConfig): AxiosPromise<PublicSignatureView> {
521
+ return localVarFp.verifyOtp(token, verifyOtpRequest, options).then((request) => request(axios, basePath));
522
+ },
523
+ /**
524
+ *
525
+ * @summary Resolve a signing token to its envelope view
526
+ * @param {string} token
527
+ * @param {*} [options] Override http request option.
528
+ * @throws {RequiredError}
529
+ */
530
+ view(token: string, options?: RawAxiosRequestConfig): AxiosPromise<PublicSignatureView> {
531
+ return localVarFp.view(token, options).then((request) => request(axios, basePath));
532
+ },
533
+ };
534
+ };
535
+
536
+ /**
537
+ * ESignPublicApi - object-oriented interface
538
+ */
539
+ export class ESignPublicApi extends BaseAPI {
540
+ /**
541
+ *
542
+ * @summary Decline to sign (voids the envelope)
543
+ * @param {string} token
544
+ * @param {DeclineSignatureRequest} [declineSignatureRequest]
545
+ * @param {*} [options] Override http request option.
546
+ * @throws {RequiredError}
547
+ */
548
+ public decline(token: string, declineSignatureRequest?: DeclineSignatureRequest, options?: RawAxiosRequestConfig) {
549
+ return ESignPublicApiFp(this.configuration).decline(token, declineSignatureRequest, options).then((request) => request(this.axios, this.basePath));
550
+ }
551
+
552
+ /**
553
+ *
554
+ * @summary Stream the source PDF for signing
555
+ * @param {string} token
556
+ * @param {*} [options] Override http request option.
557
+ * @throws {RequiredError}
558
+ */
559
+ public document(token: string, options?: RawAxiosRequestConfig) {
560
+ return ESignPublicApiFp(this.configuration).document(token, options).then((request) => request(this.axios, this.basePath));
561
+ }
562
+
563
+ /**
564
+ *
565
+ * @summary Record that the recipient opened the document
566
+ * @param {string} token
567
+ * @param {string} [userAgent]
568
+ * @param {*} [options] Override http request option.
569
+ * @throws {RequiredError}
570
+ */
571
+ public markViewed(token: string, userAgent?: string, options?: RawAxiosRequestConfig) {
572
+ return ESignPublicApiFp(this.configuration).markViewed(token, userAgent, options).then((request) => request(this.axios, this.basePath));
573
+ }
574
+
575
+ /**
576
+ *
577
+ * @summary Send a one-time access code to the recipient (EMAIL_OTP / SMS_OTP)
578
+ * @param {string} token
579
+ * @param {*} [options] Override http request option.
580
+ * @throws {RequiredError}
581
+ */
582
+ public requestOtp(token: string, options?: RawAxiosRequestConfig) {
583
+ return ESignPublicApiFp(this.configuration).requestOtp(token, options).then((request) => request(this.axios, this.basePath));
584
+ }
585
+
586
+ /**
587
+ *
588
+ * @summary Submit the recipient\'s fields and sign
589
+ * @param {string} token
590
+ * @param {ApplySignatureRequest} applySignatureRequest
591
+ * @param {string} [userAgent]
592
+ * @param {*} [options] Override http request option.
593
+ * @throws {RequiredError}
594
+ */
595
+ public sign(token: string, applySignatureRequest: ApplySignatureRequest, userAgent?: string, options?: RawAxiosRequestConfig) {
596
+ return ESignPublicApiFp(this.configuration).sign(token, applySignatureRequest, userAgent, options).then((request) => request(this.axios, this.basePath));
597
+ }
598
+
599
+ /**
600
+ *
601
+ * @summary Verify the one-time access code
602
+ * @param {string} token
603
+ * @param {VerifyOtpRequest} verifyOtpRequest
604
+ * @param {*} [options] Override http request option.
605
+ * @throws {RequiredError}
606
+ */
607
+ public verifyOtp(token: string, verifyOtpRequest: VerifyOtpRequest, options?: RawAxiosRequestConfig) {
608
+ return ESignPublicApiFp(this.configuration).verifyOtp(token, verifyOtpRequest, options).then((request) => request(this.axios, this.basePath));
609
+ }
610
+
611
+ /**
612
+ *
613
+ * @summary Resolve a signing token to its envelope view
614
+ * @param {string} token
615
+ * @param {*} [options] Override http request option.
616
+ * @throws {RequiredError}
617
+ */
618
+ public view(token: string, options?: RawAxiosRequestConfig) {
619
+ return ESignPublicApiFp(this.configuration).view(token, options).then((request) => request(this.axios, this.basePath));
620
+ }
621
+ }
622
+