Skip to content

Commit a1b2449

Browse files
authored
Merge pull request #84 from aspose-pdf-cloud/develop
update to 23.9
2 parents 8a8e2e3 + ba73927 commit a1b2449

File tree

7 files changed

+38
-22
lines changed

7 files changed

+38
-22
lines changed

README.md

+5-8
Original file line numberDiff line numberDiff line change
@@ -30,16 +30,13 @@ XLS, XLSX, PPTX, DOC, DOCX, MobiXML, JPEG, EMF, PNG, BMP, GIF, TIFF, Text
3030
## Read PDF Formats
3131
MHT, PCL, PS, XSLFO, MD
3232

33-
## Enhancements in Version 23.8
34-
- Support to split password protected PDF documents.
35-
- Support to convert password Protected PDF to Xlsx.
36-
- Support to convert password Protected PDF to Excel.
37-
- Replace a single image using multiple Image Ids.
33+
## Enhancements in Version 23.9
34+
- Support to convert password protected PDF documents to PDFA.
3835
- A new version of Aspose.PDF Cloud was prepared using the latest version of Aspose.PDF for .NET.
3936

40-
## Bugs fixed in Version 23.8
41-
- The putMergeDocuments API method in Node.js Throws Gateway Error.
42-
- Text Replacement Changes the Background.
37+
## Bugs fixed in Version 23.9
38+
- Rotate Property not working with FreeTextAnnotation.
39+
- PutAnnotationsFlatten not working correctly when passing multiple annotation types.
4340

4441
## Installation
4542

docs/PdfApi.md

+6-3
Original file line numberDiff line numberDiff line change
@@ -3712,7 +3712,7 @@ Name | Type | Description | Notes
37123712

37133713
<a name="getPdfInStorageToPdfA"></a>
37143714
## **getPdfInStorageToPdfA**
3715-
> getPdfInStorageToPdfA(name, type, folder, storage)
3715+
> getPdfInStorageToPdfA(name, type, folder, storage, password)
37163716
37173717
Converts PDF document (located on storage) to PdfA format and returns resulting file in response content
37183718

@@ -3723,6 +3723,7 @@ Name | Type | Description | Notes
37233723
**type** | [**PdfAType**](PdfAType.md) | Type of PdfA format. |
37243724
**folder** | **string** | The document folder. | [optional]
37253725
**storage** | **string** | The document storage. | [optional]
3726+
**password** | **string** | The password (Base64). | [optional]
37263727

37273728
### Return type
37283729

@@ -7527,7 +7528,7 @@ Name | Type | Description | Notes
75277528

75287529
<a name="putPdfInRequestToPdfA"></a>
75297530
## **putPdfInRequestToPdfA**
7530-
> putPdfInRequestToPdfA(outPath, type, storage, file)
7531+
> putPdfInRequestToPdfA(outPath, type, storage, password, file)
75317532
75327533
Converts PDF document (in request content) to PdfA format and uploads resulting file to storage.
75337534

@@ -7537,6 +7538,7 @@ Name | Type | Description | Notes
75377538
**outPath** | **string** | Full resulting filename (ex. /folder1/folder2/result.pdf) |
75387539
**type** | [**PdfAType**](PdfAType.md) | Type of PdfA format. |
75397540
**storage** | **string** | The document storage. | [optional]
7541+
**password** | **string** | The password (Base64). | [optional]
75407542
**file** | **Buffer** | A file to be converted. | [optional]
75417543

75427544
### Return type
@@ -7886,7 +7888,7 @@ Name | Type | Description | Notes
78867888

78877889
<a name="putPdfInStorageToPdfA"></a>
78887890
## **putPdfInStorageToPdfA**
7889-
> putPdfInStorageToPdfA(name, outPath, type, folder, storage)
7891+
> putPdfInStorageToPdfA(name, outPath, type, folder, storage, password)
78907892
78917893
Converts PDF document (located on storage) to PdfA format and uploads resulting file to storage
78927894

@@ -7898,6 +7900,7 @@ Name | Type | Description | Notes
78987900
**type** | [**PdfAType**](PdfAType.md) | Type of PdfA format. |
78997901
**folder** | **string** | The document folder. | [optional]
79007902
**storage** | **string** | The document storage. | [optional]
7903+
**password** | **string** | The password (Base64). | [optional]
79017904

79027905
### Return type
79037906

package-lock.json

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "asposepdfcloud",
3-
"version": "23.8.0",
3+
"version": "23.9.0",
44
"description": "Aspose.PDF Cloud is a REST API for creating and editing PDF files. Most popular features proposed by Aspose.PDF Cloud: PDF to Word, Convert PDF to Image, Merge PDF, Split PDF, Add Images to PDF, Rotate PDF. It can also be used to convert PDF files to different formats like DOC, HTML, XPS, TIFF and many more. Aspose.PDF Cloud gives you control: create PDFs from scratch or from HTML, XML, template, database, XPS or an image. Render PDFs to image formats such as JPEG, PNG, GIF, BMP, TIFF and many others. Aspose.PDF Cloud helps you manipulate elements of a PDF file like text, annotations, watermarks, signatures, bookmarks, stamps and so on. Its REST API also allows you to manage PDF pages by using features like merging, splitting, and inserting. Add images to a PDF file or convert PDF pages to images.",
55
"homepage": "https://products.aspose.cloud/pdf/cloud",
66
"author": {

src/api/api.ts

+22-3
Original file line numberDiff line numberDiff line change
@@ -8894,8 +8894,9 @@ export class PdfApi {
88948894
* @param type Type of PdfA format.
88958895
* @param folder The document folder.
88968896
* @param storage The document storage.
8897+
* @param password The password (Base64).
88978898
*/
8898-
public async getPdfInStorageToPdfA (name: string, type: string, folder?: string, storage?: string) : Promise<{ response: http.IncomingMessage; body: Buffer; }> {
8899+
public async getPdfInStorageToPdfA (name: string, type: string, folder?: string, storage?: string, password?: string) : Promise<{ response: http.IncomingMessage; body: Buffer; }> {
88998900
const localVarPath = this.basePath + '/pdf/{name}/convert/pdfa'
89008901
.replace('{' + 'name' + '}', encodeURIComponent(String(name)).replace('%2F', '/'));
89018902
let localVarQueryParameters: any = {};
@@ -8924,6 +8925,10 @@ export class PdfApi {
89248925
localVarQueryParameters['storage'] = ObjectSerializer.serialize(storage, "string");
89258926
}
89268927

8928+
if (password !== undefined && null !== password) {
8929+
localVarQueryParameters['password'] = ObjectSerializer.serialize(password, "string");
8930+
}
8931+
89278932

89288933
let localVarUseFormData = false;
89298934
let fileData = null;
@@ -19480,9 +19485,10 @@ export class PdfApi {
1948019485
* @param outPath Full resulting filename (ex. /folder1/folder2/result.pdf)
1948119486
* @param type Type of PdfA format.
1948219487
* @param storage The document storage.
19488+
* @param password The password (Base64).
1948319489
* @param file A file to be converted.
1948419490
*/
19485-
public async putPdfInRequestToPdfA (outPath: string, type: string, storage?: string, file?: Buffer) : Promise<{ response: http.IncomingMessage; body: AsposeResponse; }> {
19491+
public async putPdfInRequestToPdfA (outPath: string, type: string, storage?: string, password?: string, file?: Buffer) : Promise<{ response: http.IncomingMessage; body: AsposeResponse; }> {
1948619492
const localVarPath = this.basePath + '/pdf/convert/pdfa';
1948719493
let localVarQueryParameters: any = {};
1948819494
let localVarHeaderParams: any = (<any>Object).assign({}, this.defaultHeaders);
@@ -19510,6 +19516,10 @@ export class PdfApi {
1951019516
localVarQueryParameters['storage'] = ObjectSerializer.serialize(storage, "string");
1951119517
}
1951219518

19519+
if (password !== undefined && null !== password) {
19520+
localVarQueryParameters['password'] = ObjectSerializer.serialize(password, "string");
19521+
}
19522+
1951319523

1951419524
let localVarUseFormData = false;
1951519525
let fileData = null;
@@ -19915,13 +19925,16 @@ export class PdfApi {
1991519925
localVarQueryParameters['password'] = ObjectSerializer.serialize(password, "string");
1991619926
}
1991719927

19928+
1991819929
let localVarUseFormData = false;
1991919930
let fileData = null;
1992019931
if (file !== undefined) {
1992119932
localVarFormParams['file'] = file;
1992219933
fileData = file;
1992319934
}
1992419935
localVarUseFormData = true;
19936+
19937+
1992519938
let localVarRequestOptions: localVarRequest.Options = {
1992619939
method: 'PUT',
1992719940
qs: localVarQueryParameters,
@@ -19943,6 +19956,7 @@ export class PdfApi {
1994319956
return Promise.resolve({body: result, response});
1994419957
}
1994519958

19959+
1994619960
/**
1994719961
*
1994819962
* @summary Converts PDF document (in request content) to XLSX format and uploads resulting file to storage.
@@ -20598,8 +20612,9 @@ export class PdfApi {
2059820612
* @param type Type of PdfA format.
2059920613
* @param folder The document folder.
2060020614
* @param storage The document storage.
20615+
* @param password The password (Base64).
2060120616
*/
20602-
public async putPdfInStorageToPdfA (name: string, outPath: string, type: string, folder?: string, storage?: string) : Promise<{ response: http.IncomingMessage; body: AsposeResponse; }> {
20617+
public async putPdfInStorageToPdfA (name: string, outPath: string, type: string, folder?: string, storage?: string, password?: string) : Promise<{ response: http.IncomingMessage; body: AsposeResponse; }> {
2060320618
const localVarPath = this.basePath + '/pdf/{name}/convert/pdfa'
2060420619
.replace('{' + 'name' + '}', encodeURIComponent(String(name)).replace('%2F', '/'));
2060520620
let localVarQueryParameters: any = {};
@@ -20637,6 +20652,10 @@ export class PdfApi {
2063720652
localVarQueryParameters['storage'] = ObjectSerializer.serialize(storage, "string");
2063820653
}
2063920654

20655+
if (password !== undefined && null !== password) {
20656+
localVarQueryParameters['password'] = ObjectSerializer.serialize(password, "string");
20657+
}
20658+
2064020659

2064120660
let localVarUseFormData = false;
2064220661
let fileData = null;

src/requestHelper.ts

+1-4
Original file line numberDiff line numberDiff line change
@@ -69,9 +69,6 @@ export function addQueryParameterToUrl(url, queryParameters, parameterName, para
6969
* @param notApplyAuthToRequest if setted to true, auth is not applied to request
7070
*/
7171
async function invokeApiMethodInternal(requestOptions: request.Options, confguration: Configuration, notApplyAuthToRequest?: boolean, postData?: Buffer): Promise<request.RequestResponse> {
72-
73-
console.log("requestOptions[\"uri\"]: " + requestOptions["uri"]);
74-
7572
let sa = superagent(requestOptions.method, requestOptions["uri"]);
7673

7774
const auth = confguration.authentication;
@@ -96,7 +93,7 @@ console.log("requestOptions[\"uri\"]: " + requestOptions["uri"]);
9693
//headers
9794
sa.set("User-Agent", "pdf nodejs sdk");
9895
sa.set("x-aspose-client", "nodejs sdk");
99-
sa.set("x-aspose-client-version", "23.8.0");
96+
sa.set("x-aspose-client-version", "23.9.0");
10097

10198
if (!requestOptions.headers) {
10299
requestOptions.headers = {};

test/testConvert.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ describe("Convert Tests", () => {
109109

110110
var data = fs.readFileSync(BaseTest.localTestDataFolder + "/" + simplePdf);
111111

112-
return BaseTest.getPdfApi().putPdfInRequestToPdfA(outPath, PdfAType.PDFA1A, null, data)
112+
return BaseTest.getPdfApi().putPdfInRequestToPdfA(outPath, PdfAType.PDFA1A, null, null, data)
113113
.then((result) => {
114114
assert.equal(result.response.statusCode, 200);
115115
});

0 commit comments

Comments
 (0)