tencentcloud-sdk-vod 3.0.902 → 3.0.904

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
  SHA1:
3
- metadata.gz: f2415080a9efbf2c6aa618b165fe705191048d8f
4
- data.tar.gz: 44e4d6b5a2f7082241b03f0b0c2baa5adcfe119a
3
+ metadata.gz: eb02f197bb298a767d9748519399e8f0f7be7d5f
4
+ data.tar.gz: 5d57ddaf79a81970537953eccd0fce58ea9a3ec3
5
5
  SHA512:
6
- metadata.gz: bd9c58886f4d371f56fb056c2c7ca5e200fc31bf64c4b69896b4dadb8a270e94f457c04a8eadeede34099ea9cfee64a73efa7bd9a68877bdedd235b299a42247
7
- data.tar.gz: c23ba376ffb5c84fc39a9a771b471dc06c47ff329ea0b0a1940c0abd1a30897e730997831d841209a9ff9dd63741c9ad85b67f2cd5f8083fe0b451551980e8e1
6
+ metadata.gz: 2ecfde00eb5399eb00716690e74d076dfd58b04c9467e664935b38de08b8e8713b06e102955d82631ca9896e704a6db44f917b018c2ad178a660bd4ef2250803
7
+ data.tar.gz: d7bf2f6cc009002a084ae2f62683fe1f1ebb860fa5b5a31fe770c636ffa3f70b70a944fbeee5a88b133309f9497c4e572949388f2feb77b2974359dd34bdad06
data/lib/VERSION CHANGED
@@ -1 +1 @@
1
- 3.0.902
1
+ 3.0.904
@@ -5,6 +5,9 @@ require 'tencentcloud-sdk-common'
5
5
  require_relative 'v20180717/client'
6
6
  require_relative 'v20180717/models'
7
7
 
8
+ require_relative 'v20240718/client'
9
+ require_relative 'v20240718/models'
10
+
8
11
  module TencentCloud
9
12
  module Vod
10
13
  end
@@ -0,0 +1,60 @@
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 Vod
21
+ module V20240718
22
+ class Client < TencentCloud::Common::AbstractClient
23
+
24
+ def initialize(credential, region, profile = nil)
25
+ api_version = '2024-07-18'
26
+ api_endpoint = 'vod.tencentcloudapi.com'
27
+ sdk_version = 'VOD_' + 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 CreateStorageCredentials.
35
+ # @type request: :class:`Tencentcloud::vod::V20240718::CreateStorageCredentialsRequest`
36
+ # @rtype: :class:`Tencentcloud::vod::V20240718::CreateStorageCredentialsResponse`
37
+ def CreateStorageCredentials(request)
38
+ body = send_request('CreateStorageCredentials', request.serialize)
39
+ response = JSON.parse(body)
40
+ if response['Response'].key?('Error') == false
41
+ model = CreateStorageCredentialsResponse.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
+ end
58
+ end
59
+ end
60
+ end
@@ -0,0 +1,103 @@
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 Vod
19
+ module V20240718
20
+ # CreateStorageCredentials请求参数结构体
21
+ class CreateStorageCredentialsRequest < TencentCloud::Common::AbstractModel
22
+ # @param SubAppId: <b>点播[应用](/document/product/266/14574) ID。</b>
23
+ # @type SubAppId: Integer
24
+ # @param Policy: 按照下方语法组装好策略后,先序列化为字符串,再做 urlencode,结果作为 Policy 字段入参。服务端会对该字段做 urldecode,并按解析后的策略授予临时访问凭证权限,请按规范传入参数。
25
+ # 注意:
26
+ # 1.策略语法参照[访问管理策略](/document/product/598/10603)。
27
+ # 2.策略中不能包含 principal 元素。
28
+ # 3.策略的 action 元素仅支持:<li>name/vod:PutObject;</li><li>name/vod:ListParts;</li><li>name/vod:PostObject;</li><li>name/vod:InitiateMultipartUpload;</li><li>name/vod:UploadPart;</li><li>name/vod:CompleteMultipartUpload;</li><li>name/vod:AbortMultipartUpload;</li><li>name/vod:ListMultipartUploads;</li>4.策略的 resource 元素填写格式为:qcs::vod::uid/[账号AppID]:prefix//[子应用ID]/[存储桶ID]/[存储路径],其中账号AppID、子应用ID、存储桶ID和存储路径要按需填写,其他内容不允许改动,例:qcs::vod::uid/1:prefix//1/1/path。
29
+ # @type Policy: String
30
+ # @param DurationSeconds: 指定临时证书的有效期,单位:秒。
31
+ # 默认 1800 秒,最大 129600 秒。
32
+ # @type DurationSeconds: Integer
33
+
34
+ attr_accessor :SubAppId, :Policy, :DurationSeconds
35
+
36
+ def initialize(subappid=nil, policy=nil, durationseconds=nil)
37
+ @SubAppId = subappid
38
+ @Policy = policy
39
+ @DurationSeconds = durationseconds
40
+ end
41
+
42
+ def deserialize(params)
43
+ @SubAppId = params['SubAppId']
44
+ @Policy = params['Policy']
45
+ @DurationSeconds = params['DurationSeconds']
46
+ end
47
+ end
48
+
49
+ # CreateStorageCredentials返回参数结构体
50
+ class CreateStorageCredentialsResponse < TencentCloud::Common::AbstractModel
51
+ # @param Credentials: 临时访问凭证。
52
+ # @type Credentials: :class:`Tencentcloud::Vod.v20240718.models.Credentials`
53
+ # @param RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
54
+ # @type RequestId: String
55
+
56
+ attr_accessor :Credentials, :RequestId
57
+
58
+ def initialize(credentials=nil, requestid=nil)
59
+ @Credentials = credentials
60
+ @RequestId = requestid
61
+ end
62
+
63
+ def deserialize(params)
64
+ unless params['Credentials'].nil?
65
+ @Credentials = Credentials.new
66
+ @Credentials.deserialize(params['Credentials'])
67
+ end
68
+ @RequestId = params['RequestId']
69
+ end
70
+ end
71
+
72
+ # 临时证书。
73
+ class Credentials < TencentCloud::Common::AbstractModel
74
+ # @param AccessKeyId: 秘钥 ID。
75
+ # @type AccessKeyId: String
76
+ # @param SecretAccessKey: 秘钥 Key。
77
+ # @type SecretAccessKey: String
78
+ # @param SessionToken: token。token长度和绑定的策略有关,最长不超过4096字节。
79
+ # @type SessionToken: String
80
+ # @param Expiration: 凭据的过期时间。
81
+ # @type Expiration: String
82
+
83
+ attr_accessor :AccessKeyId, :SecretAccessKey, :SessionToken, :Expiration
84
+
85
+ def initialize(accesskeyid=nil, secretaccesskey=nil, sessiontoken=nil, expiration=nil)
86
+ @AccessKeyId = accesskeyid
87
+ @SecretAccessKey = secretaccesskey
88
+ @SessionToken = sessiontoken
89
+ @Expiration = expiration
90
+ end
91
+
92
+ def deserialize(params)
93
+ @AccessKeyId = params['AccessKeyId']
94
+ @SecretAccessKey = params['SecretAccessKey']
95
+ @SessionToken = params['SessionToken']
96
+ @Expiration = params['Expiration']
97
+ end
98
+ end
99
+
100
+ end
101
+ end
102
+ end
103
+
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tencentcloud-sdk-vod
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.902
4
+ version: 3.0.904
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tencent Cloud
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-09-09 00:00:00.000000000 Z
11
+ date: 2024-09-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: tencentcloud-sdk-common
@@ -34,6 +34,8 @@ extensions: []
34
34
  extra_rdoc_files: []
35
35
  files:
36
36
  - lib/tencentcloud-sdk-vod.rb
37
+ - lib/v20240718/models.rb
38
+ - lib/v20240718/client.rb
37
39
  - lib/v20180717/models.rb
38
40
  - lib/v20180717/client.rb
39
41
  - lib/VERSION