@emilgroup/document-sdk-node 1.24.1-beta.0 → 1.26.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/README.md +2 -2
- package/api/documents-api.ts +21 -39
- package/api/product-documents-api.ts +15 -17
- package/dist/api/documents-api.d.ts +15 -24
- package/dist/api/documents-api.js +15 -25
- package/dist/api/product-documents-api.d.ts +12 -12
- package/dist/api/product-documents-api.js +9 -11
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -17,11 +17,11 @@ Although this package can be used in both TypeScript and JavaScript, it is inten
|
|
|
17
17
|
Navigate to the folder of your consuming project and run one of the following commands:
|
|
18
18
|
|
|
19
19
|
```
|
|
20
|
-
npm install @emilgroup/document-sdk-node@1.
|
|
20
|
+
npm install @emilgroup/document-sdk-node@1.26.0 --save
|
|
21
21
|
```
|
|
22
22
|
or
|
|
23
23
|
```
|
|
24
|
-
yarn add @emilgroup/document-sdk-node@1.
|
|
24
|
+
yarn add @emilgroup/document-sdk-node@1.26.0
|
|
25
25
|
```
|
|
26
26
|
|
|
27
27
|
And then you can import `DocumentsApi`.
|
package/api/documents-api.ts
CHANGED
|
@@ -179,16 +179,14 @@ export const DocumentsApiAxiosParamCreator = function (configuration?: Configura
|
|
|
179
179
|
* This will return a presigned URL to download the document.
|
|
180
180
|
* @summary Fetches a document download URL
|
|
181
181
|
* @param {string} code Document code
|
|
182
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
183
182
|
* @param {string} [authorization] Bearer Token
|
|
183
|
+
* @param {'attachment' | 'inline'} [contentDisposition] Content disposition override. Default will be depending on the document type.
|
|
184
184
|
* @param {*} [options] Override http request option.
|
|
185
185
|
* @throws {RequiredError}
|
|
186
186
|
*/
|
|
187
|
-
getDocumentDownloadUrl: async (code: string, contentDisposition
|
|
187
|
+
getDocumentDownloadUrl: async (code: string, authorization?: string, contentDisposition?: 'attachment' | 'inline', options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
188
188
|
// verify required parameter 'code' is not null or undefined
|
|
189
189
|
assertParamExists('getDocumentDownloadUrl', 'code', code)
|
|
190
|
-
// verify required parameter 'contentDisposition' is not null or undefined
|
|
191
|
-
assertParamExists('getDocumentDownloadUrl', 'contentDisposition', contentDisposition)
|
|
192
190
|
const localVarPath = `/documentservice/v1/documents/{code}/download-url`
|
|
193
191
|
.replace(`{${"code"}}`, encodeURIComponent(String(code)));
|
|
194
192
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
@@ -231,16 +229,13 @@ export const DocumentsApiAxiosParamCreator = function (configuration?: Configura
|
|
|
231
229
|
* This will return a presigned URL for a random S3 key
|
|
232
230
|
* @summary Fetches a presigned URL for a S3 key
|
|
233
231
|
* @param {string} s3Key Key for the file in S3 bucket to create the presigned download URL for
|
|
234
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
235
232
|
* @param {string} [authorization] Bearer Token
|
|
236
233
|
* @param {*} [options] Override http request option.
|
|
237
234
|
* @throws {RequiredError}
|
|
238
235
|
*/
|
|
239
|
-
getSignedS3keyUrl: async (s3Key: string,
|
|
236
|
+
getSignedS3keyUrl: async (s3Key: string, authorization?: string, options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
240
237
|
// verify required parameter 's3Key' is not null or undefined
|
|
241
238
|
assertParamExists('getSignedS3keyUrl', 's3Key', s3Key)
|
|
242
|
-
// verify required parameter 'contentDisposition' is not null or undefined
|
|
243
|
-
assertParamExists('getSignedS3keyUrl', 'contentDisposition', contentDisposition)
|
|
244
239
|
const localVarPath = `/documentservice/v1/documents/signed-s3-url`;
|
|
245
240
|
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
246
241
|
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
@@ -263,10 +258,6 @@ export const DocumentsApiAxiosParamCreator = function (configuration?: Configura
|
|
|
263
258
|
localVarQueryParameter['s3Key'] = s3Key;
|
|
264
259
|
}
|
|
265
260
|
|
|
266
|
-
if (contentDisposition !== undefined) {
|
|
267
|
-
localVarQueryParameter['contentDisposition'] = contentDisposition;
|
|
268
|
-
}
|
|
269
|
-
|
|
270
261
|
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
271
262
|
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
272
263
|
}
|
|
@@ -459,26 +450,25 @@ export const DocumentsApiFp = function(configuration?: Configuration) {
|
|
|
459
450
|
* This will return a presigned URL to download the document.
|
|
460
451
|
* @summary Fetches a document download URL
|
|
461
452
|
* @param {string} code Document code
|
|
462
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
463
453
|
* @param {string} [authorization] Bearer Token
|
|
454
|
+
* @param {'attachment' | 'inline'} [contentDisposition] Content disposition override. Default will be depending on the document type.
|
|
464
455
|
* @param {*} [options] Override http request option.
|
|
465
456
|
* @throws {RequiredError}
|
|
466
457
|
*/
|
|
467
|
-
async getDocumentDownloadUrl(code: string, contentDisposition
|
|
468
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.getDocumentDownloadUrl(code,
|
|
458
|
+
async getDocumentDownloadUrl(code: string, authorization?: string, contentDisposition?: 'attachment' | 'inline', options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
|
|
459
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getDocumentDownloadUrl(code, authorization, contentDisposition, options);
|
|
469
460
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
470
461
|
},
|
|
471
462
|
/**
|
|
472
463
|
* This will return a presigned URL for a random S3 key
|
|
473
464
|
* @summary Fetches a presigned URL for a S3 key
|
|
474
465
|
* @param {string} s3Key Key for the file in S3 bucket to create the presigned download URL for
|
|
475
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
476
466
|
* @param {string} [authorization] Bearer Token
|
|
477
467
|
* @param {*} [options] Override http request option.
|
|
478
468
|
* @throws {RequiredError}
|
|
479
469
|
*/
|
|
480
|
-
async getSignedS3keyUrl(s3Key: string,
|
|
481
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.getSignedS3keyUrl(s3Key,
|
|
470
|
+
async getSignedS3keyUrl(s3Key: string, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
|
|
471
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.getSignedS3keyUrl(s3Key, authorization, options);
|
|
482
472
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
483
473
|
},
|
|
484
474
|
/**
|
|
@@ -559,25 +549,24 @@ export const DocumentsApiFactory = function (configuration?: Configuration, base
|
|
|
559
549
|
* This will return a presigned URL to download the document.
|
|
560
550
|
* @summary Fetches a document download URL
|
|
561
551
|
* @param {string} code Document code
|
|
562
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
563
552
|
* @param {string} [authorization] Bearer Token
|
|
553
|
+
* @param {'attachment' | 'inline'} [contentDisposition] Content disposition override. Default will be depending on the document type.
|
|
564
554
|
* @param {*} [options] Override http request option.
|
|
565
555
|
* @throws {RequiredError}
|
|
566
556
|
*/
|
|
567
|
-
getDocumentDownloadUrl(code: string, contentDisposition
|
|
568
|
-
return localVarFp.getDocumentDownloadUrl(code,
|
|
557
|
+
getDocumentDownloadUrl(code: string, authorization?: string, contentDisposition?: 'attachment' | 'inline', options?: any): AxiosPromise<void> {
|
|
558
|
+
return localVarFp.getDocumentDownloadUrl(code, authorization, contentDisposition, options).then((request) => request(axios, basePath));
|
|
569
559
|
},
|
|
570
560
|
/**
|
|
571
561
|
* This will return a presigned URL for a random S3 key
|
|
572
562
|
* @summary Fetches a presigned URL for a S3 key
|
|
573
563
|
* @param {string} s3Key Key for the file in S3 bucket to create the presigned download URL for
|
|
574
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
575
564
|
* @param {string} [authorization] Bearer Token
|
|
576
565
|
* @param {*} [options] Override http request option.
|
|
577
566
|
* @throws {RequiredError}
|
|
578
567
|
*/
|
|
579
|
-
getSignedS3keyUrl(s3Key: string,
|
|
580
|
-
return localVarFp.getSignedS3keyUrl(s3Key,
|
|
568
|
+
getSignedS3keyUrl(s3Key: string, authorization?: string, options?: any): AxiosPromise<void> {
|
|
569
|
+
return localVarFp.getSignedS3keyUrl(s3Key, authorization, options).then((request) => request(axios, basePath));
|
|
581
570
|
},
|
|
582
571
|
/**
|
|
583
572
|
* Returns a list of documents you have previously created. The documents are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
|
|
@@ -688,18 +677,18 @@ export interface DocumentsApiGetDocumentDownloadUrlRequest {
|
|
|
688
677
|
readonly code: string
|
|
689
678
|
|
|
690
679
|
/**
|
|
691
|
-
*
|
|
692
|
-
* @type {
|
|
680
|
+
* Bearer Token
|
|
681
|
+
* @type {string}
|
|
693
682
|
* @memberof DocumentsApiGetDocumentDownloadUrl
|
|
694
683
|
*/
|
|
695
|
-
readonly
|
|
684
|
+
readonly authorization?: string
|
|
696
685
|
|
|
697
686
|
/**
|
|
698
|
-
*
|
|
699
|
-
* @type {
|
|
687
|
+
* Content disposition override. Default will be depending on the document type.
|
|
688
|
+
* @type {'attachment' | 'inline'}
|
|
700
689
|
* @memberof DocumentsApiGetDocumentDownloadUrl
|
|
701
690
|
*/
|
|
702
|
-
readonly
|
|
691
|
+
readonly contentDisposition?: 'attachment' | 'inline'
|
|
703
692
|
}
|
|
704
693
|
|
|
705
694
|
/**
|
|
@@ -715,13 +704,6 @@ export interface DocumentsApiGetSignedS3keyUrlRequest {
|
|
|
715
704
|
*/
|
|
716
705
|
readonly s3Key: string
|
|
717
706
|
|
|
718
|
-
/**
|
|
719
|
-
* Content disposition override. Default will be depending on the document type.
|
|
720
|
-
* @type {'attachment' | 'inline'}
|
|
721
|
-
* @memberof DocumentsApiGetSignedS3keyUrl
|
|
722
|
-
*/
|
|
723
|
-
readonly contentDisposition: 'attachment' | 'inline'
|
|
724
|
-
|
|
725
707
|
/**
|
|
726
708
|
* Bearer Token
|
|
727
709
|
* @type {string}
|
|
@@ -873,7 +855,7 @@ export class DocumentsApi extends BaseAPI {
|
|
|
873
855
|
* @memberof DocumentsApi
|
|
874
856
|
*/
|
|
875
857
|
public getDocumentDownloadUrl(requestParameters: DocumentsApiGetDocumentDownloadUrlRequest, options?: AxiosRequestConfig) {
|
|
876
|
-
return DocumentsApiFp(this.configuration).getDocumentDownloadUrl(requestParameters.code, requestParameters.
|
|
858
|
+
return DocumentsApiFp(this.configuration).getDocumentDownloadUrl(requestParameters.code, requestParameters.authorization, requestParameters.contentDisposition, options).then((request) => request(this.axios, this.basePath));
|
|
877
859
|
}
|
|
878
860
|
|
|
879
861
|
/**
|
|
@@ -885,7 +867,7 @@ export class DocumentsApi extends BaseAPI {
|
|
|
885
867
|
* @memberof DocumentsApi
|
|
886
868
|
*/
|
|
887
869
|
public getSignedS3keyUrl(requestParameters: DocumentsApiGetSignedS3keyUrlRequest, options?: AxiosRequestConfig) {
|
|
888
|
-
return DocumentsApiFp(this.configuration).getSignedS3keyUrl(requestParameters.s3Key, requestParameters.
|
|
870
|
+
return DocumentsApiFp(this.configuration).getSignedS3keyUrl(requestParameters.s3Key, requestParameters.authorization, options).then((request) => request(this.axios, this.basePath));
|
|
889
871
|
}
|
|
890
872
|
|
|
891
873
|
/**
|
|
@@ -88,18 +88,16 @@ export const ProductDocumentsApiAxiosParamCreator = function (configuration?: Co
|
|
|
88
88
|
* @summary Get pre-signed url for downloading product document
|
|
89
89
|
* @param {string} productSlug Product slug
|
|
90
90
|
* @param {string} code Product document code
|
|
91
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
92
91
|
* @param {string} [authorization] Bearer Token
|
|
92
|
+
* @param {'attachment' | 'inline'} [contentDisposition] Content disposition override. Default will be depending on the document type.
|
|
93
93
|
* @param {*} [options] Override http request option.
|
|
94
94
|
* @throws {RequiredError}
|
|
95
95
|
*/
|
|
96
|
-
downloadProductDocument: async (productSlug: string, code: string, contentDisposition
|
|
96
|
+
downloadProductDocument: async (productSlug: string, code: string, authorization?: string, contentDisposition?: 'attachment' | 'inline', options: AxiosRequestConfig = {}): Promise<RequestArgs> => {
|
|
97
97
|
// verify required parameter 'productSlug' is not null or undefined
|
|
98
98
|
assertParamExists('downloadProductDocument', 'productSlug', productSlug)
|
|
99
99
|
// verify required parameter 'code' is not null or undefined
|
|
100
100
|
assertParamExists('downloadProductDocument', 'code', code)
|
|
101
|
-
// verify required parameter 'contentDisposition' is not null or undefined
|
|
102
|
-
assertParamExists('downloadProductDocument', 'contentDisposition', contentDisposition)
|
|
103
101
|
const localVarPath = `/documentservice/v1/product-documents/{productSlug}/{code}/download-url`
|
|
104
102
|
.replace(`{${"productSlug"}}`, encodeURIComponent(String(productSlug)))
|
|
105
103
|
.replace(`{${"code"}}`, encodeURIComponent(String(code)));
|
|
@@ -347,13 +345,13 @@ export const ProductDocumentsApiFp = function(configuration?: Configuration) {
|
|
|
347
345
|
* @summary Get pre-signed url for downloading product document
|
|
348
346
|
* @param {string} productSlug Product slug
|
|
349
347
|
* @param {string} code Product document code
|
|
350
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
351
348
|
* @param {string} [authorization] Bearer Token
|
|
349
|
+
* @param {'attachment' | 'inline'} [contentDisposition] Content disposition override. Default will be depending on the document type.
|
|
352
350
|
* @param {*} [options] Override http request option.
|
|
353
351
|
* @throws {RequiredError}
|
|
354
352
|
*/
|
|
355
|
-
async downloadProductDocument(productSlug: string, code: string, contentDisposition
|
|
356
|
-
const localVarAxiosArgs = await localVarAxiosParamCreator.downloadProductDocument(productSlug, code,
|
|
353
|
+
async downloadProductDocument(productSlug: string, code: string, authorization?: string, contentDisposition?: 'attachment' | 'inline', options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>> {
|
|
354
|
+
const localVarAxiosArgs = await localVarAxiosParamCreator.downloadProductDocument(productSlug, code, authorization, contentDisposition, options);
|
|
357
355
|
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
|
|
358
356
|
},
|
|
359
357
|
/**
|
|
@@ -428,13 +426,13 @@ export const ProductDocumentsApiFactory = function (configuration?: Configuratio
|
|
|
428
426
|
* @summary Get pre-signed url for downloading product document
|
|
429
427
|
* @param {string} productSlug Product slug
|
|
430
428
|
* @param {string} code Product document code
|
|
431
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
432
429
|
* @param {string} [authorization] Bearer Token
|
|
430
|
+
* @param {'attachment' | 'inline'} [contentDisposition] Content disposition override. Default will be depending on the document type.
|
|
433
431
|
* @param {*} [options] Override http request option.
|
|
434
432
|
* @throws {RequiredError}
|
|
435
433
|
*/
|
|
436
|
-
downloadProductDocument(productSlug: string, code: string, contentDisposition
|
|
437
|
-
return localVarFp.downloadProductDocument(productSlug, code,
|
|
434
|
+
downloadProductDocument(productSlug: string, code: string, authorization?: string, contentDisposition?: 'attachment' | 'inline', options?: any): AxiosPromise<void> {
|
|
435
|
+
return localVarFp.downloadProductDocument(productSlug, code, authorization, contentDisposition, options).then((request) => request(axios, basePath));
|
|
438
436
|
},
|
|
439
437
|
/**
|
|
440
438
|
* Get a product document.
|
|
@@ -530,18 +528,18 @@ export interface ProductDocumentsApiDownloadProductDocumentRequest {
|
|
|
530
528
|
readonly code: string
|
|
531
529
|
|
|
532
530
|
/**
|
|
533
|
-
*
|
|
534
|
-
* @type {
|
|
531
|
+
* Bearer Token
|
|
532
|
+
* @type {string}
|
|
535
533
|
* @memberof ProductDocumentsApiDownloadProductDocument
|
|
536
534
|
*/
|
|
537
|
-
readonly
|
|
535
|
+
readonly authorization?: string
|
|
538
536
|
|
|
539
537
|
/**
|
|
540
|
-
*
|
|
541
|
-
* @type {
|
|
538
|
+
* Content disposition override. Default will be depending on the document type.
|
|
539
|
+
* @type {'attachment' | 'inline'}
|
|
542
540
|
* @memberof ProductDocumentsApiDownloadProductDocument
|
|
543
541
|
*/
|
|
544
|
-
readonly
|
|
542
|
+
readonly contentDisposition?: 'attachment' | 'inline'
|
|
545
543
|
}
|
|
546
544
|
|
|
547
545
|
/**
|
|
@@ -698,7 +696,7 @@ export class ProductDocumentsApi extends BaseAPI {
|
|
|
698
696
|
* @memberof ProductDocumentsApi
|
|
699
697
|
*/
|
|
700
698
|
public downloadProductDocument(requestParameters: ProductDocumentsApiDownloadProductDocumentRequest, options?: AxiosRequestConfig) {
|
|
701
|
-
return ProductDocumentsApiFp(this.configuration).downloadProductDocument(requestParameters.productSlug, requestParameters.code, requestParameters.
|
|
699
|
+
return ProductDocumentsApiFp(this.configuration).downloadProductDocument(requestParameters.productSlug, requestParameters.code, requestParameters.authorization, requestParameters.contentDisposition, options).then((request) => request(this.axios, this.basePath));
|
|
702
700
|
}
|
|
703
701
|
|
|
704
702
|
/**
|
|
@@ -51,22 +51,21 @@ export declare const DocumentsApiAxiosParamCreator: (configuration?: Configurati
|
|
|
51
51
|
* This will return a presigned URL to download the document.
|
|
52
52
|
* @summary Fetches a document download URL
|
|
53
53
|
* @param {string} code Document code
|
|
54
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
55
54
|
* @param {string} [authorization] Bearer Token
|
|
55
|
+
* @param {'attachment' | 'inline'} [contentDisposition] Content disposition override. Default will be depending on the document type.
|
|
56
56
|
* @param {*} [options] Override http request option.
|
|
57
57
|
* @throws {RequiredError}
|
|
58
58
|
*/
|
|
59
|
-
getDocumentDownloadUrl: (code: string, contentDisposition
|
|
59
|
+
getDocumentDownloadUrl: (code: string, authorization?: string, contentDisposition?: 'attachment' | 'inline', options?: AxiosRequestConfig) => Promise<RequestArgs>;
|
|
60
60
|
/**
|
|
61
61
|
* This will return a presigned URL for a random S3 key
|
|
62
62
|
* @summary Fetches a presigned URL for a S3 key
|
|
63
63
|
* @param {string} s3Key Key for the file in S3 bucket to create the presigned download URL for
|
|
64
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
65
64
|
* @param {string} [authorization] Bearer Token
|
|
66
65
|
* @param {*} [options] Override http request option.
|
|
67
66
|
* @throws {RequiredError}
|
|
68
67
|
*/
|
|
69
|
-
getSignedS3keyUrl: (s3Key: string,
|
|
68
|
+
getSignedS3keyUrl: (s3Key: string, authorization?: string, options?: AxiosRequestConfig) => Promise<RequestArgs>;
|
|
70
69
|
/**
|
|
71
70
|
* Returns a list of documents you have previously created. The documents are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
|
|
72
71
|
* @summary List documents
|
|
@@ -129,22 +128,21 @@ export declare const DocumentsApiFp: (configuration?: Configuration) => {
|
|
|
129
128
|
* This will return a presigned URL to download the document.
|
|
130
129
|
* @summary Fetches a document download URL
|
|
131
130
|
* @param {string} code Document code
|
|
132
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
133
131
|
* @param {string} [authorization] Bearer Token
|
|
132
|
+
* @param {'attachment' | 'inline'} [contentDisposition] Content disposition override. Default will be depending on the document type.
|
|
134
133
|
* @param {*} [options] Override http request option.
|
|
135
134
|
* @throws {RequiredError}
|
|
136
135
|
*/
|
|
137
|
-
getDocumentDownloadUrl(code: string, contentDisposition
|
|
136
|
+
getDocumentDownloadUrl(code: string, authorization?: string, contentDisposition?: 'attachment' | 'inline', options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
|
|
138
137
|
/**
|
|
139
138
|
* This will return a presigned URL for a random S3 key
|
|
140
139
|
* @summary Fetches a presigned URL for a S3 key
|
|
141
140
|
* @param {string} s3Key Key for the file in S3 bucket to create the presigned download URL for
|
|
142
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
143
141
|
* @param {string} [authorization] Bearer Token
|
|
144
142
|
* @param {*} [options] Override http request option.
|
|
145
143
|
* @throws {RequiredError}
|
|
146
144
|
*/
|
|
147
|
-
getSignedS3keyUrl(s3Key: string,
|
|
145
|
+
getSignedS3keyUrl(s3Key: string, authorization?: string, options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
|
|
148
146
|
/**
|
|
149
147
|
* Returns a list of documents you have previously created. The documents are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
|
|
150
148
|
* @summary List documents
|
|
@@ -207,22 +205,21 @@ export declare const DocumentsApiFactory: (configuration?: Configuration, basePa
|
|
|
207
205
|
* This will return a presigned URL to download the document.
|
|
208
206
|
* @summary Fetches a document download URL
|
|
209
207
|
* @param {string} code Document code
|
|
210
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
211
208
|
* @param {string} [authorization] Bearer Token
|
|
209
|
+
* @param {'attachment' | 'inline'} [contentDisposition] Content disposition override. Default will be depending on the document type.
|
|
212
210
|
* @param {*} [options] Override http request option.
|
|
213
211
|
* @throws {RequiredError}
|
|
214
212
|
*/
|
|
215
|
-
getDocumentDownloadUrl(code: string, contentDisposition
|
|
213
|
+
getDocumentDownloadUrl(code: string, authorization?: string, contentDisposition?: 'attachment' | 'inline', options?: any): AxiosPromise<void>;
|
|
216
214
|
/**
|
|
217
215
|
* This will return a presigned URL for a random S3 key
|
|
218
216
|
* @summary Fetches a presigned URL for a S3 key
|
|
219
217
|
* @param {string} s3Key Key for the file in S3 bucket to create the presigned download URL for
|
|
220
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
221
218
|
* @param {string} [authorization] Bearer Token
|
|
222
219
|
* @param {*} [options] Override http request option.
|
|
223
220
|
* @throws {RequiredError}
|
|
224
221
|
*/
|
|
225
|
-
getSignedS3keyUrl(s3Key: string,
|
|
222
|
+
getSignedS3keyUrl(s3Key: string, authorization?: string, options?: any): AxiosPromise<void>;
|
|
226
223
|
/**
|
|
227
224
|
* Returns a list of documents you have previously created. The documents are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
|
|
228
225
|
* @summary List documents
|
|
@@ -318,18 +315,18 @@ export interface DocumentsApiGetDocumentDownloadUrlRequest {
|
|
|
318
315
|
* @memberof DocumentsApiGetDocumentDownloadUrl
|
|
319
316
|
*/
|
|
320
317
|
readonly code: string;
|
|
321
|
-
/**
|
|
322
|
-
* Content disposition override. Default will be depending on the document type.
|
|
323
|
-
* @type {'attachment' | 'inline'}
|
|
324
|
-
* @memberof DocumentsApiGetDocumentDownloadUrl
|
|
325
|
-
*/
|
|
326
|
-
readonly contentDisposition: 'attachment' | 'inline';
|
|
327
318
|
/**
|
|
328
319
|
* Bearer Token
|
|
329
320
|
* @type {string}
|
|
330
321
|
* @memberof DocumentsApiGetDocumentDownloadUrl
|
|
331
322
|
*/
|
|
332
323
|
readonly authorization?: string;
|
|
324
|
+
/**
|
|
325
|
+
* Content disposition override. Default will be depending on the document type.
|
|
326
|
+
* @type {'attachment' | 'inline'}
|
|
327
|
+
* @memberof DocumentsApiGetDocumentDownloadUrl
|
|
328
|
+
*/
|
|
329
|
+
readonly contentDisposition?: 'attachment' | 'inline';
|
|
333
330
|
}
|
|
334
331
|
/**
|
|
335
332
|
* Request parameters for getSignedS3keyUrl operation in DocumentsApi.
|
|
@@ -343,12 +340,6 @@ export interface DocumentsApiGetSignedS3keyUrlRequest {
|
|
|
343
340
|
* @memberof DocumentsApiGetSignedS3keyUrl
|
|
344
341
|
*/
|
|
345
342
|
readonly s3Key: string;
|
|
346
|
-
/**
|
|
347
|
-
* Content disposition override. Default will be depending on the document type.
|
|
348
|
-
* @type {'attachment' | 'inline'}
|
|
349
|
-
* @memberof DocumentsApiGetSignedS3keyUrl
|
|
350
|
-
*/
|
|
351
|
-
readonly contentDisposition: 'attachment' | 'inline';
|
|
352
343
|
/**
|
|
353
344
|
* Bearer Token
|
|
354
345
|
* @type {string}
|
|
@@ -246,12 +246,12 @@ var DocumentsApiAxiosParamCreator = function (configuration) {
|
|
|
246
246
|
* This will return a presigned URL to download the document.
|
|
247
247
|
* @summary Fetches a document download URL
|
|
248
248
|
* @param {string} code Document code
|
|
249
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
250
249
|
* @param {string} [authorization] Bearer Token
|
|
250
|
+
* @param {'attachment' | 'inline'} [contentDisposition] Content disposition override. Default will be depending on the document type.
|
|
251
251
|
* @param {*} [options] Override http request option.
|
|
252
252
|
* @throws {RequiredError}
|
|
253
253
|
*/
|
|
254
|
-
getDocumentDownloadUrl: function (code,
|
|
254
|
+
getDocumentDownloadUrl: function (code, authorization, contentDisposition, options) {
|
|
255
255
|
if (options === void 0) { options = {}; }
|
|
256
256
|
return __awaiter(_this, void 0, void 0, function () {
|
|
257
257
|
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
@@ -260,8 +260,6 @@ var DocumentsApiAxiosParamCreator = function (configuration) {
|
|
|
260
260
|
case 0:
|
|
261
261
|
// verify required parameter 'code' is not null or undefined
|
|
262
262
|
(0, common_1.assertParamExists)('getDocumentDownloadUrl', 'code', code);
|
|
263
|
-
// verify required parameter 'contentDisposition' is not null or undefined
|
|
264
|
-
(0, common_1.assertParamExists)('getDocumentDownloadUrl', 'contentDisposition', contentDisposition);
|
|
265
263
|
localVarPath = "/documentservice/v1/documents/{code}/download-url"
|
|
266
264
|
.replace("{".concat("code", "}"), encodeURIComponent(String(code)));
|
|
267
265
|
localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
@@ -300,12 +298,11 @@ var DocumentsApiAxiosParamCreator = function (configuration) {
|
|
|
300
298
|
* This will return a presigned URL for a random S3 key
|
|
301
299
|
* @summary Fetches a presigned URL for a S3 key
|
|
302
300
|
* @param {string} s3Key Key for the file in S3 bucket to create the presigned download URL for
|
|
303
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
304
301
|
* @param {string} [authorization] Bearer Token
|
|
305
302
|
* @param {*} [options] Override http request option.
|
|
306
303
|
* @throws {RequiredError}
|
|
307
304
|
*/
|
|
308
|
-
getSignedS3keyUrl: function (s3Key,
|
|
305
|
+
getSignedS3keyUrl: function (s3Key, authorization, options) {
|
|
309
306
|
if (options === void 0) { options = {}; }
|
|
310
307
|
return __awaiter(_this, void 0, void 0, function () {
|
|
311
308
|
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
@@ -314,8 +311,6 @@ var DocumentsApiAxiosParamCreator = function (configuration) {
|
|
|
314
311
|
case 0:
|
|
315
312
|
// verify required parameter 's3Key' is not null or undefined
|
|
316
313
|
(0, common_1.assertParamExists)('getSignedS3keyUrl', 's3Key', s3Key);
|
|
317
|
-
// verify required parameter 'contentDisposition' is not null or undefined
|
|
318
|
-
(0, common_1.assertParamExists)('getSignedS3keyUrl', 'contentDisposition', contentDisposition);
|
|
319
314
|
localVarPath = "/documentservice/v1/documents/signed-s3-url";
|
|
320
315
|
localVarUrlObj = new url_1.URL(localVarPath, common_1.DUMMY_BASE_URL);
|
|
321
316
|
if (configuration) {
|
|
@@ -335,9 +330,6 @@ var DocumentsApiAxiosParamCreator = function (configuration) {
|
|
|
335
330
|
if (s3Key !== undefined) {
|
|
336
331
|
localVarQueryParameter['s3Key'] = s3Key;
|
|
337
332
|
}
|
|
338
|
-
if (contentDisposition !== undefined) {
|
|
339
|
-
localVarQueryParameter['contentDisposition'] = contentDisposition;
|
|
340
|
-
}
|
|
341
333
|
if (authorization !== undefined && authorization !== null || baseAccessToken !== undefined && baseAccessToken !== null) {
|
|
342
334
|
localVarHeaderParameter['Authorization'] = String(authorization ? authorization : baseAccessToken);
|
|
343
335
|
}
|
|
@@ -554,17 +546,17 @@ var DocumentsApiFp = function (configuration) {
|
|
|
554
546
|
* This will return a presigned URL to download the document.
|
|
555
547
|
* @summary Fetches a document download URL
|
|
556
548
|
* @param {string} code Document code
|
|
557
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
558
549
|
* @param {string} [authorization] Bearer Token
|
|
550
|
+
* @param {'attachment' | 'inline'} [contentDisposition] Content disposition override. Default will be depending on the document type.
|
|
559
551
|
* @param {*} [options] Override http request option.
|
|
560
552
|
* @throws {RequiredError}
|
|
561
553
|
*/
|
|
562
|
-
getDocumentDownloadUrl: function (code,
|
|
554
|
+
getDocumentDownloadUrl: function (code, authorization, contentDisposition, options) {
|
|
563
555
|
return __awaiter(this, void 0, void 0, function () {
|
|
564
556
|
var localVarAxiosArgs;
|
|
565
557
|
return __generator(this, function (_a) {
|
|
566
558
|
switch (_a.label) {
|
|
567
|
-
case 0: return [4 /*yield*/, localVarAxiosParamCreator.getDocumentDownloadUrl(code,
|
|
559
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.getDocumentDownloadUrl(code, authorization, contentDisposition, options)];
|
|
568
560
|
case 1:
|
|
569
561
|
localVarAxiosArgs = _a.sent();
|
|
570
562
|
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
@@ -576,17 +568,16 @@ var DocumentsApiFp = function (configuration) {
|
|
|
576
568
|
* This will return a presigned URL for a random S3 key
|
|
577
569
|
* @summary Fetches a presigned URL for a S3 key
|
|
578
570
|
* @param {string} s3Key Key for the file in S3 bucket to create the presigned download URL for
|
|
579
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
580
571
|
* @param {string} [authorization] Bearer Token
|
|
581
572
|
* @param {*} [options] Override http request option.
|
|
582
573
|
* @throws {RequiredError}
|
|
583
574
|
*/
|
|
584
|
-
getSignedS3keyUrl: function (s3Key,
|
|
575
|
+
getSignedS3keyUrl: function (s3Key, authorization, options) {
|
|
585
576
|
return __awaiter(this, void 0, void 0, function () {
|
|
586
577
|
var localVarAxiosArgs;
|
|
587
578
|
return __generator(this, function (_a) {
|
|
588
579
|
switch (_a.label) {
|
|
589
|
-
case 0: return [4 /*yield*/, localVarAxiosParamCreator.getSignedS3keyUrl(s3Key,
|
|
580
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.getSignedS3keyUrl(s3Key, authorization, options)];
|
|
590
581
|
case 1:
|
|
591
582
|
localVarAxiosArgs = _a.sent();
|
|
592
583
|
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
@@ -690,25 +681,24 @@ var DocumentsApiFactory = function (configuration, basePath, axios) {
|
|
|
690
681
|
* This will return a presigned URL to download the document.
|
|
691
682
|
* @summary Fetches a document download URL
|
|
692
683
|
* @param {string} code Document code
|
|
693
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
694
684
|
* @param {string} [authorization] Bearer Token
|
|
685
|
+
* @param {'attachment' | 'inline'} [contentDisposition] Content disposition override. Default will be depending on the document type.
|
|
695
686
|
* @param {*} [options] Override http request option.
|
|
696
687
|
* @throws {RequiredError}
|
|
697
688
|
*/
|
|
698
|
-
getDocumentDownloadUrl: function (code,
|
|
699
|
-
return localVarFp.getDocumentDownloadUrl(code,
|
|
689
|
+
getDocumentDownloadUrl: function (code, authorization, contentDisposition, options) {
|
|
690
|
+
return localVarFp.getDocumentDownloadUrl(code, authorization, contentDisposition, options).then(function (request) { return request(axios, basePath); });
|
|
700
691
|
},
|
|
701
692
|
/**
|
|
702
693
|
* This will return a presigned URL for a random S3 key
|
|
703
694
|
* @summary Fetches a presigned URL for a S3 key
|
|
704
695
|
* @param {string} s3Key Key for the file in S3 bucket to create the presigned download URL for
|
|
705
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
706
696
|
* @param {string} [authorization] Bearer Token
|
|
707
697
|
* @param {*} [options] Override http request option.
|
|
708
698
|
* @throws {RequiredError}
|
|
709
699
|
*/
|
|
710
|
-
getSignedS3keyUrl: function (s3Key,
|
|
711
|
-
return localVarFp.getSignedS3keyUrl(s3Key,
|
|
700
|
+
getSignedS3keyUrl: function (s3Key, authorization, options) {
|
|
701
|
+
return localVarFp.getSignedS3keyUrl(s3Key, authorization, options).then(function (request) { return request(axios, basePath); });
|
|
712
702
|
},
|
|
713
703
|
/**
|
|
714
704
|
* Returns a list of documents you have previously created. The documents are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
|
|
@@ -799,7 +789,7 @@ var DocumentsApi = /** @class */ (function (_super) {
|
|
|
799
789
|
*/
|
|
800
790
|
DocumentsApi.prototype.getDocumentDownloadUrl = function (requestParameters, options) {
|
|
801
791
|
var _this = this;
|
|
802
|
-
return (0, exports.DocumentsApiFp)(this.configuration).getDocumentDownloadUrl(requestParameters.code, requestParameters.
|
|
792
|
+
return (0, exports.DocumentsApiFp)(this.configuration).getDocumentDownloadUrl(requestParameters.code, requestParameters.authorization, requestParameters.contentDisposition, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
803
793
|
};
|
|
804
794
|
/**
|
|
805
795
|
* This will return a presigned URL for a random S3 key
|
|
@@ -811,7 +801,7 @@ var DocumentsApi = /** @class */ (function (_super) {
|
|
|
811
801
|
*/
|
|
812
802
|
DocumentsApi.prototype.getSignedS3keyUrl = function (requestParameters, options) {
|
|
813
803
|
var _this = this;
|
|
814
|
-
return (0, exports.DocumentsApiFp)(this.configuration).getSignedS3keyUrl(requestParameters.s3Key, requestParameters.
|
|
804
|
+
return (0, exports.DocumentsApiFp)(this.configuration).getSignedS3keyUrl(requestParameters.s3Key, requestParameters.authorization, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
815
805
|
};
|
|
816
806
|
/**
|
|
817
807
|
* Returns a list of documents you have previously created. The documents are returned in sorted order, with the oldest one appearing first. For more information about pagination, read the Pagination documentation.
|
|
@@ -34,12 +34,12 @@ export declare const ProductDocumentsApiAxiosParamCreator: (configuration?: Conf
|
|
|
34
34
|
* @summary Get pre-signed url for downloading product document
|
|
35
35
|
* @param {string} productSlug Product slug
|
|
36
36
|
* @param {string} code Product document code
|
|
37
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
38
37
|
* @param {string} [authorization] Bearer Token
|
|
38
|
+
* @param {'attachment' | 'inline'} [contentDisposition] Content disposition override. Default will be depending on the document type.
|
|
39
39
|
* @param {*} [options] Override http request option.
|
|
40
40
|
* @throws {RequiredError}
|
|
41
41
|
*/
|
|
42
|
-
downloadProductDocument: (productSlug: string, code: string, contentDisposition
|
|
42
|
+
downloadProductDocument: (productSlug: string, code: string, authorization?: string, contentDisposition?: 'attachment' | 'inline', options?: AxiosRequestConfig) => Promise<RequestArgs>;
|
|
43
43
|
/**
|
|
44
44
|
* Get a product document.
|
|
45
45
|
* @summary Retrieve the product document
|
|
@@ -97,12 +97,12 @@ export declare const ProductDocumentsApiFp: (configuration?: Configuration) => {
|
|
|
97
97
|
* @summary Get pre-signed url for downloading product document
|
|
98
98
|
* @param {string} productSlug Product slug
|
|
99
99
|
* @param {string} code Product document code
|
|
100
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
101
100
|
* @param {string} [authorization] Bearer Token
|
|
101
|
+
* @param {'attachment' | 'inline'} [contentDisposition] Content disposition override. Default will be depending on the document type.
|
|
102
102
|
* @param {*} [options] Override http request option.
|
|
103
103
|
* @throws {RequiredError}
|
|
104
104
|
*/
|
|
105
|
-
downloadProductDocument(productSlug: string, code: string, contentDisposition
|
|
105
|
+
downloadProductDocument(productSlug: string, code: string, authorization?: string, contentDisposition?: 'attachment' | 'inline', options?: AxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
|
|
106
106
|
/**
|
|
107
107
|
* Get a product document.
|
|
108
108
|
* @summary Retrieve the product document
|
|
@@ -160,12 +160,12 @@ export declare const ProductDocumentsApiFactory: (configuration?: Configuration,
|
|
|
160
160
|
* @summary Get pre-signed url for downloading product document
|
|
161
161
|
* @param {string} productSlug Product slug
|
|
162
162
|
* @param {string} code Product document code
|
|
163
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
164
163
|
* @param {string} [authorization] Bearer Token
|
|
164
|
+
* @param {'attachment' | 'inline'} [contentDisposition] Content disposition override. Default will be depending on the document type.
|
|
165
165
|
* @param {*} [options] Override http request option.
|
|
166
166
|
* @throws {RequiredError}
|
|
167
167
|
*/
|
|
168
|
-
downloadProductDocument(productSlug: string, code: string, contentDisposition
|
|
168
|
+
downloadProductDocument(productSlug: string, code: string, authorization?: string, contentDisposition?: 'attachment' | 'inline', options?: any): AxiosPromise<void>;
|
|
169
169
|
/**
|
|
170
170
|
* Get a product document.
|
|
171
171
|
* @summary Retrieve the product document
|
|
@@ -246,18 +246,18 @@ export interface ProductDocumentsApiDownloadProductDocumentRequest {
|
|
|
246
246
|
* @memberof ProductDocumentsApiDownloadProductDocument
|
|
247
247
|
*/
|
|
248
248
|
readonly code: string;
|
|
249
|
-
/**
|
|
250
|
-
* Content disposition override. Default will be depending on the document type.
|
|
251
|
-
* @type {'attachment' | 'inline'}
|
|
252
|
-
* @memberof ProductDocumentsApiDownloadProductDocument
|
|
253
|
-
*/
|
|
254
|
-
readonly contentDisposition: 'attachment' | 'inline';
|
|
255
249
|
/**
|
|
256
250
|
* Bearer Token
|
|
257
251
|
* @type {string}
|
|
258
252
|
* @memberof ProductDocumentsApiDownloadProductDocument
|
|
259
253
|
*/
|
|
260
254
|
readonly authorization?: string;
|
|
255
|
+
/**
|
|
256
|
+
* Content disposition override. Default will be depending on the document type.
|
|
257
|
+
* @type {'attachment' | 'inline'}
|
|
258
|
+
* @memberof ProductDocumentsApiDownloadProductDocument
|
|
259
|
+
*/
|
|
260
|
+
readonly contentDisposition?: 'attachment' | 'inline';
|
|
261
261
|
}
|
|
262
262
|
/**
|
|
263
263
|
* Request parameters for getProductDocument operation in ProductDocumentsApi.
|
|
@@ -153,12 +153,12 @@ var ProductDocumentsApiAxiosParamCreator = function (configuration) {
|
|
|
153
153
|
* @summary Get pre-signed url for downloading product document
|
|
154
154
|
* @param {string} productSlug Product slug
|
|
155
155
|
* @param {string} code Product document code
|
|
156
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
157
156
|
* @param {string} [authorization] Bearer Token
|
|
157
|
+
* @param {'attachment' | 'inline'} [contentDisposition] Content disposition override. Default will be depending on the document type.
|
|
158
158
|
* @param {*} [options] Override http request option.
|
|
159
159
|
* @throws {RequiredError}
|
|
160
160
|
*/
|
|
161
|
-
downloadProductDocument: function (productSlug, code,
|
|
161
|
+
downloadProductDocument: function (productSlug, code, authorization, contentDisposition, options) {
|
|
162
162
|
if (options === void 0) { options = {}; }
|
|
163
163
|
return __awaiter(_this, void 0, void 0, function () {
|
|
164
164
|
var localVarPath, localVarUrlObj, baseOptions, baseAccessToken, localVarRequestOptions, localVarHeaderParameter, localVarQueryParameter, headersFromBaseOptions;
|
|
@@ -169,8 +169,6 @@ var ProductDocumentsApiAxiosParamCreator = function (configuration) {
|
|
|
169
169
|
(0, common_1.assertParamExists)('downloadProductDocument', 'productSlug', productSlug);
|
|
170
170
|
// verify required parameter 'code' is not null or undefined
|
|
171
171
|
(0, common_1.assertParamExists)('downloadProductDocument', 'code', code);
|
|
172
|
-
// verify required parameter 'contentDisposition' is not null or undefined
|
|
173
|
-
(0, common_1.assertParamExists)('downloadProductDocument', 'contentDisposition', contentDisposition);
|
|
174
172
|
localVarPath = "/documentservice/v1/product-documents/{productSlug}/{code}/download-url"
|
|
175
173
|
.replace("{".concat("productSlug", "}"), encodeURIComponent(String(productSlug)))
|
|
176
174
|
.replace("{".concat("code", "}"), encodeURIComponent(String(code)));
|
|
@@ -424,17 +422,17 @@ var ProductDocumentsApiFp = function (configuration) {
|
|
|
424
422
|
* @summary Get pre-signed url for downloading product document
|
|
425
423
|
* @param {string} productSlug Product slug
|
|
426
424
|
* @param {string} code Product document code
|
|
427
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
428
425
|
* @param {string} [authorization] Bearer Token
|
|
426
|
+
* @param {'attachment' | 'inline'} [contentDisposition] Content disposition override. Default will be depending on the document type.
|
|
429
427
|
* @param {*} [options] Override http request option.
|
|
430
428
|
* @throws {RequiredError}
|
|
431
429
|
*/
|
|
432
|
-
downloadProductDocument: function (productSlug, code,
|
|
430
|
+
downloadProductDocument: function (productSlug, code, authorization, contentDisposition, options) {
|
|
433
431
|
return __awaiter(this, void 0, void 0, function () {
|
|
434
432
|
var localVarAxiosArgs;
|
|
435
433
|
return __generator(this, function (_a) {
|
|
436
434
|
switch (_a.label) {
|
|
437
|
-
case 0: return [4 /*yield*/, localVarAxiosParamCreator.downloadProductDocument(productSlug, code,
|
|
435
|
+
case 0: return [4 /*yield*/, localVarAxiosParamCreator.downloadProductDocument(productSlug, code, authorization, contentDisposition, options)];
|
|
438
436
|
case 1:
|
|
439
437
|
localVarAxiosArgs = _a.sent();
|
|
440
438
|
return [2 /*return*/, (0, common_1.createRequestFunction)(localVarAxiosArgs, axios_1.default, base_1.BASE_PATH, configuration)];
|
|
@@ -541,13 +539,13 @@ var ProductDocumentsApiFactory = function (configuration, basePath, axios) {
|
|
|
541
539
|
* @summary Get pre-signed url for downloading product document
|
|
542
540
|
* @param {string} productSlug Product slug
|
|
543
541
|
* @param {string} code Product document code
|
|
544
|
-
* @param {'attachment' | 'inline'} contentDisposition Content disposition override. Default will be depending on the document type.
|
|
545
542
|
* @param {string} [authorization] Bearer Token
|
|
543
|
+
* @param {'attachment' | 'inline'} [contentDisposition] Content disposition override. Default will be depending on the document type.
|
|
546
544
|
* @param {*} [options] Override http request option.
|
|
547
545
|
* @throws {RequiredError}
|
|
548
546
|
*/
|
|
549
|
-
downloadProductDocument: function (productSlug, code,
|
|
550
|
-
return localVarFp.downloadProductDocument(productSlug, code,
|
|
547
|
+
downloadProductDocument: function (productSlug, code, authorization, contentDisposition, options) {
|
|
548
|
+
return localVarFp.downloadProductDocument(productSlug, code, authorization, contentDisposition, options).then(function (request) { return request(axios, basePath); });
|
|
551
549
|
},
|
|
552
550
|
/**
|
|
553
551
|
* Get a product document.
|
|
@@ -627,7 +625,7 @@ var ProductDocumentsApi = /** @class */ (function (_super) {
|
|
|
627
625
|
*/
|
|
628
626
|
ProductDocumentsApi.prototype.downloadProductDocument = function (requestParameters, options) {
|
|
629
627
|
var _this = this;
|
|
630
|
-
return (0, exports.ProductDocumentsApiFp)(this.configuration).downloadProductDocument(requestParameters.productSlug, requestParameters.code, requestParameters.
|
|
628
|
+
return (0, exports.ProductDocumentsApiFp)(this.configuration).downloadProductDocument(requestParameters.productSlug, requestParameters.code, requestParameters.authorization, requestParameters.contentDisposition, options).then(function (request) { return request(_this.axios, _this.basePath); });
|
|
631
629
|
};
|
|
632
630
|
/**
|
|
633
631
|
* Get a product document.
|