aspose_pdf_cloud 23.6.0 → 23.8.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: f451e346f21121426558b0fa9c16453972b636ed838b6bfc9ad56fed8608ab54
4
- data.tar.gz: '086199fea6259a01307cc9f7c6ef4830c7b6272a6a90135defc3e275bc780226'
3
+ metadata.gz: 2b4a251cc79f46c619988bdf83e4c6d80c5cef35f02936bbe2b0e2ab294d65a1
4
+ data.tar.gz: d04cdbd86931df55898fb5b49070415e2744c760a67e0475e9309ac64ff65ba8
5
5
  SHA512:
6
- metadata.gz: 3f8bdbfcaaf1409e2906c685946aeb14b951f4edf117637c1d31208695a3300566a9cd12070f933e59bf0bf44d4d602840e8070af792203d3a1119e45b61e2a4
7
- data.tar.gz: 8bbacb9c11e11d9ac3c957c360786a661fe0c990f6067a4d8541ed14f111b73529681b1681ac9e07d2f5831822b31759c276988e5b56eefe3c49c8c6ccb4a9bd
6
+ metadata.gz: c90ae8624324707d450507aa311da1cd44ce36dfae253b89e4bc7de2d3de6340b21e0bfbf6856a793f45ddfbd0a42c3b1a3d5eb62ee6bd6b2b45dfb9f727ae93
7
+ data.tar.gz: 91baacd9b060748e66bf94e24e0732877fea5b70e55b81cadb6162a81a2732058b1e5393d6983cb462a21ec01ab8908c4265d1b20425e0b466841443de5ddf96
data/README.md CHANGED
@@ -29,12 +29,16 @@ XLS, XLSX, PPTX, DOC, DOCX, MobiXML, JPEG, EMF, PNG, BMP, GIF, TIFF, Text
29
29
  ## Read PDF Formats
30
30
  MHT, PCL, PS, XSLFO, MD
31
31
 
32
- ## Enhancements in Version 23.6
33
- - Support to convert password protected PDF documents to PPTX.
32
+ ## Enhancements in Version 23.8
33
+ - Support to split password protected PDF documents.
34
+ - Support to convert password Protected PDF to Xlsx.
35
+ - Support to convert password Protected PDF to Excel.
36
+ - Replace a single image using multiple Image Ids.
34
37
  - A new version of Aspose.PDF Cloud was prepared using the latest version of Aspose.PDF for .NET.
35
38
 
36
- ## Bugs fixed in Version 23.6
37
- - Text Replacement API constantly hitting 504 Gateway Timeout.
39
+ ## Bugs fixed in Version 23.8
40
+ - The putMergeDocuments API method in Node.js Throws Gateway Error.
41
+ - Text Replacement Changes the Background.
38
42
 
39
43
  ## Installation
40
44
 
@@ -49,15 +53,15 @@ gem build aspose_pdf_cloud.gemspec
49
53
  Then either install the gem locally:
50
54
 
51
55
  ```shell
52
- gem install ./aspose_pdf_cloud-23.6.0.gem
56
+ gem install ./aspose_pdf_cloud-23.8.0.gem
53
57
  ```
54
- (for development, run `gem install --dev ./aspose_pdf_cloud-23.6.0.gem` to install the development dependencies)
58
+ (for development, run `gem install --dev ./aspose_pdf_cloud-23.8.0.gem` to install the development dependencies)
55
59
 
56
60
  or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
57
61
 
58
62
  Finally add this to the Gemfile:
59
63
 
60
- gem 'aspose_pdf_cloud', '~> 23.6.0'
64
+ gem 'aspose_pdf_cloud', '~> 23.8.0'
61
65
 
62
66
  ### Install from Git
63
67
 
data/docs/Field.md CHANGED
@@ -6,6 +6,7 @@ Name | Type | Description | Notes
6
6
  ------------ | ------------- | ------------- | -------------
7
7
  **links** | [**Array<Link>**](Link.md) | Link to the document. | [optional]
8
8
  **name** | **String** | Field name. | [optional]
9
+ **mapping_name** | **String** | Mapping name. | [optional]
9
10
  **selected_items** | **Array<Integer>** | Selected items. | [optional]
10
11
  **type** | [**FieldType**](FieldType.md) | Field type. | [optional]
11
12
  **rect** | [**Rectangle**](Rectangle.md) | Field rectangle. | [optional]
data/docs/PdfApi.md CHANGED
@@ -336,6 +336,7 @@ Method | HTTP request | Description
336
336
  [**put_radio_button_field**](PdfApi.md#put_radio_button_field) | **PUT** /pdf/\{name}/fields/radiobutton/\{fieldName} | Replace document RadioButton field
337
337
  [**put_redaction_annotation**](PdfApi.md#put_redaction_annotation) | **PUT** /pdf/\{name}/annotations/redaction/\{annotationId} | Replace document redaction annotation
338
338
  [**put_replace_image**](PdfApi.md#put_replace_image) | **PUT** /pdf/\{name}/images/\{imageId} | Replace document image.
339
+ [**put_replace_multiple_image**](PdfApi.md#put_replace_multiple_image) | **PUT** /pdf/\{name}/images/replace | Replace document multiple image.
339
340
  [**put_screen_annotation**](PdfApi.md#put_screen_annotation) | **PUT** /pdf/\{name}/annotations/screen/\{annotationId} | Replace document screen annotation
340
341
  [**put_screen_annotation_data_extract**](PdfApi.md#put_screen_annotation_data_extract) | **PUT** /pdf/\{name}/annotations/screen/\{annotationId}/data/extract | Extract document screen annotation content to storage
341
342
  [**put_searchable_document**](PdfApi.md#put_searchable_document) | **PUT** /pdf/\{name}/ocr | Create searchable PDF document. Generate OCR layer for images in input PDF document.
@@ -4157,6 +4158,7 @@ Name | Type | Description | Notes
4157
4158
  **uniform_worksheets** | **BOOLEAN**| Uniform worksheets | [optional]
4158
4159
  **folder** | **String**| The document folder. | [optional]
4159
4160
  **storage** | **String**| The document storage. | [optional]
4161
+ **password** | **String**| The password (Base64). | [optional]
4160
4162
 
4161
4163
  ### Return type
4162
4164
 
@@ -4185,6 +4187,7 @@ Name | Type | Description | Notes
4185
4187
  **uniform_worksheets** | **BOOLEAN**| Uniform worksheets | [optional]
4186
4188
  **folder** | **String**| The document folder. | [optional]
4187
4189
  **storage** | **String**| The document storage. | [optional]
4190
+ **password** | **String**| The password (Base64). | [optional]
4188
4191
 
4189
4192
  ### Return type
4190
4193
 
@@ -6550,6 +6553,7 @@ Name | Type | Description | Notes
6550
6553
  **to** | **Integer**| End page if defined. | [optional]
6551
6554
  **storage** | **String**| The document storage. | [optional]
6552
6555
  **folder** | **String**| The document folder. | [optional]
6556
+ **password** | **String**| Base64 encoded password. | [optional]
6553
6557
 
6554
6558
  ### Return type
6555
6559
 
@@ -6575,6 +6579,7 @@ Name | Type | Description | Notes
6575
6579
  **options** | [**SplitRangePdfOptions**](SplitRangePdfOptions.md)| The splitting options. |
6576
6580
  **storage** | **String**| The document storage. | [optional]
6577
6581
  **folder** | **String**| The document folder. | [optional]
6582
+ **password** | **String**| Base64 encoded password. | [optional]
6578
6583
 
6579
6584
  ### Return type
6580
6585
 
@@ -8280,6 +8285,7 @@ Name | Type | Description | Notes
8280
8285
  **scale_factor** | **Float**| Scale factor (Obsolete) | [optional]
8281
8286
  **uniform_worksheets** | **BOOLEAN**| Uniform worksheets | [optional]
8282
8287
  **storage** | **String**| The document storage. | [optional]
8288
+ **password** | **String**| The password (Base64). | [optional]
8283
8289
  **file** | **File**| A file to be converted. | [optional]
8284
8290
 
8285
8291
  ### Return type
@@ -8308,6 +8314,7 @@ Name | Type | Description | Notes
8308
8314
  **scale_factor** | **Float**| Scale factor (Obsolete) | [optional]
8309
8315
  **uniform_worksheets** | **BOOLEAN**| Uniform worksheets | [optional]
8310
8316
  **storage** | **String**| The document storage. | [optional]
8317
+ **password** | **String**| The password (Base64). | [optional]
8311
8318
  **file** | **File**| A file to be converted. | [optional]
8312
8319
 
8313
8320
  ### Return type
@@ -8670,6 +8677,7 @@ Name | Type | Description | Notes
8670
8677
  **uniform_worksheets** | **BOOLEAN**| Uniform worksheets | [optional]
8671
8678
  **folder** | **String**| The document folder. | [optional]
8672
8679
  **storage** | **String**| The document storage. | [optional]
8680
+ **password** | **String**| The password (Base64). | [optional]
8673
8681
 
8674
8682
  ### Return type
8675
8683
 
@@ -8699,6 +8707,7 @@ Name | Type | Description | Notes
8699
8707
  **uniform_worksheets** | **BOOLEAN**| Uniform worksheets | [optional]
8700
8708
  **folder** | **String**| The document folder. | [optional]
8701
8709
  **storage** | **String**| The document storage. | [optional]
8710
+ **password** | **String**| The password (Base64). | [optional]
8702
8711
 
8703
8712
  ### Return type
8704
8713
 
@@ -8969,6 +8978,33 @@ Name | Type | Description | Notes
8969
8978
 
8970
8979
 
8971
8980
 
8981
+ # **put_replace_multiple_image**
8982
+ > ImagesResponse put_replace_multiple_image(name, image_ids, opts)
8983
+
8984
+ Replace document multiple image.
8985
+
8986
+ ### Parameters
8987
+
8988
+ Name | Type | Description | Notes
8989
+ ------------- | ------------- | ------------- | -------------
8990
+ **name** | **String**| The document name. |
8991
+ **image_ids** | **Array<String>**| The image IDs. |
8992
+ **image_file_path** | **String**| Path to image file if specified. Request content is used otherwise. | [optional]
8993
+ **storage** | **String**| The document storage. | [optional]
8994
+ **folder** | **String**| The document folder. | [optional]
8995
+ **image** | **File**| Image file. | [optional]
8996
+
8997
+ ### Return type
8998
+
8999
+ [**ImagesResponse**](ImagesResponse.md)
9000
+
9001
+ ### HTTP request headers
9002
+
9003
+ - **Content-Type**: multipart/form-data
9004
+ - **Accept**: application/json
9005
+
9006
+
9007
+
8972
9008
  # **put_screen_annotation**
8973
9009
  > ScreenAnnotationResponse put_screen_annotation(name, annotation_id, annotation, opts)
8974
9010
 
@@ -11688,6 +11688,7 @@ module AsposePdfCloud
11688
11688
  # @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
11689
11689
  # @option opts [String] :folder The document folder.
11690
11690
  # @option opts [String] :storage The document storage.
11691
+ # @option opts [String] :password The password (Base64).
11691
11692
  # @return [File]
11692
11693
  def get_pdf_in_storage_to_xls(name, opts = {})
11693
11694
  @api_client.request_token_if_needed
@@ -11712,6 +11713,7 @@ module AsposePdfCloud
11712
11713
  # @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
11713
11714
  # @option opts [String] :folder The document folder.
11714
11715
  # @option opts [String] :storage The document storage.
11716
+ # @option opts [String] :password The password (Base64).
11715
11717
  # @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers
11716
11718
  def get_pdf_in_storage_to_xls_with_http_info(name, opts = {})
11717
11719
  if @api_client.config.debugging
@@ -11732,6 +11734,7 @@ module AsposePdfCloud
11732
11734
  query_params[:'uniformWorksheets'] = opts[:'uniform_worksheets'] if !opts[:'uniform_worksheets'].nil?
11733
11735
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
11734
11736
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
11737
+ query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
11735
11738
 
11736
11739
  # header parameters
11737
11740
  header_params = {}
@@ -11772,6 +11775,7 @@ module AsposePdfCloud
11772
11775
  # @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
11773
11776
  # @option opts [String] :folder The document folder.
11774
11777
  # @option opts [String] :storage The document storage.
11778
+ # @option opts [String] :password The password (Base64).
11775
11779
  # @return [File]
11776
11780
  def get_pdf_in_storage_to_xlsx(name, opts = {})
11777
11781
  @api_client.request_token_if_needed
@@ -11796,6 +11800,7 @@ module AsposePdfCloud
11796
11800
  # @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
11797
11801
  # @option opts [String] :folder The document folder.
11798
11802
  # @option opts [String] :storage The document storage.
11803
+ # @option opts [String] :password The password (Base64).
11799
11804
  # @return [Array<(File, Fixnum, Hash)>] File data, response status code and response headers
11800
11805
  def get_pdf_in_storage_to_xlsx_with_http_info(name, opts = {})
11801
11806
  if @api_client.config.debugging
@@ -11816,6 +11821,7 @@ module AsposePdfCloud
11816
11821
  query_params[:'uniformWorksheets'] = opts[:'uniform_worksheets'] if !opts[:'uniform_worksheets'].nil?
11817
11822
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
11818
11823
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
11824
+ query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
11819
11825
 
11820
11826
  # header parameters
11821
11827
  header_params = {}
@@ -19235,6 +19241,7 @@ module AsposePdfCloud
19235
19241
  # @option opts [Integer] :to End page if defined.
19236
19242
  # @option opts [String] :storage The document storage.
19237
19243
  # @option opts [String] :folder The document folder.
19244
+ # @option opts [String] :password Base64 encoded password.
19238
19245
  # @return [SplitResultResponse]
19239
19246
  def post_split_document(name, opts = {})
19240
19247
  @api_client.request_token_if_needed
@@ -19258,6 +19265,7 @@ module AsposePdfCloud
19258
19265
  # @option opts [Integer] :to End page if defined.
19259
19266
  # @option opts [String] :storage The document storage.
19260
19267
  # @option opts [String] :folder The document folder.
19268
+ # @option opts [String] :password Base64 encoded password.
19261
19269
  # @return [Array<(SplitResultResponse, Fixnum, Hash)>] SplitResultResponse data, response status code and response headers
19262
19270
  def post_split_document_with_http_info(name, opts = {})
19263
19271
  if @api_client.config.debugging
@@ -19277,6 +19285,7 @@ module AsposePdfCloud
19277
19285
  query_params[:'to'] = opts[:'to'] if !opts[:'to'].nil?
19278
19286
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
19279
19287
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
19288
+ query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
19280
19289
 
19281
19290
  # header parameters
19282
19291
  header_params = {}
@@ -19314,6 +19323,7 @@ module AsposePdfCloud
19314
19323
  # @param [Hash] opts the optional parameters
19315
19324
  # @option opts [String] :storage The document storage.
19316
19325
  # @option opts [String] :folder The document folder.
19326
+ # @option opts [String] :password Base64 encoded password.
19317
19327
  # @return [SplitResultResponse]
19318
19328
  def post_split_range_pdf_document(name, options, opts = {})
19319
19329
  @api_client.request_token_if_needed
@@ -19335,6 +19345,7 @@ module AsposePdfCloud
19335
19345
  # @param [Hash] opts the optional parameters
19336
19346
  # @option opts [String] :storage The document storage.
19337
19347
  # @option opts [String] :folder The document folder.
19348
+ # @option opts [String] :password Base64 encoded password.
19338
19349
  # @return [Array<(SplitResultResponse, Fixnum, Hash)>] SplitResultResponse data, response status code and response headers
19339
19350
  def post_split_range_pdf_document_with_http_info(name, options, opts = {})
19340
19351
  if @api_client.config.debugging
@@ -19355,6 +19366,7 @@ module AsposePdfCloud
19355
19366
  query_params = {}
19356
19367
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
19357
19368
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
19369
+ query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
19358
19370
 
19359
19371
  # header parameters
19360
19372
  header_params = {}
@@ -24736,6 +24748,7 @@ module AsposePdfCloud
24736
24748
  # @option opts [Float] :scale_factor Scale factor (Obsolete)
24737
24749
  # @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
24738
24750
  # @option opts [String] :storage The document storage.
24751
+ # @option opts [String] :password The password (Base64).
24739
24752
  # @option opts [File] :file A file to be converted.
24740
24753
  # @return [AsposeResponse]
24741
24754
  def put_pdf_in_request_to_xls(out_path, opts = {})
@@ -24760,6 +24773,7 @@ module AsposePdfCloud
24760
24773
  # @option opts [Float] :scale_factor Scale factor (Obsolete)
24761
24774
  # @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
24762
24775
  # @option opts [String] :storage The document storage.
24776
+ # @option opts [String] :password The password (Base64).
24763
24777
  # @option opts [File] :file A file to be converted.
24764
24778
  # @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers
24765
24779
  def put_pdf_in_request_to_xls_with_http_info(out_path, opts = {})
@@ -24781,6 +24795,7 @@ module AsposePdfCloud
24781
24795
  query_params[:'scaleFactor'] = opts[:'scale_factor'] if !opts[:'scale_factor'].nil?
24782
24796
  query_params[:'uniformWorksheets'] = opts[:'uniform_worksheets'] if !opts[:'uniform_worksheets'].nil?
24783
24797
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
24798
+ query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
24784
24799
 
24785
24800
  # header parameters
24786
24801
  header_params = {}
@@ -24822,6 +24837,7 @@ module AsposePdfCloud
24822
24837
  # @option opts [Float] :scale_factor Scale factor (Obsolete)
24823
24838
  # @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
24824
24839
  # @option opts [String] :storage The document storage.
24840
+ # @option opts [String] :password The password (Base64).
24825
24841
  # @option opts [File] :file A file to be converted.
24826
24842
  # @return [AsposeResponse]
24827
24843
  def put_pdf_in_request_to_xlsx(out_path, opts = {})
@@ -24846,6 +24862,7 @@ module AsposePdfCloud
24846
24862
  # @option opts [Float] :scale_factor Scale factor (Obsolete)
24847
24863
  # @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
24848
24864
  # @option opts [String] :storage The document storage.
24865
+ # @option opts [String] :password The password (Base64).
24849
24866
  # @option opts [File] :file A file to be converted.
24850
24867
  # @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers
24851
24868
  def put_pdf_in_request_to_xlsx_with_http_info(out_path, opts = {})
@@ -24867,6 +24884,7 @@ module AsposePdfCloud
24867
24884
  query_params[:'scaleFactor'] = opts[:'scale_factor'] if !opts[:'scale_factor'].nil?
24868
24885
  query_params[:'uniformWorksheets'] = opts[:'uniform_worksheets'] if !opts[:'uniform_worksheets'].nil?
24869
24886
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
24887
+ query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
24870
24888
 
24871
24889
  # header parameters
24872
24890
  header_params = {}
@@ -25999,6 +26017,7 @@ module AsposePdfCloud
25999
26017
  # @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
26000
26018
  # @option opts [String] :folder The document folder.
26001
26019
  # @option opts [String] :storage The document storage.
26020
+ # @option opts [String] :password The password (Base64).
26002
26021
  # @return [AsposeResponse]
26003
26022
  def put_pdf_in_storage_to_xls(name, out_path, opts = {})
26004
26023
  @api_client.request_token_if_needed
@@ -26024,6 +26043,7 @@ module AsposePdfCloud
26024
26043
  # @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
26025
26044
  # @option opts [String] :folder The document folder.
26026
26045
  # @option opts [String] :storage The document storage.
26046
+ # @option opts [String] :password The password (Base64).
26027
26047
  # @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers
26028
26048
  def put_pdf_in_storage_to_xls_with_http_info(name, out_path, opts = {})
26029
26049
  if @api_client.config.debugging
@@ -26049,6 +26069,7 @@ module AsposePdfCloud
26049
26069
  query_params[:'uniformWorksheets'] = opts[:'uniform_worksheets'] if !opts[:'uniform_worksheets'].nil?
26050
26070
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
26051
26071
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
26072
+ query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
26052
26073
 
26053
26074
  # header parameters
26054
26075
  header_params = {}
@@ -26090,6 +26111,7 @@ module AsposePdfCloud
26090
26111
  # @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
26091
26112
  # @option opts [String] :folder The document folder.
26092
26113
  # @option opts [String] :storage The document storage.
26114
+ # @option opts [String] :password The password (Base64).
26093
26115
  # @return [AsposeResponse]
26094
26116
  def put_pdf_in_storage_to_xlsx(name, out_path, opts = {})
26095
26117
  @api_client.request_token_if_needed
@@ -26115,6 +26137,7 @@ module AsposePdfCloud
26115
26137
  # @option opts [BOOLEAN] :uniform_worksheets Uniform worksheets
26116
26138
  # @option opts [String] :folder The document folder.
26117
26139
  # @option opts [String] :storage The document storage.
26140
+ # @option opts [String] :password The password (Base64).
26118
26141
  # @return [Array<(AsposeResponse, Fixnum, Hash)>] AsposeResponse data, response status code and response headers
26119
26142
  def put_pdf_in_storage_to_xlsx_with_http_info(name, out_path, opts = {})
26120
26143
  if @api_client.config.debugging
@@ -26140,6 +26163,7 @@ module AsposePdfCloud
26140
26163
  query_params[:'uniformWorksheets'] = opts[:'uniform_worksheets'] if !opts[:'uniform_worksheets'].nil?
26141
26164
  query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
26142
26165
  query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
26166
+ query_params[:'password'] = opts[:'password'] if !opts[:'password'].nil?
26143
26167
 
26144
26168
  # header parameters
26145
26169
  header_params = {}
@@ -26987,6 +27011,92 @@ module AsposePdfCloud
26987
27011
  return data, status_code, headers
26988
27012
  end
26989
27013
 
27014
+ # Replace document multiple image.
27015
+ #
27016
+ # @param name The document name.
27017
+ # @param image_ids The image IDs.
27018
+ # @param [Hash] opts the optional parameters
27019
+ # @option opts [String] :image_file_path Path to image file if specified. Request content is used otherwise.
27020
+ # @option opts [String] :storage The document storage.
27021
+ # @option opts [String] :folder The document folder.
27022
+ # @option opts [File] :image Image file.
27023
+ # @return [ImagesResponse]
27024
+ def put_replace_multiple_image(name, image_ids, opts = {})
27025
+ @api_client.request_token_if_needed
27026
+ data, _status_code, _headers = put_replace_multiple_image_with_http_info(name, image_ids, opts)
27027
+ rescue ApiError => error
27028
+ if error.code == 401
27029
+ @api_client.request_token_if_needed
27030
+ data, _status_code, _headers = put_replace_multiple_image_with_http_info(name, image_ids, opts)
27031
+ else
27032
+ raise
27033
+ end
27034
+ return data
27035
+ end
27036
+
27037
+ # Replace document multiple image.
27038
+ #
27039
+ # @param name The document name.
27040
+ # @param image_ids The image IDs.
27041
+ # @param [Hash] opts the optional parameters
27042
+ # @option opts [String] :image_file_path Path to image file if specified. Request content is used otherwise.
27043
+ # @option opts [String] :storage The document storage.
27044
+ # @option opts [String] :folder The document folder.
27045
+ # @option opts [File] :image Image file.
27046
+ # @return [Array<(ImagesResponse, Fixnum, Hash)>] ImagesResponse data, response status code and response headers
27047
+ def put_replace_multiple_image_with_http_info(name, image_ids, opts = {})
27048
+ if @api_client.config.debugging
27049
+ @api_client.config.logger.debug "Calling API: PdfApi.put_replace_multiple_image ..."
27050
+ end
27051
+ # verify the required parameter 'name' is set
27052
+ if @api_client.config.client_side_validation && name.nil?
27053
+ fail ArgumentError, "Missing the required parameter 'name' when calling PdfApi.put_replace_multiple_image"
27054
+ end
27055
+ # verify the required parameter 'image_ids' is set
27056
+ if @api_client.config.client_side_validation && image_ids.nil?
27057
+ fail ArgumentError, "Missing the required parameter 'image_ids' when calling PdfApi.put_replace_multiple_image"
27058
+ end
27059
+ # resource path
27060
+ local_var_path = "/pdf/{name}/images/replace".sub('{' + 'name' + '}', name.to_s)
27061
+
27062
+ # query parameters
27063
+ query_params = {}
27064
+ query_params[:'imageIds'] = @api_client.build_collection_param(image_ids, :csv)
27065
+ query_params[:'imageFilePath'] = opts[:'image_file_path'] if !opts[:'image_file_path'].nil?
27066
+ query_params[:'storage'] = opts[:'storage'] if !opts[:'storage'].nil?
27067
+ query_params[:'folder'] = opts[:'folder'] if !opts[:'folder'].nil?
27068
+
27069
+ # header parameters
27070
+ header_params = {}
27071
+ # HTTP header 'Accept' (if needed)
27072
+ header_params['Accept'] = @api_client.select_header_accept(['application/json'])
27073
+ # HTTP header 'Content-Type'
27074
+ header_params['Content-Type'] = @api_client.select_header_content_type(['multipart/form-data'])
27075
+
27076
+ # form parameters
27077
+ form_params = {}
27078
+ # Fix header in file
27079
+ post_body = nil
27080
+ post_body = opts[:'image'] if !opts[:'image'].nil?
27081
+ header_params['Content-Type'] = @api_client.select_header_content_type(['application/octet-stream'])
27082
+
27083
+ # http body (model)
27084
+ # Fix header in file
27085
+ # post_body = nil
27086
+ auth_names = ['JWT']
27087
+ data, status_code, headers = @api_client.call_api(:PUT, local_var_path,
27088
+ :header_params => header_params,
27089
+ :query_params => query_params,
27090
+ :form_params => form_params,
27091
+ :body => post_body,
27092
+ :auth_names => auth_names,
27093
+ :return_type => 'ImagesResponse')
27094
+ if @api_client.config.debugging
27095
+ @api_client.config.logger.debug "API called: PdfApi#put_replace_multiple_image\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
27096
+ end
27097
+ return data, status_code, headers
27098
+ end
27099
+
26990
27100
  # Replace document screen annotation
26991
27101
  #
26992
27102
  # @param name The document name.
@@ -31,6 +31,9 @@ module AsposePdfCloud
31
31
  # Field name.
32
32
  attr_accessor :name
33
33
 
34
+ # Mapping name.
35
+ attr_accessor :mapping_name
36
+
34
37
  # Selected items.
35
38
  attr_accessor :selected_items
36
39
 
@@ -49,6 +52,7 @@ module AsposePdfCloud
49
52
  {
50
53
  :'links' => :'Links',
51
54
  :'name' => :'Name',
55
+ :'mapping_name' => :'MappingName',
52
56
  :'selected_items' => :'SelectedItems',
53
57
  :'type' => :'Type',
54
58
  :'rect' => :'Rect',
@@ -61,6 +65,7 @@ module AsposePdfCloud
61
65
  {
62
66
  :'links' => :'Array<Link>',
63
67
  :'name' => :'String',
68
+ :'mapping_name' => :'String',
64
69
  :'selected_items' => :'Array<Integer>',
65
70
  :'type' => :'FieldType',
66
71
  :'rect' => :'Rectangle',
@@ -86,6 +91,10 @@ module AsposePdfCloud
86
91
  self.name = attributes[:'Name']
87
92
  end
88
93
 
94
+ if attributes.has_key?(:'MappingName')
95
+ self.mapping_name = attributes[:'MappingName']
96
+ end
97
+
89
98
  if attributes.has_key?(:'SelectedItems')
90
99
  if (value = attributes[:'SelectedItems']).is_a?(Array)
91
100
  self.selected_items = value
@@ -133,6 +142,7 @@ module AsposePdfCloud
133
142
  self.class == o.class &&
134
143
  links == o.links &&
135
144
  name == o.name &&
145
+ mapping_name == o.mapping_name &&
136
146
  selected_items == o.selected_items &&
137
147
  type == o.type &&
138
148
  rect == o.rect &&
@@ -148,7 +158,7 @@ module AsposePdfCloud
148
158
  # Calculates hash code according to all attributes.
149
159
  # @return [Fixnum] Hash code
150
160
  def hash
151
- [links, name, selected_items, type, rect, values].hash
161
+ [links, name, mapping_name, selected_items, type, rect, values].hash
152
162
  end
153
163
 
154
164
  # Builds the object from hash
@@ -20,5 +20,5 @@ SOFTWARE.
20
20
  =end
21
21
 
22
22
  module AsposePdfCloud
23
- VERSION = "23.6.0"
23
+ VERSION = "23.8.0"
24
24
  end
data/test/pdf_tests.rb CHANGED
@@ -4882,24 +4882,34 @@ class PdfTests < Minitest::Test
4882
4882
  def test_put_replace_image
4883
4883
  file_name = 'PdfWithImages2.pdf'
4884
4884
  upload_file(file_name)
4885
-
4886
4885
  image_file_name = 'Koala.jpg'
4887
4886
  upload_file(image_file_name)
4888
-
4889
4887
  opts = {
4890
4888
  :image_file_path => @temp_folder + '/' + image_file_name,
4891
4889
  :folder => @temp_folder
4892
4890
  }
4893
-
4894
4891
  page_number = 1
4895
4892
  responseImages = @pdf_api.get_images(file_name, page_number, opts)
4896
4893
  assert(responseImages, 'Failed to read document images.')
4897
4894
  image_id = responseImages[0].images.list[0].id
4898
-
4899
4895
  response = @pdf_api.put_replace_image(file_name, image_id, opts)
4900
4896
  assert(response, 'Failed to replace document image.')
4901
4897
  end
4902
4898
 
4899
+ def test_put_replace_multiple_image
4900
+ file_name = 'PdfWithImages.pdf'
4901
+ upload_file(file_name)
4902
+ image_file_name = 'butterfly.jpg'
4903
+ upload_file(image_file_name)
4904
+ image_ids = ['GE5TENJVGQZTWMJYGQWDINRUFQ2DCMRMGY4TC', 'GE5TIMJSGY3TWMJXG4WDIMBZFQ2DCOJMGQ3DK']
4905
+ opts = {
4906
+ :image_file_path => @temp_folder + '/' + image_file_name,
4907
+ :folder => @temp_folder
4908
+ }
4909
+ response = @pdf_api.put_replace_multiple_image(file_name, image_ids, opts)
4910
+ assert(response, 'Failed to replace document images.')
4911
+ end
4912
+
4903
4913
  def test_post_insert_image
4904
4914
  file_name = 'PdfWithImages2.pdf'
4905
4915
  upload_file(file_name)
Binary file
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aspose_pdf_cloud
3
3
  version: !ruby/object:Gem::Version
4
- version: 23.6.0
4
+ version: 23.8.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Aspose PDF Cloud
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-06-30 00:00:00.000000000 Z
11
+ date: 2023-08-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: json
@@ -785,6 +785,7 @@ files:
785
785
  - test_data/PdfWithAnnotations1.pdf
786
786
  - test_data/PdfWithBookmarks.pdf
787
787
  - test_data/PdfWithEmbeddedFiles.pdf
788
+ - test_data/PdfWithImages.pdf
788
789
  - test_data/PdfWithImages2.pdf
789
790
  - test_data/PdfWithLinks.pdf
790
791
  - test_data/PdfWithScreenAnnotations.pdf