aspose_words_cloud 25.9 → 25.10

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 346315b8b59b1459d1c6e059935570421508e1039fa7accc07a66f6dbf05c4a5
4
- data.tar.gz: ce85564da40de9dc67ad22b4616720cf3690c2583785d79d162d35fe4feb05f1
3
+ metadata.gz: 890c97263fab07e8ad3e217f7de8ae46a5b4a8729d08a8329f0214f2454fe637
4
+ data.tar.gz: 820f7090549d01c54e03bdbcffd1c6edd3436576cf631c013309e4de97e45b97
5
5
  SHA512:
6
- metadata.gz: ddcd6e207e7896af0ec3c271a847513c8d9c1817694fe5cabea0654f756f5163418dd4c388d25d8c2cb7d46e0dd782804b417733515f5005c673df8a2f14e559
7
- data.tar.gz: c976365f00f7b2c7bbf9126a87a0f656d9ea8b0ca7364556d52fbbaa5cb0b26da3729adeeb5ebd273f68b969e314172de8a2fd3c55c7d52d99418db5d0941a24
6
+ metadata.gz: 3b806373ff1efaf32f698eaf83b1350936adecd201023ceb35178ac175613f08690f5945ce8f22577e77cb8acb35a07625af11c3e5172ec3dbe3f2f2a8a1b647
7
+ data.tar.gz: 47b2e0b32699a06aae4687a4d2fb097d9c7db3708c3ca4c2224ab9fc24c74336407d77393d98c4600d040c2b4e0b4f48f8433b1549d4576c478d8da79144c541
@@ -11053,6 +11053,52 @@ module AsposeWordsCloud
11053
11053
  [data, status_code, headers]
11054
11054
  end
11055
11055
 
11056
+ # Downloads a document from the Web using URL and saves it to cloud storage in the specified format.
11057
+ # @param request LoadWebDocumentOnlineRequest
11058
+ # @return [LoadWebDocumentOnlineResponse]
11059
+ def load_web_document_online(request)
11060
+ begin
11061
+ data, _status_code, _headers = load_web_document_online_with_http_info(request)
11062
+ rescue ApiError => e
11063
+ if e.code == 401
11064
+ request_token
11065
+ data, _status_code, _headers = load_web_document_online_with_http_info(request)
11066
+ else
11067
+ raise
11068
+ end
11069
+ end
11070
+ data
11071
+ end
11072
+
11073
+ # Downloads a document from the Web using URL and saves it to cloud storage in the specified format.
11074
+ # @param request LoadWebDocumentOnlineRequest
11075
+ # @return [Array<(LoadWebDocumentOnlineResponse, Fixnum, Hash)>]
11076
+ # LoadWebDocumentOnlineResponse, response status code and response headers
11077
+ private def load_web_document_online_with_http_info(request)
11078
+ raise ArgumentError, 'Incorrect request type' unless request.is_a? LoadWebDocumentOnlineRequest
11079
+
11080
+ @api_client.config.logger.debug 'Calling API: WordsApi.load_web_document_online ...' if @api_client.config.debugging
11081
+ request_data = request.create_http_request(@api_client)
11082
+
11083
+ data, status_code, headers = @api_client.call_api(
11084
+ request_data[:'method'],
11085
+ request_data[:'path'],
11086
+ header_params: request_data[:'header_params'],
11087
+ query_params: request_data[:'query_params'],
11088
+ body: request_data[:'body'],
11089
+ multipart_response: true,
11090
+ return_type: 'LoadWebDocumentOnlineResponse')
11091
+ if @api_client.config.debugging
11092
+ @api_client.config.logger.debug "API called:
11093
+ WordsApi#load_web_document_online\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
11094
+ end
11095
+
11096
+ mp_data = LoadWebDocumentOnlineResponse.new()
11097
+ mp_data.model = @api_client.deserialize(data['Model'][:data], data['Model'][:headers], 'SaveResponse')
11098
+ mp_data.document = @api_client.parse_files_collection(data['Document'][:data], data['Document'][:headers])
11099
+ [mp_data, status_code, headers]
11100
+ end
11101
+
11056
11102
  # Merge the section with the next one.
11057
11103
  # @param request MergeWithNextRequest
11058
11104
  # @return [nil]
@@ -0,0 +1,151 @@
1
+ # ------------------------------------------------------------------------------------
2
+ # <copyright company="Aspose" file="load_web_document_online_request.rb">
3
+ # Copyright (c) 2025 Aspose.Words for Cloud
4
+ # </copyright>
5
+ # <summary>
6
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
7
+ # of this software and associated documentation files (the "Software"), to deal
8
+ # in the Software without restriction, including without limitation the rights
9
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
+ # copies of the Software, and to permit persons to whom the Software is
11
+ # furnished to do so, subject to the following conditions:
12
+ #
13
+ # The above copyright notice and this permission notice shall be included in all
14
+ # copies or substantial portions of the Software.
15
+ #
16
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
+ # SOFTWARE.
23
+ # </summary>
24
+ # ------------------------------------------------------------------------------------
25
+
26
+ module AsposeWordsCloud
27
+
28
+ #
29
+ # Request model for load_web_document_online operation.
30
+ #
31
+ class LoadWebDocumentOnlineRequest
32
+ # The properties of data downloading.
33
+ attr_accessor :data
34
+
35
+ #
36
+ # Initializes a new instance.
37
+ # @param data The properties of data downloading.
38
+
39
+ def initialize(data:)
40
+ self.data = data
41
+ end
42
+
43
+ # Creating batch part from request
44
+ def to_batch_part(api_client, requestId, parentRequestId = nil)
45
+ # verify the required parameter 'data' is set
46
+ raise ArgumentError, 'Missing the required parameter data when calling WordsApi.load_web_document_online' if api_client.config.client_side_validation && self.data.nil?
47
+ self.data.validate
48
+ # resource path
49
+ local_var_path = '/words/online/put/loadWebDocument'[7..-1]
50
+ local_var_path = local_var_path.sub('//', '/')
51
+
52
+ # query parameters
53
+ query_params = {}
54
+
55
+ if query_params
56
+ query_params.each { |key, value| local_var_path = api_client.add_param_to_query(local_var_path, key, value) }
57
+ end
58
+
59
+ header_params = {}
60
+ # header parameters
61
+ # HTTP header 'Content-Type'
62
+ header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
63
+ header_params['RequestId'] = requestId
64
+
65
+ if parentRequestId != nil
66
+ header_params['DependsOn'] = parentRequestId
67
+ end
68
+
69
+ # form parameters
70
+ form_params = []
71
+ files_content = []
72
+ if self.data.nil?
73
+ raise "Parameter Data is required."
74
+ end
75
+ unless self.data.nil?
76
+ form_params.push({:'Name' => 'data', :'Data' => self.data.to_body.to_json, :'MimeType' =>'application/json'})
77
+ end
78
+
79
+
80
+ # http body (model)
81
+ body = api_client.build_request_body_batch(header_params, form_params, files_content)
82
+ part = ""
83
+ part.concat("PUT".force_encoding('UTF-8'))
84
+ part.concat(" ".force_encoding('UTF-8'))
85
+ part.concat(local_var_path.force_encoding('UTF-8'))
86
+ part.concat(" \r\n".force_encoding('UTF-8'))
87
+
88
+ header_params.each_pair {|key, value| part.concat(key.dup.force_encoding('UTF-8') , ": ".force_encoding('UTF-8'), value.dup.force_encoding('UTF-8'), "\r\n".force_encoding('UTF-8')) }
89
+ part.concat("\r\n".force_encoding('UTF-8'))
90
+ if body
91
+ if body.is_a?(Hash)
92
+ body.each do |key, value|
93
+ part.concat(value, "\r\n")
94
+ end
95
+ else
96
+ part.concat(body)
97
+ end
98
+ end
99
+ part
100
+ end
101
+
102
+ def create_http_request(api_client)
103
+ # verify the required parameter 'data' is set
104
+ raise ArgumentError, 'Missing the required parameter data when calling WordsApi.load_web_document_online' if api_client.config.client_side_validation && self.data.nil?
105
+ self.data.validate
106
+ # resource path
107
+ local_var_path = '/words/online/put/loadWebDocument'[1..-1]
108
+ local_var_path = local_var_path.sub('//', '/')
109
+
110
+ # query parameters
111
+ query_params = {}
112
+
113
+ # header parameters
114
+ header_params = {}
115
+ # HTTP header 'Content-Type'
116
+ header_params['Content-Type'] = api_client.select_header_content_type(['multipart/form-data'])
117
+
118
+ # form parameters
119
+ form_params = []
120
+ files_content = []
121
+ if self.data.nil?
122
+ raise "Parameter Data is required."
123
+ end
124
+ unless self.data.nil?
125
+ form_params.push({:'Name' => 'data', :'Data' => self.data.to_body.to_json, :'MimeType' =>'application/json'})
126
+ end
127
+
128
+ body = api_client.build_request_body(header_params, form_params, files_content)
129
+ {
130
+ 'method': :PUT,
131
+ 'path': local_var_path,
132
+ 'header_params': header_params,
133
+ 'query_params': query_params,
134
+ 'body': body,
135
+ 'auth_names': ['JWT']
136
+ }
137
+ end
138
+
139
+ #
140
+ # Helper method to convert first letter to downcase
141
+ #
142
+ def downcase_first_letter(str)
143
+ str[0].downcase + str[1..-1]
144
+ end
145
+
146
+ # Get response type
147
+ def get_response_type
148
+ 'LoadWebDocumentOnlineResponse'
149
+ end
150
+ end
151
+ end
@@ -0,0 +1,46 @@
1
+ # ------------------------------------------------------------------------------------
2
+ # <copyright company="Aspose" file="load_web_document_online_response.rb">
3
+ # Copyright (c) 2025 Aspose.Words for Cloud
4
+ # </copyright>
5
+ # <summary>
6
+ # Permission is hereby granted, free of charge, to any person obtaining a copy
7
+ # of this software and associated documentation files (the "Software"), to deal
8
+ # in the Software without restriction, including without limitation the rights
9
+ # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10
+ # copies of the Software, and to permit persons to whom the Software is
11
+ # furnished to do so, subject to the following conditions:
12
+ #
13
+ # The above copyright notice and this permission notice shall be included in all
14
+ # copies or substantial portions of the Software.
15
+ #
16
+ # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17
+ # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18
+ # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19
+ # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20
+ # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21
+ # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
22
+ # SOFTWARE.
23
+ # </summary>
24
+ # ------------------------------------------------------------------------------------
25
+
26
+ module AsposeWordsCloud
27
+
28
+ #
29
+ # Response model for load_web_document_online operation.
30
+ #
31
+ class LoadWebDocumentOnlineResponse
32
+ # The REST response with a save result.
33
+ attr_accessor :model
34
+
35
+ # The document after modification.
36
+ attr_accessor :document
37
+
38
+ #
39
+ # Initializes a new instance.
40
+ #
41
+ def initialize()
42
+ self.model = nil
43
+ self.document = nil
44
+ end
45
+ end
46
+ end
@@ -24,5 +24,5 @@
24
24
  # ------------------------------------------------------------------------------------
25
25
 
26
26
  module AsposeWordsCloud
27
- VERSION = "25.9".freeze
27
+ VERSION = "25.10".freeze
28
28
  end
@@ -566,6 +566,7 @@ require_relative 'aspose_words_cloud/models/requests/insert_watermark_text_reque
566
566
  require_relative 'aspose_words_cloud/models/requests/insert_watermark_text_online_request'
567
567
  require_relative 'aspose_words_cloud/models/requests/link_header_footers_to_previous_request'
568
568
  require_relative 'aspose_words_cloud/models/requests/load_web_document_request'
569
+ require_relative 'aspose_words_cloud/models/requests/load_web_document_online_request'
569
570
  require_relative 'aspose_words_cloud/models/requests/merge_with_next_request'
570
571
  require_relative 'aspose_words_cloud/models/requests/merge_with_next_online_request'
571
572
  require_relative 'aspose_words_cloud/models/requests/move_file_request'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aspose_words_cloud
3
3
  version: !ruby/object:Gem::Version
4
- version: '25.9'
4
+ version: '25.10'
5
5
  platform: ruby
6
6
  authors:
7
7
  - Aspose
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-09-10 00:00:00.000000000 Z
11
+ date: 2025-10-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -537,6 +537,7 @@ files:
537
537
  - lib/aspose_words_cloud/models/requests/insert_watermark_text_online_request.rb
538
538
  - lib/aspose_words_cloud/models/requests/insert_watermark_text_request.rb
539
539
  - lib/aspose_words_cloud/models/requests/link_header_footers_to_previous_request.rb
540
+ - lib/aspose_words_cloud/models/requests/load_web_document_online_request.rb
540
541
  - lib/aspose_words_cloud/models/requests/load_web_document_request.rb
541
542
  - lib/aspose_words_cloud/models/requests/merge_with_next_online_request.rb
542
543
  - lib/aspose_words_cloud/models/requests/merge_with_next_request.rb
@@ -661,6 +662,7 @@ files:
661
662
  - lib/aspose_words_cloud/models/responses/insert_watermark_image_online_response.rb
662
663
  - lib/aspose_words_cloud/models/responses/insert_watermark_online_response.rb
663
664
  - lib/aspose_words_cloud/models/responses/insert_watermark_text_online_response.rb
665
+ - lib/aspose_words_cloud/models/responses/load_web_document_online_response.rb
664
666
  - lib/aspose_words_cloud/models/responses/protect_document_online_response.rb
665
667
  - lib/aspose_words_cloud/models/responses/reject_all_revisions_online_response.rb
666
668
  - lib/aspose_words_cloud/models/responses/remove_all_signatures_online_response.rb