tencentcloud-sdk-ape 1.0.200

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 5fb6497ccc49c2cc0991b54ddfb86c41e4c17522
4
+ data.tar.gz: 0b985fb8cbd0f3d2f27aa166bb246e39a4201a3f
5
+ SHA512:
6
+ metadata.gz: 671eb915bc3fc557f7ca2b4c1867c9f96b8c810c9709e734ea033bb72c8567a631f6db48371d5be0eb8c2b03d2d96989ccc09ea5933dcafa4909e93a9ffe790e
7
+ data.tar.gz: 1ef45a5d4345d47799d2ba2c23545351a03629cd17f691a505a2eab6ac0e9d8e91908d754231a61a671f1ad473673fe0fbf4a88a256b049283b71bf4cf4185f1
data/lib/VERSION ADDED
@@ -0,0 +1 @@
1
+ 1.0.200
@@ -0,0 +1,11 @@
1
+ # frozen_string_literal: true
2
+
3
+ require 'tencentcloud-sdk-common'
4
+
5
+ require_relative 'v20200513/client'
6
+ require_relative 'v20200513/models'
7
+
8
+ module TencentCloud
9
+ module Ape
10
+ end
11
+ end
@@ -0,0 +1,228 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright (c) 2017-2018 THL A29 Limited, a Tencent company. All Rights Reserved.
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # http://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ require 'json'
18
+
19
+ module TencentCloud
20
+ module Ape
21
+ module V20200513
22
+ class Client < TencentCloud::Common::AbstractClient
23
+
24
+ def initialize(credential, region, profile = nil)
25
+ api_version = '2020-05-13'
26
+ api_endpoint = 'ape.tencentcloudapi.com'
27
+ sdk_version = 'APE_' + File.read(File.expand_path('../VERSION', __dir__)).strip
28
+ super(credential, region, api_version, api_endpoint, sdk_version, profile)
29
+ end
30
+
31
+
32
+ # 批量获取授权书下载地址
33
+
34
+ # @param request: Request instance for BatchDescribeOrderCertificate.
35
+ # @type request: :class:`Tencentcloud::ape::V20200513::BatchDescribeOrderCertificateRequest`
36
+ # @rtype: :class:`Tencentcloud::ape::V20200513::BatchDescribeOrderCertificateResponse`
37
+ def BatchDescribeOrderCertificate(request)
38
+ body = send_request('BatchDescribeOrderCertificate', request.serialize)
39
+ response = JSON.parse(body)
40
+ if response['Response'].key?('Error') == false
41
+ model = BatchDescribeOrderCertificateResponse.new
42
+ model.deserialize(response['Response'])
43
+ model
44
+ else
45
+ code = response['Response']['Error']['Code']
46
+ message = response['Response']['Error']['Message']
47
+ reqid = response['Response']['RequestId']
48
+ raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
49
+ end
50
+ rescue TencentCloud::Common::TencentCloudSDKException => e
51
+ raise e
52
+ rescue StandardError => e
53
+ raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
54
+ end
55
+
56
+ # 批量获取图片下载地址
57
+
58
+ # @param request: Request instance for BatchDescribeOrderImage.
59
+ # @type request: :class:`Tencentcloud::ape::V20200513::BatchDescribeOrderImageRequest`
60
+ # @rtype: :class:`Tencentcloud::ape::V20200513::BatchDescribeOrderImageResponse`
61
+ def BatchDescribeOrderImage(request)
62
+ body = send_request('BatchDescribeOrderImage', request.serialize)
63
+ response = JSON.parse(body)
64
+ if response['Response'].key?('Error') == false
65
+ model = BatchDescribeOrderImageResponse.new
66
+ model.deserialize(response['Response'])
67
+ model
68
+ else
69
+ code = response['Response']['Error']['Code']
70
+ message = response['Response']['Error']['Message']
71
+ reqid = response['Response']['RequestId']
72
+ raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
73
+ end
74
+ rescue TencentCloud::Common::TencentCloudSDKException => e
75
+ raise e
76
+ rescue StandardError => e
77
+ raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
78
+ end
79
+
80
+ # 核销图片,获取原图URL地址
81
+
82
+ # @param request: Request instance for CreateOrderAndDownloads.
83
+ # @type request: :class:`Tencentcloud::ape::V20200513::CreateOrderAndDownloadsRequest`
84
+ # @rtype: :class:`Tencentcloud::ape::V20200513::CreateOrderAndDownloadsResponse`
85
+ def CreateOrderAndDownloads(request)
86
+ body = send_request('CreateOrderAndDownloads', request.serialize)
87
+ response = JSON.parse(body)
88
+ if response['Response'].key?('Error') == false
89
+ model = CreateOrderAndDownloadsResponse.new
90
+ model.deserialize(response['Response'])
91
+ model
92
+ else
93
+ code = response['Response']['Error']['Code']
94
+ message = response['Response']['Error']['Message']
95
+ reqid = response['Response']['RequestId']
96
+ raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
97
+ end
98
+ rescue TencentCloud::Common::TencentCloudSDKException => e
99
+ raise e
100
+ rescue StandardError => e
101
+ raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
102
+ end
103
+
104
+ # 购买一张图片并且支付
105
+
106
+ # @param request: Request instance for CreateOrderAndPay.
107
+ # @type request: :class:`Tencentcloud::ape::V20200513::CreateOrderAndPayRequest`
108
+ # @rtype: :class:`Tencentcloud::ape::V20200513::CreateOrderAndPayResponse`
109
+ def CreateOrderAndPay(request)
110
+ body = send_request('CreateOrderAndPay', request.serialize)
111
+ response = JSON.parse(body)
112
+ if response['Response'].key?('Error') == false
113
+ model = CreateOrderAndPayResponse.new
114
+ model.deserialize(response['Response'])
115
+ model
116
+ else
117
+ code = response['Response']['Error']['Code']
118
+ message = response['Response']['Error']['Message']
119
+ reqid = response['Response']['RequestId']
120
+ raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
121
+ end
122
+ rescue TencentCloud::Common::TencentCloudSDKException => e
123
+ raise e
124
+ rescue StandardError => e
125
+ raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
126
+ end
127
+
128
+ # 分页查询授权人列表
129
+
130
+ # @param request: Request instance for DescribeAuthUsers.
131
+ # @type request: :class:`Tencentcloud::ape::V20200513::DescribeAuthUsersRequest`
132
+ # @rtype: :class:`Tencentcloud::ape::V20200513::DescribeAuthUsersResponse`
133
+ def DescribeAuthUsers(request)
134
+ body = send_request('DescribeAuthUsers', request.serialize)
135
+ response = JSON.parse(body)
136
+ if response['Response'].key?('Error') == false
137
+ model = DescribeAuthUsersResponse.new
138
+ model.deserialize(response['Response'])
139
+ model
140
+ else
141
+ code = response['Response']['Error']['Code']
142
+ message = response['Response']['Error']['Message']
143
+ reqid = response['Response']['RequestId']
144
+ raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
145
+ end
146
+ rescue TencentCloud::Common::TencentCloudSDKException => e
147
+ raise e
148
+ rescue StandardError => e
149
+ raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
150
+ end
151
+
152
+ # 获取用户图片下载记录
153
+
154
+ # @param request: Request instance for DescribeDownloadInfos.
155
+ # @type request: :class:`Tencentcloud::ape::V20200513::DescribeDownloadInfosRequest`
156
+ # @rtype: :class:`Tencentcloud::ape::V20200513::DescribeDownloadInfosResponse`
157
+ def DescribeDownloadInfos(request)
158
+ body = send_request('DescribeDownloadInfos', request.serialize)
159
+ response = JSON.parse(body)
160
+ if response['Response'].key?('Error') == false
161
+ model = DescribeDownloadInfosResponse.new
162
+ model.deserialize(response['Response'])
163
+ model
164
+ else
165
+ code = response['Response']['Error']['Code']
166
+ message = response['Response']['Error']['Message']
167
+ reqid = response['Response']['RequestId']
168
+ raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
169
+ end
170
+ rescue TencentCloud::Common::TencentCloudSDKException => e
171
+ raise e
172
+ rescue StandardError => e
173
+ raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
174
+ end
175
+
176
+ # 根据ID查询一张图片的详细信息
177
+
178
+ # @param request: Request instance for DescribeImage.
179
+ # @type request: :class:`Tencentcloud::ape::V20200513::DescribeImageRequest`
180
+ # @rtype: :class:`Tencentcloud::ape::V20200513::DescribeImageResponse`
181
+ def DescribeImage(request)
182
+ body = send_request('DescribeImage', request.serialize)
183
+ response = JSON.parse(body)
184
+ if response['Response'].key?('Error') == false
185
+ model = DescribeImageResponse.new
186
+ model.deserialize(response['Response'])
187
+ model
188
+ else
189
+ code = response['Response']['Error']['Code']
190
+ message = response['Response']['Error']['Message']
191
+ reqid = response['Response']['RequestId']
192
+ raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
193
+ end
194
+ rescue TencentCloud::Common::TencentCloudSDKException => e
195
+ raise e
196
+ rescue StandardError => e
197
+ raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
198
+ end
199
+
200
+ # 根据关键字搜索图片列表
201
+
202
+ # @param request: Request instance for DescribeImages.
203
+ # @type request: :class:`Tencentcloud::ape::V20200513::DescribeImagesRequest`
204
+ # @rtype: :class:`Tencentcloud::ape::V20200513::DescribeImagesResponse`
205
+ def DescribeImages(request)
206
+ body = send_request('DescribeImages', request.serialize)
207
+ response = JSON.parse(body)
208
+ if response['Response'].key?('Error') == false
209
+ model = DescribeImagesResponse.new
210
+ model.deserialize(response['Response'])
211
+ model
212
+ else
213
+ code = response['Response']['Error']['Code']
214
+ message = response['Response']['Error']['Message']
215
+ reqid = response['Response']['RequestId']
216
+ raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
217
+ end
218
+ rescue TencentCloud::Common::TencentCloudSDKException => e
219
+ raise e
220
+ rescue StandardError => e
221
+ raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
222
+ end
223
+
224
+
225
+ end
226
+ end
227
+ end
228
+ end
@@ -0,0 +1,715 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright (c) 2017-2018 THL A29 Limited, a Tencent company. All Rights Reserved.
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # http://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ module TencentCloud
18
+ module Ape
19
+ module V20200513
20
+ # 授权人信息
21
+ class AuthInfo < TencentCloud::Common::AbstractModel
22
+ # @param Id: 主键
23
+ # @type Id: String
24
+ # @param Name: 授权人名称
25
+ # @type Name: String
26
+ # @param Code: 身份证号/社会信用代码
27
+ # @type Code: String
28
+ # @param Type: 授权人类型
29
+ # @type Type: Integer
30
+ # @param CreateTime: 创建时间
31
+ # @type CreateTime: String
32
+
33
+ attr_accessor :Id, :Name, :Code, :Type, :CreateTime
34
+
35
+ def initialize(id=nil, name=nil, code=nil, type=nil, createtime=nil)
36
+ @Id = id
37
+ @Name = name
38
+ @Code = code
39
+ @Type = type
40
+ @CreateTime = createtime
41
+ end
42
+
43
+ def deserialize(params)
44
+ @Id = params['Id']
45
+ @Name = params['Name']
46
+ @Code = params['Code']
47
+ @Type = params['Type']
48
+ @CreateTime = params['CreateTime']
49
+ end
50
+ end
51
+
52
+ # BatchDescribeOrderCertificate请求参数结构体
53
+ class BatchDescribeOrderCertificateRequest < TencentCloud::Common::AbstractModel
54
+ # @param OrderIds: 要下载授权书的订单id
55
+ # @type OrderIds: Array
56
+
57
+ attr_accessor :OrderIds
58
+
59
+ def initialize(orderids=nil)
60
+ @OrderIds = orderids
61
+ end
62
+
63
+ def deserialize(params)
64
+ @OrderIds = params['OrderIds']
65
+ end
66
+ end
67
+
68
+ # BatchDescribeOrderCertificate返回参数结构体
69
+ class BatchDescribeOrderCertificateResponse < TencentCloud::Common::AbstractModel
70
+ # @param CertificateUrls: 授权书的下载地址
71
+ # @type CertificateUrls: Array
72
+ # @param RequestId: 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
73
+ # @type RequestId: String
74
+
75
+ attr_accessor :CertificateUrls, :RequestId
76
+
77
+ def initialize(certificateurls=nil, requestid=nil)
78
+ @CertificateUrls = certificateurls
79
+ @RequestId = requestid
80
+ end
81
+
82
+ def deserialize(params)
83
+ @CertificateUrls = params['CertificateUrls']
84
+ @RequestId = params['RequestId']
85
+ end
86
+ end
87
+
88
+ # BatchDescribeOrderImage请求参数结构体
89
+ class BatchDescribeOrderImageRequest < TencentCloud::Common::AbstractModel
90
+ # @param OrderIds: 要下载图片的订单id
91
+ # @type OrderIds: Array
92
+
93
+ attr_accessor :OrderIds
94
+
95
+ def initialize(orderids=nil)
96
+ @OrderIds = orderids
97
+ end
98
+
99
+ def deserialize(params)
100
+ @OrderIds = params['OrderIds']
101
+ end
102
+ end
103
+
104
+ # BatchDescribeOrderImage返回参数结构体
105
+ class BatchDescribeOrderImageResponse < TencentCloud::Common::AbstractModel
106
+ # @param ImageUrls: 图片的下载地址
107
+ # @type ImageUrls: Array
108
+ # @param RequestId: 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
109
+ # @type RequestId: String
110
+
111
+ attr_accessor :ImageUrls, :RequestId
112
+
113
+ def initialize(imageurls=nil, requestid=nil)
114
+ @ImageUrls = imageurls
115
+ @RequestId = requestid
116
+ end
117
+
118
+ def deserialize(params)
119
+ @ImageUrls = params['ImageUrls']
120
+ @RequestId = params['RequestId']
121
+ end
122
+ end
123
+
124
+ # CreateOrderAndDownloads请求参数结构体
125
+ class CreateOrderAndDownloadsRequest < TencentCloud::Common::AbstractModel
126
+ # @param ImageInfos: ImageId必填,单张购买,所有必填,会员身份可以省略部分参数
127
+ # @type ImageInfos: Array
128
+
129
+ attr_accessor :ImageInfos
130
+
131
+ def initialize(imageinfos=nil)
132
+ @ImageInfos = imageinfos
133
+ end
134
+
135
+ def deserialize(params)
136
+ unless params['ImageInfos'].nil?
137
+ @ImageInfos = []
138
+ params['ImageInfos'].each do |i|
139
+ imageinfo_tmp = ImageInfo.new
140
+ imageinfo_tmp.deserialize(i)
141
+ @ImageInfos << imageinfo_tmp
142
+ end
143
+ end
144
+ end
145
+ end
146
+
147
+ # CreateOrderAndDownloads返回参数结构体
148
+ class CreateOrderAndDownloadsResponse < TencentCloud::Common::AbstractModel
149
+ # @param DownloadInfos: 成功核销后可以获取图片基本信息和原图地址
150
+ # 注意:此字段可能返回 null,表示取不到有效值。
151
+ # @type DownloadInfos: Array
152
+ # @param TotalCount: 可下载图片数量
153
+ # @type TotalCount: Integer
154
+ # @param RequestId: 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
155
+ # @type RequestId: String
156
+
157
+ attr_accessor :DownloadInfos, :TotalCount, :RequestId
158
+
159
+ def initialize(downloadinfos=nil, totalcount=nil, requestid=nil)
160
+ @DownloadInfos = downloadinfos
161
+ @TotalCount = totalcount
162
+ @RequestId = requestid
163
+ end
164
+
165
+ def deserialize(params)
166
+ unless params['DownloadInfos'].nil?
167
+ @DownloadInfos = []
168
+ params['DownloadInfos'].each do |i|
169
+ downloadinfo_tmp = DownloadInfo.new
170
+ downloadinfo_tmp.deserialize(i)
171
+ @DownloadInfos << downloadinfo_tmp
172
+ end
173
+ end
174
+ @TotalCount = params['TotalCount']
175
+ @RequestId = params['RequestId']
176
+ end
177
+ end
178
+
179
+ # CreateOrderAndPay请求参数结构体
180
+ class CreateOrderAndPayRequest < TencentCloud::Common::AbstractModel
181
+ # @param ImageId: 图片ID
182
+ # @type ImageId: Integer
183
+ # @param AuthUserId: 授权人ID
184
+ # @type AuthUserId: String
185
+ # @param MarshalId: 售卖组合id
186
+ # @type MarshalId: Integer
187
+
188
+ attr_accessor :ImageId, :AuthUserId, :MarshalId
189
+
190
+ def initialize(imageid=nil, authuserid=nil, marshalid=nil)
191
+ @ImageId = imageid
192
+ @AuthUserId = authuserid
193
+ @MarshalId = marshalid
194
+ end
195
+
196
+ def deserialize(params)
197
+ @ImageId = params['ImageId']
198
+ @AuthUserId = params['AuthUserId']
199
+ @MarshalId = params['MarshalId']
200
+ end
201
+ end
202
+
203
+ # CreateOrderAndPay返回参数结构体
204
+ class CreateOrderAndPayResponse < TencentCloud::Common::AbstractModel
205
+ # @param OrderId: 订单ID
206
+ # @type OrderId: String
207
+ # @param RequestId: 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
208
+ # @type RequestId: String
209
+
210
+ attr_accessor :OrderId, :RequestId
211
+
212
+ def initialize(orderid=nil, requestid=nil)
213
+ @OrderId = orderid
214
+ @RequestId = requestid
215
+ end
216
+
217
+ def deserialize(params)
218
+ @OrderId = params['OrderId']
219
+ @RequestId = params['RequestId']
220
+ end
221
+ end
222
+
223
+ # DescribeAuthUsers请求参数结构体
224
+ class DescribeAuthUsersRequest < TencentCloud::Common::AbstractModel
225
+ # @param Limit: 分页大小
226
+ # @type Limit: Integer
227
+ # @param Offset: 页偏移量
228
+ # @type Offset: Integer
229
+
230
+ attr_accessor :Limit, :Offset
231
+
232
+ def initialize(limit=nil, offset=nil)
233
+ @Limit = limit
234
+ @Offset = offset
235
+ end
236
+
237
+ def deserialize(params)
238
+ @Limit = params['Limit']
239
+ @Offset = params['Offset']
240
+ end
241
+ end
242
+
243
+ # DescribeAuthUsers返回参数结构体
244
+ class DescribeAuthUsersResponse < TencentCloud::Common::AbstractModel
245
+ # @param Users: 授权人信息数组
246
+ # 注意:此字段可能返回 null,表示取不到有效值。
247
+ # @type Users: Array
248
+ # @param TotalCount: 总记录数
249
+ # @type TotalCount: Integer
250
+ # @param OldUser: 是否是老策略用户
251
+ # @type OldUser: Boolean
252
+ # @param RequestId: 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
253
+ # @type RequestId: String
254
+
255
+ attr_accessor :Users, :TotalCount, :OldUser, :RequestId
256
+
257
+ def initialize(users=nil, totalcount=nil, olduser=nil, requestid=nil)
258
+ @Users = users
259
+ @TotalCount = totalcount
260
+ @OldUser = olduser
261
+ @RequestId = requestid
262
+ end
263
+
264
+ def deserialize(params)
265
+ unless params['Users'].nil?
266
+ @Users = []
267
+ params['Users'].each do |i|
268
+ authinfo_tmp = AuthInfo.new
269
+ authinfo_tmp.deserialize(i)
270
+ @Users << authinfo_tmp
271
+ end
272
+ end
273
+ @TotalCount = params['TotalCount']
274
+ @OldUser = params['OldUser']
275
+ @RequestId = params['RequestId']
276
+ end
277
+ end
278
+
279
+ # DescribeDownloadInfos请求参数结构体
280
+ class DescribeDownloadInfosRequest < TencentCloud::Common::AbstractModel
281
+ # @param Limit: 默认10
282
+ # @type Limit: Integer
283
+ # @param Offset: 默认0
284
+ # @type Offset: Integer
285
+ # @param BeginTime: 开始时间晚于指定时间
286
+ # @type BeginTime: String
287
+ # @param EndTime: 结束时间早于指定时间
288
+ # @type EndTime: String
289
+ # @param ImageIds: 无效值,过滤结果为空
290
+ # @type ImageIds: Array
291
+
292
+ attr_accessor :Limit, :Offset, :BeginTime, :EndTime, :ImageIds
293
+
294
+ def initialize(limit=nil, offset=nil, begintime=nil, endtime=nil, imageids=nil)
295
+ @Limit = limit
296
+ @Offset = offset
297
+ @BeginTime = begintime
298
+ @EndTime = endtime
299
+ @ImageIds = imageids
300
+ end
301
+
302
+ def deserialize(params)
303
+ @Limit = params['Limit']
304
+ @Offset = params['Offset']
305
+ @BeginTime = params['BeginTime']
306
+ @EndTime = params['EndTime']
307
+ @ImageIds = params['ImageIds']
308
+ end
309
+ end
310
+
311
+ # DescribeDownloadInfos返回参数结构体
312
+ class DescribeDownloadInfosResponse < TencentCloud::Common::AbstractModel
313
+ # @param DownloadInfos: 核销下载记录
314
+ # 注意:此字段可能返回 null,表示取不到有效值。
315
+ # @type DownloadInfos: Array
316
+ # @param TotalCount: 总记录数量
317
+ # @type TotalCount: Integer
318
+ # @param RequestId: 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
319
+ # @type RequestId: String
320
+
321
+ attr_accessor :DownloadInfos, :TotalCount, :RequestId
322
+
323
+ def initialize(downloadinfos=nil, totalcount=nil, requestid=nil)
324
+ @DownloadInfos = downloadinfos
325
+ @TotalCount = totalcount
326
+ @RequestId = requestid
327
+ end
328
+
329
+ def deserialize(params)
330
+ unless params['DownloadInfos'].nil?
331
+ @DownloadInfos = []
332
+ params['DownloadInfos'].each do |i|
333
+ downloadinfo_tmp = DownloadInfo.new
334
+ downloadinfo_tmp.deserialize(i)
335
+ @DownloadInfos << downloadinfo_tmp
336
+ end
337
+ end
338
+ @TotalCount = params['TotalCount']
339
+ @RequestId = params['RequestId']
340
+ end
341
+ end
342
+
343
+ # DescribeImage请求参数结构体
344
+ class DescribeImageRequest < TencentCloud::Common::AbstractModel
345
+ # @param ImageId: 图片ID
346
+ # @type ImageId: Integer
347
+
348
+ attr_accessor :ImageId
349
+
350
+ def initialize(imageid=nil)
351
+ @ImageId = imageid
352
+ end
353
+
354
+ def deserialize(params)
355
+ @ImageId = params['ImageId']
356
+ end
357
+ end
358
+
359
+ # DescribeImage返回参数结构体
360
+ class DescribeImageResponse < TencentCloud::Common::AbstractModel
361
+ # @param ImageId: 图片ID
362
+ # @type ImageId: Integer
363
+ # @param Title: 图片标题
364
+ # @type Title: String
365
+ # @param Description: 图片描述
366
+ # @type Description: String
367
+ # @param PreviewUrl: 图片预览链接
368
+ # @type PreviewUrl: String
369
+ # @param ThumbUrl: 图片缩略图
370
+ # @type ThumbUrl: String
371
+ # @param Vendor: 图片供应商
372
+ # @type Vendor: String
373
+ # @param Marshals: 图片售卖组合信息
374
+ # @type Marshals: Array
375
+ # @param Width: 宽
376
+ # @type Width: Integer
377
+ # @param Height: 高
378
+ # @type Height: Integer
379
+ # @param ImageFormat: 图片格式 jpg/eps/psd/...
380
+ # @type ImageFormat: String
381
+ # @param ImageSenseType: 图片类型 摄影图片、插画、漫画、图表、矢量、psd、全景、gif、模板
382
+ # @type ImageSenseType: String
383
+ # @param Keywords: 关键词,多关键词用空格分隔
384
+ # @type Keywords: String
385
+ # @param LayeredGalleryId: 分层图库id
386
+ # @type LayeredGalleryId: Integer
387
+ # @param Orientation: 构图方式:horizontal:横图、vertical:竖图、square:方图
388
+ # @type Orientation: String
389
+ # @param RequestId: 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
390
+ # @type RequestId: String
391
+
392
+ attr_accessor :ImageId, :Title, :Description, :PreviewUrl, :ThumbUrl, :Vendor, :Marshals, :Width, :Height, :ImageFormat, :ImageSenseType, :Keywords, :LayeredGalleryId, :Orientation, :RequestId
393
+
394
+ def initialize(imageid=nil, title=nil, description=nil, previewurl=nil, thumburl=nil, vendor=nil, marshals=nil, width=nil, height=nil, imageformat=nil, imagesensetype=nil, keywords=nil, layeredgalleryid=nil, orientation=nil, requestid=nil)
395
+ @ImageId = imageid
396
+ @Title = title
397
+ @Description = description
398
+ @PreviewUrl = previewurl
399
+ @ThumbUrl = thumburl
400
+ @Vendor = vendor
401
+ @Marshals = marshals
402
+ @Width = width
403
+ @Height = height
404
+ @ImageFormat = imageformat
405
+ @ImageSenseType = imagesensetype
406
+ @Keywords = keywords
407
+ @LayeredGalleryId = layeredgalleryid
408
+ @Orientation = orientation
409
+ @RequestId = requestid
410
+ end
411
+
412
+ def deserialize(params)
413
+ @ImageId = params['ImageId']
414
+ @Title = params['Title']
415
+ @Description = params['Description']
416
+ @PreviewUrl = params['PreviewUrl']
417
+ @ThumbUrl = params['ThumbUrl']
418
+ @Vendor = params['Vendor']
419
+ unless params['Marshals'].nil?
420
+ @Marshals = []
421
+ params['Marshals'].each do |i|
422
+ imagemarshal_tmp = ImageMarshal.new
423
+ imagemarshal_tmp.deserialize(i)
424
+ @Marshals << imagemarshal_tmp
425
+ end
426
+ end
427
+ @Width = params['Width']
428
+ @Height = params['Height']
429
+ @ImageFormat = params['ImageFormat']
430
+ @ImageSenseType = params['ImageSenseType']
431
+ @Keywords = params['Keywords']
432
+ @LayeredGalleryId = params['LayeredGalleryId']
433
+ @Orientation = params['Orientation']
434
+ @RequestId = params['RequestId']
435
+ end
436
+ end
437
+
438
+ # DescribeImages请求参数结构体
439
+ class DescribeImagesRequest < TencentCloud::Common::AbstractModel
440
+ # @param Offset: 页偏移量
441
+ # @type Offset: Integer
442
+ # @param Limit: 页大小
443
+ # @type Limit: Integer
444
+ # @param Keyword: 搜索关键字
445
+ # @type Keyword: String
446
+ # @param Orientation: 构图方式,可选以下值:horizontal、vertical、square,分别代表以下含义:横图、竖图、方图
447
+ # @type Orientation: String
448
+ # @param ImageSenseType: 图片类型,可选以下值:照片、插画
449
+ # @type ImageSenseType: String
450
+ # @param LayeredGalleryIds: 分层图库id数组,可选以下数值:1(基础),2(精选),3(高级)
451
+ # @type LayeredGalleryIds: Array
452
+
453
+ attr_accessor :Offset, :Limit, :Keyword, :Orientation, :ImageSenseType, :LayeredGalleryIds
454
+
455
+ def initialize(offset=nil, limit=nil, keyword=nil, orientation=nil, imagesensetype=nil, layeredgalleryids=nil)
456
+ @Offset = offset
457
+ @Limit = limit
458
+ @Keyword = keyword
459
+ @Orientation = orientation
460
+ @ImageSenseType = imagesensetype
461
+ @LayeredGalleryIds = layeredgalleryids
462
+ end
463
+
464
+ def deserialize(params)
465
+ @Offset = params['Offset']
466
+ @Limit = params['Limit']
467
+ @Keyword = params['Keyword']
468
+ @Orientation = params['Orientation']
469
+ @ImageSenseType = params['ImageSenseType']
470
+ @LayeredGalleryIds = params['LayeredGalleryIds']
471
+ end
472
+ end
473
+
474
+ # DescribeImages返回参数结构体
475
+ class DescribeImagesResponse < TencentCloud::Common::AbstractModel
476
+ # @param Offset: 页偏移量
477
+ # @type Offset: Integer
478
+ # @param Limit: 页大小
479
+ # @type Limit: Integer
480
+ # @param Total: 总条数
481
+ # @type Total: Integer
482
+ # @param HaveMore: 是否有下一页
483
+ # @type HaveMore: Boolean
484
+ # @param Items: 图片信息数组
485
+ # @type Items: Array
486
+ # @param RequestId: 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
487
+ # @type RequestId: String
488
+
489
+ attr_accessor :Offset, :Limit, :Total, :HaveMore, :Items, :RequestId
490
+
491
+ def initialize(offset=nil, limit=nil, total=nil, havemore=nil, items=nil, requestid=nil)
492
+ @Offset = offset
493
+ @Limit = limit
494
+ @Total = total
495
+ @HaveMore = havemore
496
+ @Items = items
497
+ @RequestId = requestid
498
+ end
499
+
500
+ def deserialize(params)
501
+ @Offset = params['Offset']
502
+ @Limit = params['Limit']
503
+ @Total = params['Total']
504
+ @HaveMore = params['HaveMore']
505
+ unless params['Items'].nil?
506
+ @Items = []
507
+ params['Items'].each do |i|
508
+ imageitem_tmp = ImageItem.new
509
+ imageitem_tmp.deserialize(i)
510
+ @Items << imageitem_tmp
511
+ end
512
+ end
513
+ @RequestId = params['RequestId']
514
+ end
515
+ end
516
+
517
+ # 图片下载信息
518
+ class DownloadInfo < TencentCloud::Common::AbstractModel
519
+ # @param ImageInfo: 图片基础信息
520
+ # @type ImageInfo: :class:`Tencentcloud::Ape.v20200513.models.ImageInfo`
521
+ # @param ImageUrl: 图片原图URL
522
+ # @type ImageUrl: String
523
+ # @param ImageThumbUrl: 图片缩略图URL
524
+ # @type ImageThumbUrl: String
525
+ # @param OrderId: 订单Id
526
+ # @type OrderId: String
527
+ # @param OrderCreateTime: 订单创建时间
528
+ # @type OrderCreateTime: String
529
+ # @param DownloadId: 下载Id
530
+ # @type DownloadId: String
531
+ # @param DownloadTime: 下载时间
532
+ # @type DownloadTime: String
533
+ # @param ConsumeType: 图片购买类型,单张/会员
534
+ # @type ConsumeType: Integer
535
+ # @param FirstDownload: 是否首次下载
536
+ # @type FirstDownload: Boolean
537
+
538
+ attr_accessor :ImageInfo, :ImageUrl, :ImageThumbUrl, :OrderId, :OrderCreateTime, :DownloadId, :DownloadTime, :ConsumeType, :FirstDownload
539
+
540
+ def initialize(imageinfo=nil, imageurl=nil, imagethumburl=nil, orderid=nil, ordercreatetime=nil, downloadid=nil, downloadtime=nil, consumetype=nil, firstdownload=nil)
541
+ @ImageInfo = imageinfo
542
+ @ImageUrl = imageurl
543
+ @ImageThumbUrl = imagethumburl
544
+ @OrderId = orderid
545
+ @OrderCreateTime = ordercreatetime
546
+ @DownloadId = downloadid
547
+ @DownloadTime = downloadtime
548
+ @ConsumeType = consumetype
549
+ @FirstDownload = firstdownload
550
+ end
551
+
552
+ def deserialize(params)
553
+ unless params['ImageInfo'].nil?
554
+ @ImageInfo = ImageInfo.new
555
+ @ImageInfo.deserialize(params['ImageInfo'])
556
+ end
557
+ @ImageUrl = params['ImageUrl']
558
+ @ImageThumbUrl = params['ImageThumbUrl']
559
+ @OrderId = params['OrderId']
560
+ @OrderCreateTime = params['OrderCreateTime']
561
+ @DownloadId = params['DownloadId']
562
+ @DownloadTime = params['DownloadTime']
563
+ @ConsumeType = params['ConsumeType']
564
+ @FirstDownload = params['FirstDownload']
565
+ end
566
+ end
567
+
568
+ # 图片基础信息
569
+ class ImageInfo < TencentCloud::Common::AbstractModel
570
+ # @param ImageId: 图片Id
571
+ # @type ImageId: Integer
572
+ # @param LicenseScopeId: 授权场景Id
573
+ # @type LicenseScopeId: Integer
574
+ # @param DimensionsNameId: 尺寸名称Id
575
+ # @type DimensionsNameId: Integer
576
+ # @param UserId: 平台用户标识
577
+ # @type UserId: String
578
+ # @param DownloadPrice: 平台用户下载图片购买的价格(单位:分)
579
+ # @type DownloadPrice: Integer
580
+ # @param DownloadType: 下载类型。匹配集合中的任意元素:
581
+ # <li>Single: 单张购买下载</li>
582
+ # <li>BasicEnterpriseMember: 企业基础会员下载</li>
583
+ # <li>AdvancedEnterpriseMember: 企业高级会员下载</li>
584
+ # <li>DistinguishedEnterpriseMember: 企业尊享会员下载</li>
585
+ # @type DownloadType: String
586
+
587
+ attr_accessor :ImageId, :LicenseScopeId, :DimensionsNameId, :UserId, :DownloadPrice, :DownloadType
588
+
589
+ def initialize(imageid=nil, licensescopeid=nil, dimensionsnameid=nil, userid=nil, downloadprice=nil, downloadtype=nil)
590
+ @ImageId = imageid
591
+ @LicenseScopeId = licensescopeid
592
+ @DimensionsNameId = dimensionsnameid
593
+ @UserId = userid
594
+ @DownloadPrice = downloadprice
595
+ @DownloadType = downloadtype
596
+ end
597
+
598
+ def deserialize(params)
599
+ @ImageId = params['ImageId']
600
+ @LicenseScopeId = params['LicenseScopeId']
601
+ @DimensionsNameId = params['DimensionsNameId']
602
+ @UserId = params['UserId']
603
+ @DownloadPrice = params['DownloadPrice']
604
+ @DownloadType = params['DownloadType']
605
+ end
606
+ end
607
+
608
+ # 图片信息条目
609
+ class ImageItem < TencentCloud::Common::AbstractModel
610
+ # @param ImageId: 图片ID
611
+ # @type ImageId: Integer
612
+ # @param Title: 图片标题
613
+ # @type Title: String
614
+ # @param Description: 图片描述
615
+ # @type Description: String
616
+ # @param PreviewUrl: 图片预览链接
617
+ # @type PreviewUrl: String
618
+ # @param ThumbUrl: 图片缩略图
619
+ # @type ThumbUrl: String
620
+ # @param Vendor: 图片供应商
621
+ # @type Vendor: String
622
+ # @param Keywords: 图片关键词
623
+ # @type Keywords: String
624
+ # @param Width: 宽
625
+ # @type Width: Integer
626
+ # @param Height: 高
627
+ # @type Height: Integer
628
+
629
+ attr_accessor :ImageId, :Title, :Description, :PreviewUrl, :ThumbUrl, :Vendor, :Keywords, :Width, :Height
630
+
631
+ def initialize(imageid=nil, title=nil, description=nil, previewurl=nil, thumburl=nil, vendor=nil, keywords=nil, width=nil, height=nil)
632
+ @ImageId = imageid
633
+ @Title = title
634
+ @Description = description
635
+ @PreviewUrl = previewurl
636
+ @ThumbUrl = thumburl
637
+ @Vendor = vendor
638
+ @Keywords = keywords
639
+ @Width = width
640
+ @Height = height
641
+ end
642
+
643
+ def deserialize(params)
644
+ @ImageId = params['ImageId']
645
+ @Title = params['Title']
646
+ @Description = params['Description']
647
+ @PreviewUrl = params['PreviewUrl']
648
+ @ThumbUrl = params['ThumbUrl']
649
+ @Vendor = params['Vendor']
650
+ @Keywords = params['Keywords']
651
+ @Width = params['Width']
652
+ @Height = params['Height']
653
+ end
654
+ end
655
+
656
+ # 图片售卖组合信息
657
+ class ImageMarshal < TencentCloud::Common::AbstractModel
658
+ # @param MarshalId: 售卖组合唯一标识
659
+ # @type MarshalId: Integer
660
+ # @param Height: 图片高度
661
+ # @type Height: Integer
662
+ # @param Width: 图片宽度
663
+ # @type Width: Integer
664
+ # @param Size: 图片大小
665
+ # @type Size: Integer
666
+ # @param Format: 图片格式
667
+ # @type Format: String
668
+ # @param Price: 图片价格(单位:分)
669
+ # @type Price: Integer
670
+ # @param LicenseScope: 授权范围
671
+ # @type LicenseScope: String
672
+ # @param IsVip: 是否支持VIP购买
673
+ # @type IsVip: Boolean
674
+ # @param LicenseScopeId: 授权范围id
675
+ # @type LicenseScopeId: Integer
676
+ # @param DimensionsName: 尺寸
677
+ # @type DimensionsName: String
678
+ # @param DimensionsNameId: 尺寸id
679
+ # @type DimensionsNameId: Integer
680
+
681
+ attr_accessor :MarshalId, :Height, :Width, :Size, :Format, :Price, :LicenseScope, :IsVip, :LicenseScopeId, :DimensionsName, :DimensionsNameId
682
+
683
+ def initialize(marshalid=nil, height=nil, width=nil, size=nil, format=nil, price=nil, licensescope=nil, isvip=nil, licensescopeid=nil, dimensionsname=nil, dimensionsnameid=nil)
684
+ @MarshalId = marshalid
685
+ @Height = height
686
+ @Width = width
687
+ @Size = size
688
+ @Format = format
689
+ @Price = price
690
+ @LicenseScope = licensescope
691
+ @IsVip = isvip
692
+ @LicenseScopeId = licensescopeid
693
+ @DimensionsName = dimensionsname
694
+ @DimensionsNameId = dimensionsnameid
695
+ end
696
+
697
+ def deserialize(params)
698
+ @MarshalId = params['MarshalId']
699
+ @Height = params['Height']
700
+ @Width = params['Width']
701
+ @Size = params['Size']
702
+ @Format = params['Format']
703
+ @Price = params['Price']
704
+ @LicenseScope = params['LicenseScope']
705
+ @IsVip = params['IsVip']
706
+ @LicenseScopeId = params['LicenseScopeId']
707
+ @DimensionsName = params['DimensionsName']
708
+ @DimensionsNameId = params['DimensionsNameId']
709
+ end
710
+ end
711
+
712
+ end
713
+ end
714
+ end
715
+
metadata ADDED
@@ -0,0 +1,66 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: tencentcloud-sdk-ape
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.0.200
5
+ platform: ruby
6
+ authors:
7
+ - Tencent Cloud
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+ date: 2021-11-11 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: tencentcloud-sdk-common
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.0'
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.0'
27
+ description: Tencent Cloud Ruby SDK is the official software development kit, which
28
+ allows Ruby developers to write software that makes use of Tencent Cloud service
29
+ APE.
30
+ email:
31
+ - tencentcloudapi@tencent.com
32
+ executables: []
33
+ extensions: []
34
+ extra_rdoc_files: []
35
+ files:
36
+ - lib/VERSION
37
+ - lib/tencentcloud-sdk-ape.rb
38
+ - lib/v20200513/client.rb
39
+ - lib/v20200513/models.rb
40
+ homepage: https://github.com/TencentCloud/tencentcloud-sdk-ruby
41
+ licenses:
42
+ - Apache-2.0
43
+ metadata:
44
+ source_code_uri: https://github.com/TencentCloud/tencentcloud-sdk-ruby/tencentcloud-sdk-ape
45
+ changelog_uri: https://github.com/TencentCloud/tencentcloud-sdk-ruby/blob/master/CHANGELOG.md
46
+ post_install_message:
47
+ rdoc_options: []
48
+ require_paths:
49
+ - lib
50
+ required_ruby_version: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ">="
53
+ - !ruby/object:Gem::Version
54
+ version: '0'
55
+ required_rubygems_version: !ruby/object:Gem::Requirement
56
+ requirements:
57
+ - - ">="
58
+ - !ruby/object:Gem::Version
59
+ version: '0'
60
+ requirements: []
61
+ rubyforge_project:
62
+ rubygems_version: 2.6.14
63
+ signing_key:
64
+ specification_version: 4
65
+ summary: Tencent Cloud SDK for Ruby - APE
66
+ test_files: []