lingling
2025-04-16 d0558ff1687a1bffd62c45660d4bab3132643039
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
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
using Newtonsoft.Json;
using System.Collections.Generic;
 
namespace LifePayment.Domain.Shared;
 
public interface IACOOLYRequestBaseResponse
{
    /// <summary>
    /// 接口调用状态(true/false)
    /// </summary>
    public bool Success { get; set; }
 
    /// <summary>
    /// 请求号(16-40位)
    /// </summary>
    public string RequestNo { get; set; }
 
    /// <summary>
    /// 商户ID(定长20字符)
    /// </summary>
    public string PartnerId { get; set; }
 
    /// <summary>
    /// 服务名称 
    /// </summary>
    public string Service { get; set; }
 
    /// <summary>
    /// 服务版本(默认1.0)
    /// </summary>
    public string? Version { get; set; }
 
    /// <summary>
    /// 协议类型(HTTP/JSON)
    /// </summary>
    public string? Protocol { get; set; }
 
    /// <summary>
    /// 会话参数(JSON格式)
    /// </summary>
    public string? Context { get; set; }
 
    /// <summary>
    /// 扩展参数(JSON单层结构)
    /// </summary>
    public object Ext { get; set; }
 
    /// <summary>
    /// 响应编码(SUCCESS/PARAM_ERROR等)
    /// </summary>
    public string Code { get; set; }
 
    /// <summary>
    /// 响应消息 
    /// </summary>
    public string Message { get; set; }
 
    /// <summary>
    /// 响应详情 
    /// </summary>
    public string? Detail { get; set; }
}
 
/// <summary>
/// 公共响应参数基类 
/// </summary>
public class ACOOLYRequestBaseResponse : IACOOLYRequestBaseResponse
{
    /// <summary>
    /// 接口调用状态(true/false)
    /// </summary>
    public bool Success { get; set; }
 
    /// <summary>
    /// 请求号(16-40位)
    /// </summary>
    public string RequestNo { get; set; }
 
    /// <summary>
    /// 商户ID(定长20字符)
    /// </summary>
    public string PartnerId { get; set; }
 
    /// <summary>
    /// 服务名称 
    /// </summary>
    public string Service { get; set; }
 
    /// <summary>
    /// 服务版本(默认1.0)
    /// </summary>
    public string? Version { get; set; }
 
    /// <summary>
    /// 协议类型(HTTP/JSON)
    /// </summary>
    public string? Protocol { get; set; }
 
    /// <summary>
    /// 会话参数(JSON格式)
    /// </summary>
    public string? Context { get; set; }
 
    /// <summary>
    /// 扩展参数(JSON单层结构)
    /// </summary>
    public object Ext { get; set; }
 
    /// <summary>
    /// 响应编码(SUCCESS/PARAM_ERROR等)
    /// </summary>
    public string Code { get; set; }
 
    /// <summary>
    /// 响应消息 
    /// </summary>
    public string Message { get; set; }
 
    /// <summary>
    /// 响应详情 
    /// </summary>
    public string? Detail { get; set; }
}
 
/// <summary>
/// 获取燃气面值返回参数
/// </summary>
public class GasParValueResponse : ACOOLYRequestBaseResponse
{
    /// <summary>
    /// 天然气公司类型
    /// </summary>
    [JsonProperty("gasParValue")]
    public List<GasParValueOutput> GasParValue { get; set; }
 
}
public class GasOrgTypeValueResponse : ACOOLYRequestBaseResponse
{
    /// <summary>
    /// 天然气公司类型
    /// </summary>
    [JsonProperty("gasSupportMerchantInfos")]
    public List<GasSupportMerchantInfos> GasSupportMerchantInfos { get; set; }
 
}
 
public class GasSupportMerchantInfos
{
    /// <summary>
    /// 燃气支持商户编码
    /// </summary>
    public string gasOrgTypeCode { get; set; }
 
    /// <summary>
    /// 燃气支持商户名称
    /// </summary>
    public string gasOrgTypeName { get; set; }
}
/// <summary>
/// 燃气面值数据
/// </summary>
public class GasParValueOutput
{
    /// <summary>
    /// 天然气名称(示例:中国燃气天)
    /// </summary>
    [JsonProperty("gasOrgName")]
    public string GasOrgName { get; set; }
 
    /// <summary>
    /// 天然气单位编码(示例:zhong_guo)
    /// </summary>
    [JsonProperty("gasOrgCode")]
    public string GasOrgCode { get; set; }
 
    /// <summary>
    /// 面额数组(示例:100,200,300)
    /// </summary>
    [JsonProperty("parValue")]
    public List<string> ParValue { get; set; }
 
    /// <summary>
    /// 折扣率(示例:0.94)
    /// </summary>
    [JsonProperty("rate")]
    public decimal Rate { get; set; }
 
    /// <summary>
    /// 备注信息(示例:转网用户不能充值)
    /// </summary>
    [JsonProperty("comments")]
    public string Comments { get; set; }
}
 
/// <summary>
/// 提交燃气订单返回参数
/// </summary>
public class ConfirmGasOrderResponse : ACOOLYRequestBaseResponse
{
    [JsonProperty("gasChargeOrder")]
    public GasChargeOrderOutput GasChargeOrder { get; set; }
 
}
 
public class GasChargeOrderOutput
{
    /// <summary>
    /// 商户订单号。
    /// </summary>
    [JsonProperty("outOrderNo")]
    public string OutOrderNo { get; set; }
 
    /// <summary>
    /// 平台订单号。
    /// </summary>
    [JsonProperty("busiOrderNo")]
    public string BusiOrderNo { get; set; }
 
    /// <summary>
    /// 天然气公司类型,例如:"xin_ao"代表新奥燃气。
    /// </summary>
    [JsonProperty("gasOrgType")]
    public string GasOrgType { get; set; }
 
    /// <summary>
    /// 区域名称,如:北京,上海,广东,湖北等。
    /// </summary>
    [JsonProperty("areaName")]
    public string AreaName { get; set; }
 
    /// <summary>
    /// 电费面值金额,单位为元。
    /// </summary>
    [JsonProperty("parValue")]
    public decimal ParValue { get; set; }
 
    /// <summary>
    /// 实际扣款金额,单位为元。
    /// </summary>
    [JsonProperty("payAmount")]
    public decimal PayAmount { get; set; }
 
    /// <summary>
    /// 天然气账号。
    /// </summary>
    [JsonProperty("gasAccount")]
    public string GasAccount { get; set; }
 
    /// <summary>
    /// 充值状态,如:"SUCCESS"表示充值成功。
    /// </summary>
    [JsonProperty("status")]
    public string Status { get; set; }
 
    /// <summary>
    /// 状态描述,如:"充值成功"。
    /// </summary>
    [JsonProperty("statusText")]
    public string StatusText { get; set; }
}
 
/// <summary>
/// 电费面值返回参数
/// </summary>
public class ElectricParValueResponse : ACOOLYRequestBaseResponse
{
    [JsonProperty("electricParValue")]
    public List<ElectricParValueOutput> ElectricParValue { get; set; }
}
 
/// <summary>
/// 电费充值信息类,用于表示电费充值相关的详细信息。
/// </summary>
public class ElectricParValueOutput
{
    /// <summary>
    /// 电网类型,例如:"guowang"代表国家电网,"nanwang"代表南方电网。
    /// </summary>
    [JsonProperty("electricType")]
    public string ElectricType { get; set; }
 
    /// <summary>
    /// 区域名称,如:北京,上海,广东,湖北等。
    /// </summary>
    [JsonProperty("areaName")]
    public string AreaName { get; set; }
 
    /// <summary>
    /// 面额,单位为元。可能的值包括100,200,300等。
    /// </summary>
    [JsonProperty("parValue")]
    public List<string> ParValue { get; set; } // 假设面额为整数
 
    /// <summary>
    /// 折扣率,可选项。折扣率为一个浮点数,例如0.94代表94%。
    /// </summary>
    [JsonProperty("rate")]
    public decimal? Rate { get; set; } // 使用可空类型表示可选字段
 
    /// <summary>
    /// 备注,可选项。例如:"转网用户不能充值"。
    /// </summary>
    [JsonProperty("comments")]
    public string Comments { get; set; } // 备注字段默认可以为空字符串或null,表示可选
}
 
 
public class ElectricSupportAreaResponse : ACOOLYRequestBaseResponse
{
    [JsonProperty("electricSupportAreaList")]
    public List<ElectricSupportAreaListOutput> ElectricAreaList { get; set; }
}
 
public class ElectricSupportAreaListOutput
{
    /// <summary>
    /// 城市自己列表。
    /// </summary>
    [JsonProperty("childCityList")]
    public List<ElectricSupportAreaChildCityListOutput> ChildCityList { get; set; }
 
    /// <summary>
    /// 城市名称。
    /// </summary>
    [JsonProperty("cityName")]
    public string CityName { get; set; }
 
    /// <summary>
    /// 城市父级Id。
    /// </summary>
    [JsonProperty("cityParentId")]
    public string CityParentId { get; set; } // 假设面额为整数
 
    /// <summary>
    /// 城市Id。
    /// </summary>
    [JsonProperty("cityId")]
    public string CityId { get; set; } // 使用可空类型表示可选字段
 
    /// <summary>
    /// 电网类型,例如:"guowang"代表国家电网,"nanwang"代表南方电网。
    /// </summary>
    [JsonProperty("electricType")]
    public string ElectricType { get; set; }
 
    /// <summary>
    /// 面额,单位为元。可能的值包括100,200,300等。
    /// </summary>
    [JsonProperty("parValue")]
    public List<string> ParValue { get; set; } // 假设面额为整数
 
    /// <summary>
    /// 折扣率,可选项。折扣率为一个浮点数,例如0.94代表94%。
    /// </summary>
    [JsonProperty("rate")]
    public decimal? Rate { get; set; } // 使用可空类型表示可选字段
}
 
public class ElectricSupportAreaChildCityListOutput
{
    /// <summary>
    /// 城市名称。
    /// </summary>
    [JsonProperty("cityName")]
    public string CityName { get; set; }
 
    /// <summary>
    /// 城市父级Id。
    /// </summary>
    [JsonProperty("cityParentId")]
    public string CityParentId { get; set; } // 假设面额为整数
 
    /// <summary>
    /// 城市Id。
    /// </summary>
    [JsonProperty("cityId")]
    public string CityId { get; set; } // 使用可空类型表示可选字段
}
 
/// <summary>
/// 话费面值返回参数
/// </summary>
public class PhoneParValueResponse : ACOOLYRequestBaseResponse
{
    [JsonProperty("phoneParValue")]
    public List<PhoneParValueOutput> PhoneParValue { get; set; }
}
 
public class PhoneParValueOutput
{
    /// <summary>
    /// 运营商编码,例如:"yidong", "dianxin", "liantong"。
    /// </summary>
    [JsonProperty("ispCode")]
    public string IspCode { get; set; }
 
    /// <summary>
    /// 运营商名称,如:移动,联通,电信。
    /// </summary>
    [JsonProperty("ispName")]
    public string IspName { get; set; }
 
    /// <summary>
    /// 面额,单位为元。可能的值包括100, 200, 300等。
    /// </summary>
    [JsonProperty("parValue")]
    public List<string> ParValue { get; set; } // 假设面额为整数
 
    /// <summary>
    /// 折扣率,可选项。折扣率为一个浮点数,例如0.94代表94%。
    /// </summary>
    [JsonProperty("rate")]
    public decimal? Rate { get; set; } // 使用可空类型表示可选字段
 
    /// <summary>
    /// 手机号段,例如:移动的134,136等,使用逗号分隔。
    /// </summary>
    [JsonProperty("phoneSection")]
    public string PhoneSection { get; set; }
 
    /// <summary>
    /// 备注,可选项。例如:"转网用户不能充值"。
    /// </summary>
    [JsonProperty("comments")]
    public string Comments { get; set; } // 备注字段默认可以为空字符串或null,表示可选
}
 
/// <summary>
/// 提交电费订单返回参数
/// </summary>
public class ConfirmElectricOrderResponse : ACOOLYRequestBaseResponse
{
    [JsonProperty("electricChargeOrder")]
    public ElectricChargeOrderOutput ElectricChargeOrder { get; set; }
}
public class ElectricChargeOrderOutput
{
    /// <summary>
    /// 商户订单号。
    /// </summary>
    [JsonProperty("outOrderNo")]
    public string OutOrderNo { get; set; }
 
    /// <summary>
    /// 平台订单号。
    /// </summary>
    [JsonProperty("busiOrderNo")]
    public string BusiOrderNo { get; set; }
 
    /// <summary>
    /// 电费户号。
    /// </summary>
    [JsonProperty("electricAccount")]
    public string ElectricAccount { get; set; }
 
    /// <summary>
    /// 区域名称,如:北京,上海,广东,湖北等。
    /// </summary>
    [JsonProperty("areaName")]
    public string AreaName { get; set; }
 
    /// <summary>
    /// 电网类型,例如:"guowang"代表国家电网,"nanwang"代表南方电网。
    /// </summary>
    [JsonProperty("electricType")]
    public string ElectricType { get; set; }
 
    /// <summary>
    /// 电费面值金额,单位为元。
    /// </summary>
    [JsonProperty("parValue")]
    public decimal ParValue { get; set; }
 
 
    /// <summary>
    /// 实际到账金额。
    /// </summary>
    [JsonProperty("actualParValue")]
    public decimal ActualParValue { get; set; }
    /// <summary>
    /// 实际扣款金额,单位为元。
    /// </summary>
    [JsonProperty("payAmount")]
    public decimal PayAmount { get; set; }
 
    /// <summary>
    /// 充值状态,如:"SUCCESS"表示充值成功。
    /// </summary>
    [JsonProperty("status")]
    public string Status { get; set; }
 
    /// <summary>
    /// 状态描述,如:"充值成功"。
    /// </summary>
    [JsonProperty("statusText")]
    public string StatusText { get; set; }
 
    /// <summary>
    /// 通知消息
    /// </summary>
    [JsonProperty("responseMessage")]
    public string ResponseMessage {  get; set; }
 
}
 
/// <summary>
/// 提交电话费订单返回参数
/// </summary>
public class ConfirmPhoneOrderResponse : ACOOLYRequestBaseResponse
{
    [JsonProperty("phoneChargeOrder")]
    public PhoneChargeOrderOutput PhoneChargeOrder { get; set; }
}
 
public class PhoneChargeOrderOutput
{
    /// <summary>
    /// 外部商户订单号。
    /// </summary>
    [JsonProperty("outOrderNo")]
    public string OutOrderNo { get; set; }
 
    /// <summary>
    /// 平台订单号。
    /// </summary>
    [JsonProperty("busiOrderNo")]
    public string BusiOrderNo { get; set; }
 
    /// <summary>
    /// 面值金额,单位为元。
    /// </summary>
    [JsonProperty("parValue")]
    public decimal ParValue { get; set; }
 
    /// <summary>
    /// 实际扣款金额,单位为元。
    /// </summary>
    [JsonProperty("payAmount")]
    public decimal PayAmount { get; set; }
 
    /// <summary>
    /// 充值状态,如:"SUCCESS"表示充值成功。
    /// </summary>
    [JsonProperty("status")]
    public string Status { get; set; }
 
    /// <summary>
    /// 状态描述,如:"充值成功"。
    /// </summary>
    [JsonProperty("statusText")]
    public string StatusText { get; set; }
}