@be-link/ecommerce-promotion-service-node-sdk 0.0.32 → 0.0.34

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5,6 +5,7 @@ declare class AwardService extends BaseService implements Service.PrizeDistribut
5
5
  distributePrize(request: Service.Request.distributePrize): Promise<Service.Response.distributePrize>;
6
6
  reversePrize(request: Service.Request.reversePrize): Promise<Service.Response.distributePrize>;
7
7
  liveRoomIssueCoupon(request: Service.Request.liveRoomIssueCoupon): Promise<Service.Response.distributePrize>;
8
+ queryLiveRoomDistributionStats(request: Service.Request.queryLiveRoomDistributionStats): Promise<Service.Response.queryLiveRoomDistributionStatsResponse>;
8
9
  }
9
10
  export declare const awardService: AwardService;
10
11
  export default awardService;
@@ -20,26 +20,6 @@ let AwardService = class AwardService extends BaseService_1.default {
20
20
  constructor() {
21
21
  super(...arguments);
22
22
  this.prefixUrl = '/award';
23
- // @OperationId('会员等级积分发放')
24
- // @Post('issue-member-points')
25
- // public issueMemberPoints(
26
- // @Body() request: Service.Request.issueMemberPoints,
27
- // ): Promise<Service.Response.distributePrize> {
28
- // return callApi<Service.PrizeDistributionController['issueMemberPoints']>(
29
- // this.getApiUrl(this.issueMemberPoints),
30
- // request,
31
- // )
32
- // }
33
- // @OperationId('统计直播间发放数据')
34
- // @Post('get-live-room-distribution-stats')
35
- // public getLiveRoomDistributionStats(
36
- // @Body() request: Service.Request.getLiveRoomDistributionStats,
37
- // ): Promise<Service.Response.getLiveRoomDistributionStats> {
38
- // return callApi<Service.PrizeDistributionController['getLiveRoomDistributionStats']>(
39
- // this.getApiUrl(this.getLiveRoomDistributionStats),
40
- // request,
41
- // )
42
- // }
43
23
  }
44
24
  distributePrize(request) {
45
25
  return (0, http_1.callApi)(this.getApiUrl(this.distributePrize), request);
@@ -50,6 +30,9 @@ let AwardService = class AwardService extends BaseService_1.default {
50
30
  liveRoomIssueCoupon(request) {
51
31
  return (0, http_1.callApi)(this.getApiUrl(this.liveRoomIssueCoupon), request);
52
32
  }
33
+ queryLiveRoomDistributionStats(request) {
34
+ return (0, http_1.callApi)(this.getApiUrl(this.queryLiveRoomDistributionStats), request);
35
+ }
53
36
  };
54
37
  __decorate([
55
38
  (0, tsoa_1.OperationId)('发放奖励'),
@@ -66,6 +49,11 @@ __decorate([
66
49
  (0, tsoa_1.Post)('live-room-issue-coupon'),
67
50
  __param(0, (0, tsoa_1.Body)())
68
51
  ], AwardService.prototype, "liveRoomIssueCoupon", null);
52
+ __decorate([
53
+ (0, tsoa_1.OperationId)('直播间积分&券发放统计'),
54
+ (0, tsoa_1.Post)('query-live-room-distribution-stats'),
55
+ __param(0, (0, tsoa_1.Body)())
56
+ ], AwardService.prototype, "queryLiveRoomDistributionStats", null);
69
57
  AwardService = __decorate([
70
58
  (0, tsoa_1.Route)('award'),
71
59
  (0, tsoa_1.Tags)('Award')
@@ -59,14 +59,22 @@ export declare namespace Service {
59
59
  interface liveRoomIssueCoupon {
60
60
  /** 直播间ID */
61
61
  liveRoomId: string;
62
- /** 用户ID */
63
- userId: string;
64
62
  /** 优惠券ID */
65
63
  couponId: string;
66
64
  /** 活动ID(业务ID) */
67
65
  activityId: string;
68
- /** 业务编号:唯一标识 */
69
- bizNo: string;
66
+ /** 时间戳 */
67
+ timestamp: number;
68
+ }
69
+ interface liveRoomIssueCouponEncrypt {
70
+ /** 加密后的数据 */
71
+ encryptData: string;
72
+ /** 加密密钥 */
73
+ encryptKey: string;
74
+ /** 初始化向量 */
75
+ iv: string;
76
+ /** 认证标签 */
77
+ authTag: string;
70
78
  }
71
79
  /** 会员等级积分发放 */
72
80
  interface issueMemberPoints {
@@ -79,14 +87,16 @@ export declare namespace Service {
79
87
  /** 业务编号 */
80
88
  bizNo: string;
81
89
  }
82
- /** 统计直播间发放数据 */
83
- interface getLiveRoomDistributionStats {
90
+ /** 直播间积分&券发放统计 */
91
+ interface queryLiveRoomDistributionStats {
84
92
  /** 直播间ID */
85
93
  liveRoomId: string;
86
- /** 开始时间(时间戳) */
87
- startTime: number;
88
- /** 结束时间(时间戳) */
89
- endTime: number;
94
+ /** 用户列表 */
95
+ userIds?: string[];
96
+ /** 页码 */
97
+ pageIndex?: number;
98
+ /** 每页数量 */
99
+ pageSize?: number;
90
100
  }
91
101
  }
92
102
  namespace Response {
@@ -97,23 +107,21 @@ export declare namespace Service {
97
107
  /** 失败原因 */
98
108
  message?: string;
99
109
  }
100
- /** 分渠道统计数据 */
101
- interface ChannelStats {
102
- /** 渠道 */
103
- channel: ENUM.AWARD_ENUM.DISTRIBUTION_CHANNEL;
104
- /** 数量 */
105
- count: number;
106
- }
107
- /** 统计直播间发放数据响应 */
108
- interface getLiveRoomDistributionStats {
109
- /** 券发放总数量 */
110
- totalCouponCount: number;
111
- /** 积分发放总数量 */
112
- totalPointsCount: number;
113
- /** 券按渠道统计 */
114
- couponByChannel: ChannelStats[];
115
- /** 积分按渠道统计 */
116
- pointsByChannel: ChannelStats[];
110
+ /** 直播间积分&券发放统计响应 */
111
+ interface queryLiveRoomDistributionStatsResponse {
112
+ /** 总数 */
113
+ total: number;
114
+ /** 数据列表 */
115
+ list: {
116
+ /** 用户ID */
117
+ userId: string;
118
+ /** 积分发放数量 */
119
+ points: number;
120
+ /** 券发放数量 */
121
+ coupons: number;
122
+ /** 发放渠道 */
123
+ getChannel: ENUM.AWARD_ENUM.DISTRIBUTION_CHANNEL;
124
+ }[];
117
125
  }
118
126
  }
119
127
  interface PrizeDistributionController {
@@ -123,5 +131,7 @@ export declare namespace Service {
123
131
  reversePrize(request: Service.Request.reversePrize, req: any): Promise<Service.Response.distributePrize>;
124
132
  /** 直播间发券 */
125
133
  liveRoomIssueCoupon(request: Service.Request.liveRoomIssueCoupon, req: any): Promise<Service.Response.distributePrize>;
134
+ /** 直播间积分&券发放统计 */
135
+ queryLiveRoomDistributionStats(request: Service.Request.queryLiveRoomDistributionStats, req: any): Promise<Service.Response.queryLiveRoomDistributionStatsResponse>;
126
136
  }
127
137
  }
@@ -186,6 +186,8 @@ export declare namespace Service {
186
186
  availableCouponStats?: Entity.CouponGroupStats[];
187
187
  /** 用户可用积分数量 */
188
188
  userAvailablePoints?: number;
189
+ /** 使用兑换券券码列表 */
190
+ usedCoupons?: string[];
189
191
  }
190
192
  /** 积分商城用户选择后再次算价响应 */
191
193
  interface recalculatePointsMallOrder {
@@ -201,6 +203,8 @@ export declare namespace Service {
201
203
  requiredCoupons?: number;
202
204
  /** 使用积分数量 */
203
205
  usedPoints?: number;
206
+ /** 用户可用积分数量 */
207
+ userAvailablePoints?: number;
204
208
  /** 用户选择优惠券聚合 */
205
209
  selectedCouponStats?: Entity.CouponGroupStats[];
206
210
  /** 使用兑换券券码列表 */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@be-link/ecommerce-promotion-service-node-sdk",
3
- "version": "0.0.32",
3
+ "version": "0.0.34",
4
4
  "description": "EcommercePromotionService Node.js SDK",
5
5
  "main": "index.js",
6
6
  "types": "index.d.ts",