Class: TencentCloud::Intlpartnersmgt::V20220928::Client
- Inherits:
-
Common::AbstractClient
- Object
- Common::AbstractClient
- TencentCloud::Intlpartnersmgt::V20220928::Client
- Defined in:
- lib/v20220928/client.rb
Instance Method Summary collapse
-
#AllocateCustomerCredit(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::AllocateCustomerCreditResponse`.
-
#CreateAccount(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::CreateAccountResponse`.
-
#GetCountryCodes(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::GetCountryCodesResponse`.
-
#initialize(credential, region, profile = nil) ⇒ Client
constructor
A new instance of Client.
-
#QueryCreditAllocationHistory(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::QueryCreditAllocationHistoryResponse`.
-
#QueryCreditByUinList(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::QueryCreditByUinListResponse`.
-
#QueryCustomersCredit(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::QueryCustomersCreditResponse`.
-
#QueryDirectCustomersCredit(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::QueryDirectCustomersCreditResponse`.
-
#QueryPartnerCredit(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::QueryPartnerCreditResponse`.
-
#QueryVoucherAmountByUin(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::QueryVoucherAmountByUinResponse`.
-
#QueryVoucherListByUin(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::QueryVoucherListByUinResponse`.
-
#QueryVoucherPool(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::QueryVoucherPoolResponse`.
Constructor Details
#initialize(credential, region, profile = nil) ⇒ Client
Returns a new instance of Client.
24 25 26 27 28 29 |
# File 'lib/v20220928/client.rb', line 24 def initialize(credential, region, profile = nil) api_version = '2022-09-28' api_endpoint = 'intlpartnersmgt.tencentcloudapi.com' sdk_version = 'INTLPARTNERSMGT_' + File.read(File.('../VERSION', __dir__)).strip super(credential, region, api_version, api_endpoint, sdk_version, profile) end |
Instance Method Details
#AllocateCustomerCredit(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::AllocateCustomerCreditResponse`
41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 |
# File 'lib/v20220928/client.rb', line 41 def AllocateCustomerCredit(request) body = send_request('AllocateCustomerCredit', request.serialize) response = JSON.parse(body) if response['Response'].key?('Error') == false model = AllocateCustomerCreditResponse.new model.deserialize(response['Response']) model else code = response['Response']['Error']['Code'] = response['Response']['Error']['Message'] reqid = response['Response']['RequestId'] raise TencentCloud::Common::TencentCloudSDKException.new(code, , reqid) end rescue TencentCloud::Common::TencentCloudSDKException => e raise e rescue StandardError => e raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect) end |
#CreateAccount(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::CreateAccountResponse`
69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 |
# File 'lib/v20220928/client.rb', line 69 def CreateAccount(request) body = send_request('CreateAccount', request.serialize) response = JSON.parse(body) if response['Response'].key?('Error') == false model = CreateAccountResponse.new model.deserialize(response['Response']) model else code = response['Response']['Error']['Code'] = response['Response']['Error']['Message'] reqid = response['Response']['RequestId'] raise TencentCloud::Common::TencentCloudSDKException.new(code, , reqid) end rescue TencentCloud::Common::TencentCloudSDKException => e raise e rescue StandardError => e raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect) end |
#GetCountryCodes(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::GetCountryCodesResponse`
93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 |
# File 'lib/v20220928/client.rb', line 93 def GetCountryCodes(request) body = send_request('GetCountryCodes', request.serialize) response = JSON.parse(body) if response['Response'].key?('Error') == false model = GetCountryCodesResponse.new model.deserialize(response['Response']) model else code = response['Response']['Error']['Code'] = response['Response']['Error']['Message'] reqid = response['Response']['RequestId'] raise TencentCloud::Common::TencentCloudSDKException.new(code, , reqid) end rescue TencentCloud::Common::TencentCloudSDKException => e raise e rescue StandardError => e raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect) end |
#QueryCreditAllocationHistory(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::QueryCreditAllocationHistoryResponse`
117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 |
# File 'lib/v20220928/client.rb', line 117 def QueryCreditAllocationHistory(request) body = send_request('QueryCreditAllocationHistory', request.serialize) response = JSON.parse(body) if response['Response'].key?('Error') == false model = QueryCreditAllocationHistoryResponse.new model.deserialize(response['Response']) model else code = response['Response']['Error']['Code'] = response['Response']['Error']['Message'] reqid = response['Response']['RequestId'] raise TencentCloud::Common::TencentCloudSDKException.new(code, , reqid) end rescue TencentCloud::Common::TencentCloudSDKException => e raise e rescue StandardError => e raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect) end |
#QueryCreditByUinList(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::QueryCreditByUinListResponse`
141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 |
# File 'lib/v20220928/client.rb', line 141 def QueryCreditByUinList(request) body = send_request('QueryCreditByUinList', request.serialize) response = JSON.parse(body) if response['Response'].key?('Error') == false model = QueryCreditByUinListResponse.new model.deserialize(response['Response']) model else code = response['Response']['Error']['Code'] = response['Response']['Error']['Message'] reqid = response['Response']['RequestId'] raise TencentCloud::Common::TencentCloudSDKException.new(code, , reqid) end rescue TencentCloud::Common::TencentCloudSDKException => e raise e rescue StandardError => e raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect) end |
#QueryCustomersCredit(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::QueryCustomersCreditResponse`
165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 |
# File 'lib/v20220928/client.rb', line 165 def QueryCustomersCredit(request) body = send_request('QueryCustomersCredit', request.serialize) response = JSON.parse(body) if response['Response'].key?('Error') == false model = QueryCustomersCreditResponse.new model.deserialize(response['Response']) model else code = response['Response']['Error']['Code'] = response['Response']['Error']['Message'] reqid = response['Response']['RequestId'] raise TencentCloud::Common::TencentCloudSDKException.new(code, , reqid) end rescue TencentCloud::Common::TencentCloudSDKException => e raise e rescue StandardError => e raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect) end |
#QueryDirectCustomersCredit(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::QueryDirectCustomersCreditResponse`
189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 |
# File 'lib/v20220928/client.rb', line 189 def QueryDirectCustomersCredit(request) body = send_request('QueryDirectCustomersCredit', request.serialize) response = JSON.parse(body) if response['Response'].key?('Error') == false model = QueryDirectCustomersCreditResponse.new model.deserialize(response['Response']) model else code = response['Response']['Error']['Code'] = response['Response']['Error']['Message'] reqid = response['Response']['RequestId'] raise TencentCloud::Common::TencentCloudSDKException.new(code, , reqid) end rescue TencentCloud::Common::TencentCloudSDKException => e raise e rescue StandardError => e raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect) end |
#QueryPartnerCredit(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::QueryPartnerCreditResponse`
213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 |
# File 'lib/v20220928/client.rb', line 213 def QueryPartnerCredit(request) body = send_request('QueryPartnerCredit', request.serialize) response = JSON.parse(body) if response['Response'].key?('Error') == false model = QueryPartnerCreditResponse.new model.deserialize(response['Response']) model else code = response['Response']['Error']['Code'] = response['Response']['Error']['Message'] reqid = response['Response']['RequestId'] raise TencentCloud::Common::TencentCloudSDKException.new(code, , reqid) end rescue TencentCloud::Common::TencentCloudSDKException => e raise e rescue StandardError => e raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect) end |
#QueryVoucherAmountByUin(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::QueryVoucherAmountByUinResponse`
237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 |
# File 'lib/v20220928/client.rb', line 237 def QueryVoucherAmountByUin(request) body = send_request('QueryVoucherAmountByUin', request.serialize) response = JSON.parse(body) if response['Response'].key?('Error') == false model = QueryVoucherAmountByUinResponse.new model.deserialize(response['Response']) model else code = response['Response']['Error']['Code'] = response['Response']['Error']['Message'] reqid = response['Response']['RequestId'] raise TencentCloud::Common::TencentCloudSDKException.new(code, , reqid) end rescue TencentCloud::Common::TencentCloudSDKException => e raise e rescue StandardError => e raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect) end |
#QueryVoucherListByUin(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::QueryVoucherListByUinResponse`
261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 |
# File 'lib/v20220928/client.rb', line 261 def QueryVoucherListByUin(request) body = send_request('QueryVoucherListByUin', request.serialize) response = JSON.parse(body) if response['Response'].key?('Error') == false model = QueryVoucherListByUinResponse.new model.deserialize(response['Response']) model else code = response['Response']['Error']['Code'] = response['Response']['Error']['Message'] reqid = response['Response']['RequestId'] raise TencentCloud::Common::TencentCloudSDKException.new(code, , reqid) end rescue TencentCloud::Common::TencentCloudSDKException => e raise e rescue StandardError => e raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect) end |
#QueryVoucherPool(request) ⇒ Object
@rtype: :class:‘Tencentcloud::intlpartnersmgt::V20220928::QueryVoucherPoolResponse`
285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 |
# File 'lib/v20220928/client.rb', line 285 def QueryVoucherPool(request) body = send_request('QueryVoucherPool', request.serialize) response = JSON.parse(body) if response['Response'].key?('Error') == false model = QueryVoucherPoolResponse.new model.deserialize(response['Response']) model else code = response['Response']['Error']['Code'] = response['Response']['Error']['Message'] reqid = response['Response']['RequestId'] raise TencentCloud::Common::TencentCloudSDKException.new(code, , reqid) end rescue TencentCloud::Common::TencentCloudSDKException => e raise e rescue StandardError => e raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect) end |