/
IntlpartnersmgtClient.java
298 lines (270 loc) · 14.1 KB
/
IntlpartnersmgtClient.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
/*
* Copyright (c) 2017-2018 THL A29 Limited, a Tencent company. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.tencentcloudapi.intlpartnersmgt.v20220928;
import java.lang.reflect.Type;
import com.google.gson.JsonSyntaxException;
import com.google.gson.reflect.TypeToken;
import com.tencentcloudapi.common.exception.TencentCloudSDKException;
import com.tencentcloudapi.common.AbstractClient;
import com.tencentcloudapi.common.profile.ClientProfile;
import com.tencentcloudapi.common.JsonResponseModel;
import com.tencentcloudapi.common.Credential;
import com.tencentcloudapi.intlpartnersmgt.v20220928.models.*;
public class IntlpartnersmgtClient extends AbstractClient{
private static String endpoint = "intlpartnersmgt.tencentcloudapi.com";
private static String service = "intlpartnersmgt";
private static String version = "2022-09-28";
public IntlpartnersmgtClient(Credential credential, String region) {
this(credential, region, new ClientProfile());
}
public IntlpartnersmgtClient(Credential credential, String region, ClientProfile profile) {
super(IntlpartnersmgtClient.endpoint, IntlpartnersmgtClient.version, credential, region, profile);
}
/**
*This API is used for a partner to set credit for a customer, such as increasing or lowering the credit and setting it to 0.
1. The credit is valid permanently and will not be zeroed regularly.
2. The customer's service will be suspended when its available credit is set to 0, so caution should be exercised with this operation.
3. To prevent the customer from making new purchases without affecting their use of previously purchased products, the partner can set their available credit to 0 after obtaining the non-stop feature privilege from the channel manager.
4. The set credit is an increment of the current available credit and cannot exceed the remaining allocable credit. Setting the credit to a negative value indicates that it will be repossessed. The available credit can be set to 0 at the minimum.
* @param req AllocateCustomerCreditRequest
* @return AllocateCustomerCreditResponse
* @throws TencentCloudSDKException
*/
public AllocateCustomerCreditResponse AllocateCustomerCredit(AllocateCustomerCreditRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "AllocateCustomerCredit", AllocateCustomerCreditResponse.class);
}
/**
*This API is used to create Tencent Cloud customer accounts for first-level resellers/second-level resellers. After the account is created, it will be automatically bound to the partner account.Note:1. Create a Tencent Cloud account. The entered email address and mobile phone number need to be verified by the partner for validity.2. Customers need to add personal information when logging in for the first time.3. This interface needs to be applied for allowlist usage. Please contact the channel manager to initiate the application process.
* @param req CreateAccountRequest
* @return CreateAccountResponse
* @throws TencentCloudSDKException
*/
public CreateAccountResponse CreateAccount(CreateAccountRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "CreateAccount", CreateAccountResponse.class);
}
/**
*This API is used to query the customer bill details.
* @param req DescribeBillDetailRequest
* @return DescribeBillDetailResponse
* @throws TencentCloudSDKException
*/
public DescribeBillDetailResponse DescribeBillDetail(DescribeBillDetailRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "DescribeBillDetail", DescribeBillDetailResponse.class);
}
/**
*This API is used to download billing files and return billing file URLs by customers.
* @param req DescribeBillDownloadUrlRequest
* @return DescribeBillDownloadUrlResponse
* @throws TencentCloudSDKException
*/
public DescribeBillDownloadUrlResponse DescribeBillDownloadUrl(DescribeBillDownloadUrlRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "DescribeBillDownloadUrl", DescribeBillDownloadUrlResponse.class);
}
/**
*External API for the L1 billing of the customer billing center
* @param req DescribeBillSummaryRequest
* @return DescribeBillSummaryResponse
* @throws TencentCloudSDKException
*/
public DescribeBillSummaryResponse DescribeBillSummary(DescribeBillSummaryRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "DescribeBillSummary", DescribeBillSummaryResponse.class);
}
/**
*This API is used to obtain the total amount of customer bills by payment mode.
* @param req DescribeBillSummaryByPayModeRequest
* @return DescribeBillSummaryByPayModeResponse
* @throws TencentCloudSDKException
*/
public DescribeBillSummaryByPayModeResponse DescribeBillSummaryByPayMode(DescribeBillSummaryByPayModeRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "DescribeBillSummaryByPayMode", DescribeBillSummaryByPayModeResponse.class);
}
/**
*This API is used to obtain the total amount of customer bills by product.
* @param req DescribeBillSummaryByProductRequest
* @return DescribeBillSummaryByProductResponse
* @throws TencentCloudSDKException
*/
public DescribeBillSummaryByProductResponse DescribeBillSummaryByProduct(DescribeBillSummaryByProductRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "DescribeBillSummaryByProduct", DescribeBillSummaryByProductResponse.class);
}
/**
*This API is used to obtain the total amount of customer bills by region.
* @param req DescribeBillSummaryByRegionRequest
* @return DescribeBillSummaryByRegionResponse
* @throws TencentCloudSDKException
*/
public DescribeBillSummaryByRegionResponse DescribeBillSummaryByRegion(DescribeBillSummaryByRegionRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "DescribeBillSummaryByRegion", DescribeBillSummaryByRegionResponse.class);
}
/**
*This API is used to query the customer bill details.
* @param req DescribeCustomerBillDetailRequest
* @return DescribeCustomerBillDetailResponse
* @throws TencentCloudSDKException
*/
public DescribeCustomerBillDetailResponse DescribeCustomerBillDetail(DescribeCustomerBillDetailRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "DescribeCustomerBillDetail", DescribeCustomerBillDetailResponse.class);
}
/**
*This API is used to query the total amount of customer bills.
* @param req DescribeCustomerBillSummaryRequest
* @return DescribeCustomerBillSummaryResponse
* @throws TencentCloudSDKException
*/
public DescribeCustomerBillSummaryResponse DescribeCustomerBillSummary(DescribeCustomerBillSummaryRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "DescribeCustomerBillSummary", DescribeCustomerBillSummaryResponse.class);
}
/**
*This API is used to query the customer information.
* @param req DescribeCustomerInfoRequest
* @return DescribeCustomerInfoResponse
* @throws TencentCloudSDKException
*/
public DescribeCustomerInfoResponse DescribeCustomerInfo(DescribeCustomerInfoRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "DescribeCustomerInfo", DescribeCustomerInfoResponse.class);
}
/**
*This API is used to query the list of customer UINs.
* @param req DescribeCustomerUinRequest
* @return DescribeCustomerUinResponse
* @throws TencentCloudSDKException
*/
public DescribeCustomerUinResponse DescribeCustomerUin(DescribeCustomerUinRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "DescribeCustomerUin", DescribeCustomerUinResponse.class);
}
/**
*This API is used to obtain country/region codes.
* @param req GetCountryCodesRequest
* @return GetCountryCodesResponse
* @throws TencentCloudSDKException
*/
public GetCountryCodesResponse GetCountryCodes(GetCountryCodesRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "GetCountryCodes", GetCountryCodesResponse.class);
}
/**
*This API is used to query the account verification status.
* @param req QueryAccountVerificationStatusRequest
* @return QueryAccountVerificationStatusResponse
* @throws TencentCloudSDKException
*/
public QueryAccountVerificationStatusResponse QueryAccountVerificationStatus(QueryAccountVerificationStatusRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "QueryAccountVerificationStatus", QueryAccountVerificationStatusResponse.class);
}
/**
*This API is used to query all the credit allocation records of a single customer.
* @param req QueryCreditAllocationHistoryRequest
* @return QueryCreditAllocationHistoryResponse
* @throws TencentCloudSDKException
*/
public QueryCreditAllocationHistoryResponse QueryCreditAllocationHistory(QueryCreditAllocationHistoryRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "QueryCreditAllocationHistory", QueryCreditAllocationHistoryResponse.class);
}
/**
*This API is used to query the credit of users in the list.
* @param req QueryCreditByUinListRequest
* @return QueryCreditByUinListResponse
* @throws TencentCloudSDKException
*/
public QueryCreditByUinListResponse QueryCreditByUinList(QueryCreditByUinListRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "QueryCreditByUinList", QueryCreditByUinListResponse.class);
}
/**
*This API is used to query customer credits.
* @param req QueryCreditQuotaRequest
* @return QueryCreditQuotaResponse
* @throws TencentCloudSDKException
*/
public QueryCreditQuotaResponse QueryCreditQuota(QueryCreditQuotaRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "QueryCreditQuota", QueryCreditQuotaResponse.class);
}
/**
*This API is used for a partner to the credits and basic information of cutomers.
* @param req QueryCustomersCreditRequest
* @return QueryCustomersCreditResponse
* @throws TencentCloudSDKException
*/
public QueryCustomersCreditResponse QueryCustomersCredit(QueryCustomersCreditRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "QueryCustomersCredit", QueryCustomersCreditResponse.class);
}
/**
*This API is used to query the credits of direct customers.
* @param req QueryDirectCustomersCreditRequest
* @return QueryDirectCustomersCreditResponse
* @throws TencentCloudSDKException
*/
public QueryDirectCustomersCreditResponse QueryDirectCustomersCredit(QueryDirectCustomersCreditRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "QueryDirectCustomersCredit", QueryDirectCustomersCreditResponse.class);
}
/**
*This API is used for a partner to query its own total credit, available credit, and used credit in USD.
* @param req QueryPartnerCreditRequest
* @return QueryPartnerCreditResponse
* @throws TencentCloudSDKException
*/
public QueryPartnerCreditResponse QueryPartnerCredit(QueryPartnerCreditRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "QueryPartnerCredit", QueryPartnerCreditResponse.class);
}
/**
*This API is used to query the voucher quota based on the customer UIN.
* @param req QueryVoucherAmountByUinRequest
* @return QueryVoucherAmountByUinResponse
* @throws TencentCloudSDKException
*/
public QueryVoucherAmountByUinResponse QueryVoucherAmountByUin(QueryVoucherAmountByUinRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "QueryVoucherAmountByUin", QueryVoucherAmountByUinResponse.class);
}
/**
*This API is used to query the voucher list based on the customer UIN.
* @param req QueryVoucherListByUinRequest
* @return QueryVoucherListByUinResponse
* @throws TencentCloudSDKException
*/
public QueryVoucherListByUinResponse QueryVoucherListByUin(QueryVoucherListByUinRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "QueryVoucherListByUin", QueryVoucherListByUinResponse.class);
}
/**
*This API is used to query the voucher quota pool.
* @param req QueryVoucherPoolRequest
* @return QueryVoucherPoolResponse
* @throws TencentCloudSDKException
*/
public QueryVoucherPoolResponse QueryVoucherPool(QueryVoucherPoolRequest req) throws TencentCloudSDKException{
req.setSkipSign(false);
return this.internalRequest(req, "QueryVoucherPool", QueryVoucherPoolResponse.class);
}
}