tencentcloud-sdk-smop 3.0.534
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/lib/VERSION +1 -0
- data/lib/tencentcloud-sdk-smop.rb +11 -0
- data/lib/v20201203/client.rb +60 -0
- data/lib/v20201203/models.rb +178 -0
- metadata +66 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: c684ef4e30fa1274bdf3fdb79b61273b14bf560b
|
4
|
+
data.tar.gz: 5fd42cd1134710bea4205894f4992551f87aa1b1
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: fdefa0d260720ccb2e1b57d62d8ea3c56c332ed79cf1649e652cbb73479f7a0213cd8b57a2fea85345de9cb4f0ed38a46daa50f479d6586313d54c37921c5ce5
|
7
|
+
data.tar.gz: d3aa61ea425e425b010454cf4b36dc8741012b9e0b8ad9481a2af16130bdffe67735ef21699f15e35d985d42871d1ee6f2e7465dc66c0ea2417891593166ca8a
|
data/lib/VERSION
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
3.0.534
|
@@ -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 Smop
|
21
|
+
module V20201203
|
22
|
+
class Client < TencentCloud::Common::AbstractClient
|
23
|
+
|
24
|
+
def initialize(credential, region, profile = nil)
|
25
|
+
api_version = '2020-12-03'
|
26
|
+
api_endpoint = 'smop.tencentcloudapi.com'
|
27
|
+
sdk_version = 'SMOP_' + 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 SubmitTaskEvent.
|
35
|
+
# @type request: :class:`Tencentcloud::smop::V20201203::SubmitTaskEventRequest`
|
36
|
+
# @rtype: :class:`Tencentcloud::smop::V20201203::SubmitTaskEventResponse`
|
37
|
+
def SubmitTaskEvent(request)
|
38
|
+
body = send_request('SubmitTaskEvent', request.serialize)
|
39
|
+
response = JSON.parse(body)
|
40
|
+
if response['Response'].key?('Error') == false
|
41
|
+
model = SubmitTaskEventResponse.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,178 @@
|
|
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 Smop
|
19
|
+
module V20201203
|
20
|
+
# SubmitTaskEvent请求参数结构体
|
21
|
+
class SubmitTaskEventRequest < TencentCloud::Common::AbstractModel
|
22
|
+
# @param AccountId: 用户ID
|
23
|
+
# @type AccountId: String
|
24
|
+
# @param DeviceId: 设备ID
|
25
|
+
# @type DeviceId: String
|
26
|
+
# @param OrderId: 订单ID
|
27
|
+
# @type OrderId: String
|
28
|
+
# @param Code: 任务事件Code
|
29
|
+
# @type Code: String
|
30
|
+
# @param Async: 同步异步方式
|
31
|
+
# @type Async: Integer
|
32
|
+
# @param ProductId: 产品ID
|
33
|
+
# @type ProductId: Integer
|
34
|
+
# @param NotifyURL: 回调地址
|
35
|
+
# @type NotifyURL: String
|
36
|
+
|
37
|
+
attr_accessor :AccountId, :DeviceId, :OrderId, :Code, :Async, :ProductId, :NotifyURL
|
38
|
+
|
39
|
+
def initialize(accountid=nil, deviceid=nil, orderid=nil, code=nil, async=nil, productid=nil, notifyurl=nil)
|
40
|
+
@AccountId = accountid
|
41
|
+
@DeviceId = deviceid
|
42
|
+
@OrderId = orderid
|
43
|
+
@Code = code
|
44
|
+
@Async = async
|
45
|
+
@ProductId = productid
|
46
|
+
@NotifyURL = notifyurl
|
47
|
+
end
|
48
|
+
|
49
|
+
def deserialize(params)
|
50
|
+
@AccountId = params['AccountId']
|
51
|
+
@DeviceId = params['DeviceId']
|
52
|
+
@OrderId = params['OrderId']
|
53
|
+
@Code = params['Code']
|
54
|
+
@Async = params['Async']
|
55
|
+
@ProductId = params['ProductId']
|
56
|
+
@NotifyURL = params['NotifyURL']
|
57
|
+
end
|
58
|
+
end
|
59
|
+
|
60
|
+
# SubmitTaskEvent返回参数结构体
|
61
|
+
class SubmitTaskEventResponse < TencentCloud::Common::AbstractModel
|
62
|
+
# @param OrderId: 订单ID
|
63
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
64
|
+
# @type OrderId: String
|
65
|
+
# @param Code: 信息码
|
66
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
67
|
+
# @type Code: Integer
|
68
|
+
# @param Message: success
|
69
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
70
|
+
# @type Message: String
|
71
|
+
# @param Data: 任务处理结果列表
|
72
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
73
|
+
# @type Data: Array
|
74
|
+
# @param RequestId: 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
|
75
|
+
# @type RequestId: String
|
76
|
+
|
77
|
+
attr_accessor :OrderId, :Code, :Message, :Data, :RequestId
|
78
|
+
|
79
|
+
def initialize(orderid=nil, code=nil, message=nil, data=nil, requestid=nil)
|
80
|
+
@OrderId = orderid
|
81
|
+
@Code = code
|
82
|
+
@Message = message
|
83
|
+
@Data = data
|
84
|
+
@RequestId = requestid
|
85
|
+
end
|
86
|
+
|
87
|
+
def deserialize(params)
|
88
|
+
@OrderId = params['OrderId']
|
89
|
+
@Code = params['Code']
|
90
|
+
@Message = params['Message']
|
91
|
+
unless params['Data'].nil?
|
92
|
+
@Data = []
|
93
|
+
params['Data'].each do |i|
|
94
|
+
taskeventdata_tmp = TaskEventData.new
|
95
|
+
taskeventdata_tmp.deserialize(i)
|
96
|
+
@Data << taskeventdata_tmp
|
97
|
+
end
|
98
|
+
end
|
99
|
+
@RequestId = params['RequestId']
|
100
|
+
end
|
101
|
+
end
|
102
|
+
|
103
|
+
# 后端提交任务事件返回Data复杂类型
|
104
|
+
class TaskEventData < TencentCloud::Common::AbstractModel
|
105
|
+
# @param Code: 状态码
|
106
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
107
|
+
# @type Code: Integer
|
108
|
+
# @param Message: 提示信息
|
109
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
110
|
+
# @type Message: String
|
111
|
+
# @param TaskId: 任务ID
|
112
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
113
|
+
# @type TaskId: Integer
|
114
|
+
# @param TaskOrderId: 当前完成或正在完成的任务订单ID
|
115
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
116
|
+
# @type TaskOrderId: String
|
117
|
+
# @param TaskCode: 当前任务订单状态码
|
118
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
119
|
+
# @type TaskCode: Integer
|
120
|
+
# @param TaskCoinNumber: 获得积分数/成长值
|
121
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
122
|
+
# @type TaskCoinNumber: Integer
|
123
|
+
# @param TaskType: 任务类型后台代码
|
124
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
125
|
+
# @type TaskType: Integer
|
126
|
+
# @param TotalCoin: 当前积分/成长值
|
127
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
128
|
+
# @type TotalCoin: Integer
|
129
|
+
# @param Attach: 用户透传的代码块
|
130
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
131
|
+
# @type Attach: String
|
132
|
+
# @param DoneTimes: 计次任务当前完成次数
|
133
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
134
|
+
# @type DoneTimes: Integer
|
135
|
+
# @param TotalTimes: 计次任务当前所需完成次数
|
136
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
137
|
+
# @type TotalTimes: Integer
|
138
|
+
# @param TaskName: 任务名称
|
139
|
+
# 注意:此字段可能返回 null,表示取不到有效值。
|
140
|
+
# @type TaskName: String
|
141
|
+
|
142
|
+
attr_accessor :Code, :Message, :TaskId, :TaskOrderId, :TaskCode, :TaskCoinNumber, :TaskType, :TotalCoin, :Attach, :DoneTimes, :TotalTimes, :TaskName
|
143
|
+
|
144
|
+
def initialize(code=nil, message=nil, taskid=nil, taskorderid=nil, taskcode=nil, taskcoinnumber=nil, tasktype=nil, totalcoin=nil, attach=nil, donetimes=nil, totaltimes=nil, taskname=nil)
|
145
|
+
@Code = code
|
146
|
+
@Message = message
|
147
|
+
@TaskId = taskid
|
148
|
+
@TaskOrderId = taskorderid
|
149
|
+
@TaskCode = taskcode
|
150
|
+
@TaskCoinNumber = taskcoinnumber
|
151
|
+
@TaskType = tasktype
|
152
|
+
@TotalCoin = totalcoin
|
153
|
+
@Attach = attach
|
154
|
+
@DoneTimes = donetimes
|
155
|
+
@TotalTimes = totaltimes
|
156
|
+
@TaskName = taskname
|
157
|
+
end
|
158
|
+
|
159
|
+
def deserialize(params)
|
160
|
+
@Code = params['Code']
|
161
|
+
@Message = params['Message']
|
162
|
+
@TaskId = params['TaskId']
|
163
|
+
@TaskOrderId = params['TaskOrderId']
|
164
|
+
@TaskCode = params['TaskCode']
|
165
|
+
@TaskCoinNumber = params['TaskCoinNumber']
|
166
|
+
@TaskType = params['TaskType']
|
167
|
+
@TotalCoin = params['TotalCoin']
|
168
|
+
@Attach = params['Attach']
|
169
|
+
@DoneTimes = params['DoneTimes']
|
170
|
+
@TotalTimes = params['TotalTimes']
|
171
|
+
@TaskName = params['TaskName']
|
172
|
+
end
|
173
|
+
end
|
174
|
+
|
175
|
+
end
|
176
|
+
end
|
177
|
+
end
|
178
|
+
|
metadata
ADDED
@@ -0,0 +1,66 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: tencentcloud-sdk-smop
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 3.0.534
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Tencent Cloud
|
8
|
+
autorequire:
|
9
|
+
bindir: bin
|
10
|
+
cert_chain: []
|
11
|
+
date: 2023-03-21 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: '3.0'
|
20
|
+
type: :runtime
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - ~>
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '3.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
|
+
SMOP.
|
30
|
+
email:
|
31
|
+
- tencentcloudapi@tencent.com
|
32
|
+
executables: []
|
33
|
+
extensions: []
|
34
|
+
extra_rdoc_files: []
|
35
|
+
files:
|
36
|
+
- lib/tencentcloud-sdk-smop.rb
|
37
|
+
- lib/v20201203/models.rb
|
38
|
+
- lib/v20201203/client.rb
|
39
|
+
- lib/VERSION
|
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-smop
|
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.0.14
|
63
|
+
signing_key:
|
64
|
+
specification_version: 4
|
65
|
+
summary: Tencent Cloud SDK for Ruby - SMOP
|
66
|
+
test_files: []
|