@yunzhanghu/sdk-nodejs 1.0.26 → 1.0.27

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.
@@ -177,6 +177,33 @@ authentication
177
177
  console.log(err.toString())
178
178
  })
179
179
 
180
+ // 非居民身份证验证名单审核结果查询
181
+ authentication
182
+ .GetUserWhiteApproveInfo({
183
+
184
+ /**
185
+ * @param {string} request-id:请求 ID,请求的唯一标识
186
+ * 建议平台企业自定义 request-id,并记录在日志中,便于问题发现及排查
187
+ * 如未自定义 request-id,将使用 SDK 中的 UUID 方法自动生成。注意:UUID 方法生成的 request-id 不能保证全局唯一,推荐自定义 request-id
188
+ */
189
+ real_name: '张三',
190
+ id_card: 'EA3456789',
191
+ card_type: 'passport',
192
+ })
193
+ .then((data) => {
194
+ if (data.code === '0000') {
195
+ // 操作成功
196
+ console.log('操作成功 ', data.data)
197
+ } else {
198
+ // 失败返回
199
+ console.log('失败返回 ', 'code:' + data.code + ' message:' + data.message + ' request_id:' + data.request_id)
200
+ }
201
+ })
202
+ .catch((err) => {
203
+ // 发生异常
204
+ console.log(err.toString())
205
+ })
206
+
180
207
  // 添加本地图片路径
181
208
  var file = '/Library/WebServer/Documents/test.png'
182
209
 
@@ -55,6 +55,7 @@ caculatorLabor
55
55
  id_card: "11010519491231002X",
56
56
  pay: "99",
57
57
  tax_type: "before_tax",
58
+ before_tax_amount_type: "max",
58
59
  })
59
60
  .then((data) => {
60
61
  if (data.code === '0000') {
@@ -7,7 +7,7 @@ const h5usersign = new yzhAPI.H5UserSignServiceClient(config)
7
7
  // 预申请签约
8
8
  h5usersign
9
9
  .H5UserPresign({
10
-
10
+
11
11
  /**
12
12
  * @param {string} request-id:请求 ID,请求的唯一标识
13
13
  * 建议平台企业自定义 request-id,并记录在日志中,便于问题发现及排查
@@ -20,6 +20,7 @@ h5usersign
20
20
  id_card: '11010519491231002X',
21
21
  certificate_type: 0,
22
22
  collect_phone_no: 0,
23
+ page_open_way: 1,
23
24
  })
24
25
  .then((data) => {
25
26
  if (data.code === '0000') {
@@ -28,7 +29,7 @@ h5usersign
28
29
  } else {
29
30
  // 失败返回
30
31
  console.log('失败返回 ', 'code:' + data.code + ' message:' + data.message + ' request_id:' + data.request_id)
31
- }
32
+ }
32
33
  })
33
34
  .catch((err) => {
34
35
  // 发生异常
@@ -38,7 +39,7 @@ h5usersign
38
39
  // 申请签约
39
40
  h5usersign
40
41
  .H5UserSign({
41
-
42
+
42
43
  /**
43
44
  * @param {string} request-id:请求 ID,请求的唯一标识
44
45
  * 建议平台企业自定义 request-id,并记录在日志中,便于问题发现及排查
@@ -57,7 +58,7 @@ h5usersign
57
58
  } else {
58
59
  // 失败返回
59
60
  console.log('失败返回 ', 'code:' + data.code + ' message:' + data.message + ' request_id:' + data.request_id)
60
- }
61
+ }
61
62
  })
62
63
  .catch((err) => {
63
64
  // 发生异常
@@ -67,7 +68,7 @@ h5usersign
67
68
  // 获取用户签约状态
68
69
  h5usersign
69
70
  .GetH5UserSignStatus({
70
-
71
+
71
72
  /**
72
73
  * @param {string} request-id:请求 ID,请求的唯一标识
73
74
  * 建议平台企业自定义 request-id,并记录在日志中,便于问题发现及排查
@@ -86,7 +87,7 @@ h5usersign
86
87
  } else {
87
88
  // 失败返回
88
89
  console.log('失败返回 ', 'code:' + data.code + ' message:' + data.message + ' request_id:' + data.request_id)
89
- }
90
+ }
90
91
  })
91
92
  .catch((err) => {
92
93
  // 发生异常
@@ -96,7 +97,7 @@ h5usersign
96
97
  // 用户解约(测试账号专用接口)
97
98
  h5usersign
98
99
  .H5UserRelease({
99
-
100
+
100
101
  /**
101
102
  * @param {string} request-id:请求 ID,请求的唯一标识
102
103
  * 建议平台企业自定义 request-id,并记录在日志中,便于问题发现及排查
@@ -116,7 +117,7 @@ h5usersign
116
117
  } else {
117
118
  // 失败返回
118
119
  console.log('失败返回 ', 'code:' + data.code + ' message:' + data.message + ' request_id:' + data.request_id)
119
- }
120
+ }
120
121
  })
121
122
  .catch((err) => {
122
123
  // 发生异常
@@ -466,3 +466,5 @@ payment
466
466
  // 发生异常
467
467
  console.log(err.toString())
468
468
  })
469
+
470
+
@@ -0,0 +1,88 @@
1
+ const yzhAPI = require('../yzh/index.js')
2
+ const config = require('./conf/config.js')
3
+
4
+ // 连续劳务税费退补
5
+ const taxClearRefundClient = new yzhAPI.TaxClearRefundClient(config)
6
+
7
+ // 查询税费清缴完成结果
8
+ taxClearRefundClient
9
+ .GetClearTaxInfo({
10
+
11
+ /**
12
+ * @param {string} request-id:请求 ID,请求的唯一标识
13
+ * 建议平台企业自定义 request-id,并记录在日志中,便于问题发现及排查
14
+ * 如未自定义 request-id,将使用 SDK 中的 UUID 方法自动生成。注意:UUID 方法生成的 request-id 不能保证全局唯一,推荐自定义 request-id
15
+ */
16
+ broker_id: config.broker_id,
17
+ dealer_id: config.dealer_id,
18
+ tax_month: '2025-10',
19
+ })
20
+ .then((data) => {
21
+ if (data.code === '0000') {
22
+ // 操作成功
23
+ console.log('操作成功 ', data.data)
24
+ } else {
25
+ // 失败返回
26
+ console.log('失败返回 ', 'code:' + data.code + ' message:' + data.message + ' request_id:' + data.request_id)
27
+ }
28
+ })
29
+ .catch((err) => {
30
+ // 发生异常
31
+ console.log(err.toString())
32
+ })
33
+
34
+ // 查询税费清缴明细文件
35
+ taxClearRefundClient
36
+ .GetClearTaxFile({
37
+
38
+ /**
39
+ * @param {string} request-id:请求 ID,请求的唯一标识
40
+ * 建议平台企业自定义 request-id,并记录在日志中,便于问题发现及排查
41
+ * 如未自定义 request-id,将使用 SDK 中的 UUID 方法自动生成。注意:UUID 方法生成的 request-id 不能保证全局唯一,推荐自定义 request-id
42
+ */
43
+ broker_id: config.broker_id,
44
+ dealer_id: config.dealer_id,
45
+ tax_month: '2025-10',
46
+ batch_id: '10313232135454132',
47
+ })
48
+ .then((data) => {
49
+ if (data.code === '0000') {
50
+ // 操作成功
51
+ console.log('操作成功 ', data.data)
52
+ } else {
53
+ // 失败返回
54
+ console.log('失败返回 ', 'code:' + data.code + ' message:' + data.message + ' request_id:' + data.request_id)
55
+ }
56
+ })
57
+ .catch((err) => {
58
+ // 发生异常
59
+ console.log(err.toString())
60
+ })
61
+
62
+ // 查询税费退补完成结果
63
+ taxClearRefundClient
64
+ .GetRefundTaxInfo({
65
+
66
+ /**
67
+ * @param {string} request-id:请求 ID,请求的唯一标识
68
+ * 建议平台企业自定义 request-id,并记录在日志中,便于问题发现及排查
69
+ * 如未自定义 request-id,将使用 SDK 中的 UUID 方法自动生成。注意:UUID 方法生成的 request-id 不能保证全局唯一,推荐自定义 request-id
70
+ */
71
+ broker_id: config.broker_id,
72
+ dealer_id: config.dealer_id,
73
+ tax_month: '2025-10',
74
+ batch_id: '10313232135454132',
75
+ })
76
+ .then((data) => {
77
+ if (data.code === '0000') {
78
+ // 操作成功
79
+ console.log('操作成功 ', data.data)
80
+ } else {
81
+ // 失败返回
82
+ console.log('失败返回 ', 'code:' + data.code + ' message:' + data.message + ' request_id:' + data.request_id)
83
+ }
84
+ })
85
+ .catch((err) => {
86
+ // 发生异常
87
+ console.log(err.toString())
88
+ })
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yunzhanghu/sdk-nodejs",
3
- "version": "1.0.26",
3
+ "version": "1.0.27",
4
4
  "description": "云账户 SDK for Node.js",
5
5
  "main": "yzh/index.js",
6
6
  "scripts": {
@@ -147,6 +147,24 @@ interface GetBankCardInfoResponse {
147
147
  is_support: boolean;
148
148
  }
149
149
 
150
+ /** GetUserWhiteApproveInfoRequest 非居民身份证验证名单审核结果查询请求 */
151
+ interface GetUserWhiteApproveInfoRequest {
152
+ /** 姓名 */
153
+ real_name: string;
154
+ /** 证件号码 */
155
+ id_card: string;
156
+ /** 证件类型编码 */
157
+ card_type: string;
158
+ }
159
+
160
+ /** GetUserWhiteApproveInfoResponse */
161
+ interface GetUserWhiteApproveInfoResponse {
162
+ /** 审核状态 pass:通过 reviewing:审核中 reject:拒绝 */
163
+ status: string;
164
+ /** 审核信息 */
165
+ comment: string;
166
+ }
167
+
150
168
  export class AuthenticationClient extends YZHclient {
151
169
  // eslint-disable-next-line no-useless-constructor
152
170
  constructor(conf: {
@@ -226,4 +244,12 @@ export class AuthenticationClient extends YZHclient {
226
244
  ): Promise<GetBankCardInfoResponse> {
227
245
  return this.request('get', '/api/payment/v1/card', req, { encryption: false }, cb);
228
246
  }
247
+
248
+ // GetUserWhiteApproveInfo 非居民身份证验证名单审核结果查询
249
+ async GetUserWhiteApproveInfo(
250
+ req: GetUserWhiteApproveInfoRequest,
251
+ cb?: (error: null | string, rep: GetUserWhiteApproveInfoResponse) => void
252
+ ): Promise<GetUserWhiteApproveInfoResponse> {
253
+ return this.request('get', '/api/payment/v1/user/white/approve', req, { encryption: false }, cb);
254
+ }
229
255
  }
@@ -80,6 +80,8 @@ interface CalcTaxRequest {
80
80
  pay: string;
81
81
  /** 测算类型 */
82
82
  tax_type: string;
83
+ /** 税前订单金额返回值类型 */
84
+ before_tax_amount_type: string;
83
85
  }
84
86
 
85
87
  /** CalcTaxResponse 订单税费试算返回 */
@@ -14,6 +14,8 @@ interface H5UserPresignRequest {
14
14
  certificate_type: number;
15
15
  /** 是否收集手机号码 0:不收集(默认) 1:收集手机号码 */
16
16
  collect_phone_no: number;
17
+ /** 签约页面打开方式 1:微信小程序打开签约页面 */
18
+ page_open_way: number;
17
19
  }
18
20
 
19
21
  /** H5UserPresignResponse 预申请签约返回 */
@@ -14,3 +14,4 @@ export { PaymentClient } from './payment';
14
14
  export { TaxClient } from './tax';
15
15
  export { UploadUserSignServiceClient } from './uploadusersign';
16
16
  export { UserCollectServiceClient } from './usercollect';
17
+ export { TaxClearRefundClient } from './taxclearrefund';
@@ -0,0 +1,193 @@
1
+ import YZHclient from '../../common/client';
2
+
3
+
4
+ /** ClearTaxData 连续劳务税费清缴完成数据 */
5
+ interface ClearTaxData {
6
+ /** 报税属期 */
7
+ tax_month: string;
8
+ /** 综合服务主体 ID */
9
+ broker_id: string;
10
+ /** 平台企业 ID */
11
+ dealer_id: string;
12
+ /** 清缴次数 */
13
+ tax_clear_num: string;
14
+ /** 退补税用户数量 */
15
+ refund_tax_labor_num: string;
16
+ /** 退补税订单数量 */
17
+ refund_tax_order_num: string;
18
+ /** 订单总金额 */
19
+ total_amount: string;
20
+ /** 本批次退补税费总额 */
21
+ cur_total_refund_tax: string;
22
+ /** 退补税费总额 */
23
+ total_refund_tax: string;
24
+ /** 历史已退补税费总额 */
25
+ history_refund_tax: string;
26
+ /** 本批次预扣税费总额 */
27
+ total_tax: string;
28
+ /** 本批次实缴税费总额 */
29
+ receive_total_tax: string;
30
+ /** 本批次退补给用户税费总额 */
31
+ cur_total_refund_labor_tax: string;
32
+ /** 本批次退补给平台企业税费总额 */
33
+ cur_total_refund_dealer_tax: string;
34
+ /** 本批次退补给云账户税费总额 */
35
+ cur_total_refund_broker_tax: string;
36
+ /** 批次号 */
37
+ batch_id: string;
38
+ /** 批次生成时间 */
39
+ batch_create_time: string;
40
+ }
41
+
42
+ /** GetClearTaxInfoRequest 查询税费清缴完成结果请求 */
43
+ interface GetClearTaxInfoRequest {
44
+ /** 综合服务主体 ID */
45
+ broker_id: string;
46
+ /** 平台企业 ID */
47
+ dealer_id: string;
48
+ /** 报税属期 */
49
+ tax_month: string;
50
+ }
51
+
52
+ /** GetClearTaxInfoResponse 查询税费清缴完成结果返回 */
53
+ interface GetClearTaxInfoResponse {
54
+ /** 清缴批次列表 */
55
+ batch_list: ClearTaxData[];
56
+ }
57
+
58
+ /** GetClearTaxFileRequest 查询税费清缴明细文件请求 */
59
+ interface GetClearTaxFileRequest {
60
+ /** 综合服务主体 ID */
61
+ broker_id: string;
62
+ /** 平台企业 ID */
63
+ dealer_id: string;
64
+ /** 报税属期 */
65
+ tax_month: string;
66
+ /** 批次号 */
67
+ batch_id: string;
68
+ }
69
+
70
+ /** GetClearTaxFileResponse 查询税费清缴明细文件返回 */
71
+ interface GetClearTaxFileResponse {
72
+ /** 下载地址 */
73
+ url: string;
74
+ }
75
+
76
+
77
+ /** RefundTaxData 连续劳务税费退补完成数据 */
78
+ interface RefundTaxData {
79
+ /** 综合服务主体 ID */
80
+ broker_id: string;
81
+ /** 平台企业 ID */
82
+ dealer_id: string;
83
+ /** 清缴次数 */
84
+ tax_clear_num: string;
85
+ /** 报税属期 */
86
+ tax_month: string;
87
+ /** 退补税用户数量 */
88
+ refund_tax_labor_num: string;
89
+ /** 退补税订单数量 */
90
+ refund_tax_order_num: string;
91
+ /** 订单总金额 */
92
+ total_amount: string;
93
+ /** 本批次退补税费总额 */
94
+ cur_total_refund_tax: string;
95
+ /** 退补税费总额 */
96
+ total_refund_tax: string;
97
+ /** 历史已退补税费总额 */
98
+ history_refund_tax: string;
99
+ /** 本批次预扣税费总额 */
100
+ total_tax: string;
101
+ /** 本批次实缴税费总额 */
102
+ receive_total_tax: string;
103
+ /** 本批次退补给用户税费总额 */
104
+ cur_total_refund_labor_tax: string;
105
+ /** 本批次退补给平台企业税费总额 */
106
+ cur_total_refund_dealer_tax: string;
107
+ /** 本批次退补给云账户税费总额 */
108
+ cur_total_refund_broker_tax: string;
109
+ /** 批次号 */
110
+ batch_id: string;
111
+ /** 批次退补税状态 */
112
+ batch_refund_tax_status: string;
113
+ /** 批次生成时间 */
114
+ batch_create_time: string;
115
+ /** 批次退补税成功时间 */
116
+ batch_refund_tax_finished_time: string;
117
+ /** 已完成税费退补的用户数量 */
118
+ refund_tax_finished_labor_num: string;
119
+ /** 已完成的税费退补总额 */
120
+ refund_tax_finished_amount: string;
121
+ }
122
+
123
+ /** GetRefundTaxInfoRequest 查询税费退补完成结果请求 */
124
+ interface GetRefundTaxInfoRequest {
125
+ /** 综合服务主体 ID */
126
+ broker_id: string;
127
+ /** 平台企业 ID */
128
+ dealer_id: string;
129
+ /** 报税属期 */
130
+ tax_month: string;
131
+ /** 批次号 */
132
+ batch_id: string;
133
+ }
134
+
135
+ export class TaxClearRefundClient extends YZHclient {
136
+ // eslint-disable-next-line no-useless-constructor
137
+ constructor(conf: {
138
+ dealer_id: string;
139
+ broker_id: string;
140
+ app_key: string;
141
+ des3_key: string;
142
+ private_key: string;
143
+ yzh_public_key: string;
144
+ sign_type: 'rsa' | 'sha256';
145
+ base_url?: string;
146
+ timeout?: number;
147
+ }) {
148
+ super(conf);
149
+ }
150
+
151
+ // GetClearTaxInfo 查询税费清缴完成结果
152
+ async GetClearTaxInfo(
153
+ req: GetClearTaxInfoRequest,
154
+ cb?: (error: null | string,rep: GetClearTaxInfoResponse)=>void
155
+ ): Promise<GetClearTaxInfoResponse> {
156
+ return this.request(
157
+ 'get',
158
+ '/api/payment/v1/query-clear-tax',
159
+ req,
160
+ {encryption: false },
161
+ cb
162
+ );
163
+ }
164
+
165
+ // GetClearTaxFile 查询税费清缴明细文件
166
+ async GetClearTaxFile(
167
+ req: GetClearTaxFileRequest,
168
+ cb?: (error: null | string,rep: GetClearTaxFileResponse)=>void
169
+ ): Promise<GetClearTaxFileResponse> {
170
+ return this.request(
171
+ 'get',
172
+ '/api/payment/v1/query-clear-tax/file',
173
+ req,
174
+ {encryption: false },
175
+ cb
176
+ );
177
+ }
178
+
179
+ // GetRefundTaxInfo 查询税费退补完成结果
180
+ async GetRefundTaxInfo(
181
+ req: GetRefundTaxInfoRequest,
182
+ cb?: (error: null | string,rep: RefundTaxData)=>void
183
+ ): Promise<RefundTaxData> {
184
+ return this.request(
185
+ 'get',
186
+ '/api/payment/v1/query-clear-status',
187
+ req,
188
+ {encryption: false },
189
+ cb
190
+ );
191
+ }
192
+
193
+ }
@@ -146,6 +146,24 @@ interface GetBankCardInfoResponse {
146
146
  is_support: boolean;
147
147
  }
148
148
 
149
+ /** GetUserWhiteApproveInfoRequest 非居民身份证验证名单审核结果查询请求 */
150
+ interface GetUserWhiteApproveInfoRequest {
151
+ /** 姓名 */
152
+ real_name: string;
153
+ /** 证件号码 */
154
+ id_card: string;
155
+ /** 证件类型编码 */
156
+ card_type: string;
157
+ }
158
+
159
+ /** GetUserWhiteApproveInfoResponse */
160
+ interface GetUserWhiteApproveInfoResponse {
161
+ /** 审核状态 pass:通过 reviewing:审核中 reject:拒绝 */
162
+ status: string;
163
+ /** 审核信息 */
164
+ comment: string;
165
+ }
166
+
149
167
  export declare class AuthenticationClient extends YZHclient {
150
168
  constructor(conf: {
151
169
  dealer_id: string;
@@ -190,6 +208,10 @@ export declare class AuthenticationClient extends YZHclient {
190
208
  req: GetBankCardInfoRequest,
191
209
  cb?: (error: null | string, rep: GetBankCardInfoResponse) => void
192
210
  ): Promise<GetBankCardInfoResponse>;
211
+ GetUserWhiteApproveInfo(
212
+ req: GetUserWhiteApproveInfoRequest,
213
+ cb?: (error: null | string, rep: GetUserWhiteApproveInfoResponse) => void
214
+ ): Promise<GetUserWhiteApproveInfoResponse>;
193
215
  }
194
216
 
195
217
  export {};
@@ -39,5 +39,9 @@ class AuthenticationClient extends client_1.default {
39
39
  async GetBankCardInfo(req, cb) {
40
40
  return this.request('get', '/api/payment/v1/card', req, { encryption: false }, cb);
41
41
  }
42
+ // GetUserWhiteApproveInfo 非居民身份证验证名单审核结果查询
43
+ async GetUserWhiteApproveInfo(req, cb) {
44
+ return this.request('get', '/api/payment/v1/user/white/approve', req, { encryption: false }, cb);
45
+ }
42
46
  }
43
47
  exports.AuthenticationClient = AuthenticationClient;
@@ -80,6 +80,8 @@ interface CalcTaxRequest {
80
80
  pay: string;
81
81
  /** 测算类型 */
82
82
  tax_type: string;
83
+ /** 税前订单金额返回值类型 */
84
+ before_tax_amount_type: string;
83
85
  }
84
86
 
85
87
  /** CalcTaxResponse 订单税费试算返回 */
@@ -13,6 +13,8 @@ interface H5UserPresignRequest {
13
13
  certificate_type: number;
14
14
  /** 是否收集手机号码 0:不收集(默认) 1:收集手机号码 */
15
15
  collect_phone_no: number;
16
+ /** 签约页面打开方式 1:微信小程序打开签约页面 */
17
+ page_open_way: number;
16
18
  }
17
19
 
18
20
  /** H5UserPresignResponse 预申请签约返回 */
@@ -14,4 +14,5 @@ export { PaymentClient } from './payment';
14
14
  export { TaxClient } from './tax';
15
15
  export { UploadUserSignServiceClient } from './uploadusersign';
16
16
  export { UserCollectServiceClient } from './usercollect';
17
- export { RealNameServiceClient } from './realname';
17
+ export { RealNameServiceClient } from './realname';
18
+ export { TaxClearRefundClient } from './taxclearrefund';
@@ -35,4 +35,6 @@ var usercollect_1 = require("./usercollect");
35
35
  Object.defineProperty(exports, "UserCollectServiceClient", { enumerable: true, get: function () { return usercollect_1.UserCollectServiceClient; } });
36
36
  var realname_1 = require("./realname");
37
37
  Object.defineProperty(exports, "RealNameServiceClient", { enumerable: true, get: function () { return realname_1.RealNameServiceClient; } });
38
+ var taxclearrefund_1 = require("./taxclearrefund");
39
+ Object.defineProperty(exports, "TaxClearRefundClient", { enumerable: true, get: function () { return taxclearrefund_1.TaxClearRefundClient; } });
38
40
 
@@ -0,0 +1,160 @@
1
+ import YZHclient from '../../common/client';
2
+
3
+
4
+ /** ClearTaxData 连续劳务税费清缴完成数据 */
5
+ interface ClearTaxData {
6
+ /** 报税属期 */
7
+ tax_month: string;
8
+ /** 综合服务主体 ID */
9
+ broker_id: string;
10
+ /** 平台企业 ID */
11
+ dealer_id: string;
12
+ /** 清缴次数 */
13
+ tax_clear_num: string;
14
+ /** 退补税用户数量 */
15
+ refund_tax_labor_num: string;
16
+ /** 退补税订单数量 */
17
+ refund_tax_order_num: string;
18
+ /** 订单总金额 */
19
+ total_amount: string;
20
+ /** 本批次退补税费总额 */
21
+ cur_total_refund_tax: string;
22
+ /** 退补税费总额 */
23
+ total_refund_tax: string;
24
+ /** 历史已退补税费总额 */
25
+ history_refund_tax: string;
26
+ /** 本批次预扣税费总额 */
27
+ total_tax: string;
28
+ /** 本批次实缴税费总额 */
29
+ receive_total_tax: string;
30
+ /** 本批次退补给用户税费总额 */
31
+ cur_total_refund_labor_tax: string;
32
+ /** 本批次退补给平台企业税费总额 */
33
+ cur_total_refund_dealer_tax: string;
34
+ /** 本批次退补给云账户税费总额 */
35
+ cur_total_refund_broker_tax: string;
36
+ /** 批次号 */
37
+ batch_id: string;
38
+ /** 批次生成时间 */
39
+ batch_create_time: string;
40
+ }
41
+
42
+ /** GetClearTaxInfoRequest 查询税费清缴完成结果请求 */
43
+ interface GetClearTaxInfoRequest {
44
+ /** 综合服务主体 ID */
45
+ broker_id: string;
46
+ /** 平台企业 ID */
47
+ dealer_id: string;
48
+ /** 报税属期 */
49
+ tax_month: string;
50
+ }
51
+
52
+ /** GetClearTaxInfoResponse 查询税费清缴完成结果返回 */
53
+ interface GetClearTaxInfoResponse {
54
+ /** 清缴批次列表 */
55
+ batch_list: ClearTaxData[];
56
+ }
57
+
58
+ /** GetClearTaxFileRequest 查询税费清缴明细文件请求 */
59
+ interface GetClearTaxFileRequest {
60
+ /** 综合服务主体 ID */
61
+ broker_id: string;
62
+ /** 平台企业 ID */
63
+ dealer_id: string;
64
+ /** 报税属期 */
65
+ tax_month: string;
66
+ /** 批次号 */
67
+ batch_id: string;
68
+ }
69
+
70
+ /** GetClearTaxFileResponse 查询税费清缴明细文件返回 */
71
+ interface GetClearTaxFileResponse {
72
+ /** 下载地址 */
73
+ url: string;
74
+ }
75
+
76
+ /** RefundTaxData 连续劳务税费退补完成数据 */
77
+ interface RefundTaxData {
78
+ /** 综合服务主体 ID */
79
+ broker_id: string;
80
+ /** 平台企业 ID */
81
+ dealer_id: string;
82
+ /** 清缴次数 */
83
+ tax_clear_num: string;
84
+ /** 报税属期 */
85
+ tax_month: string;
86
+ /** 退补税用户数量 */
87
+ refund_tax_labor_num: string;
88
+ /** 退补税订单数量 */
89
+ refund_tax_order_num: string;
90
+ /** 订单总金额 */
91
+ total_amount: string;
92
+ /** 本批次退补税费总额 */
93
+ cur_total_refund_tax: string;
94
+ /** 退补税费总额 */
95
+ total_refund_tax: string;
96
+ /** 历史已退补税费总额 */
97
+ history_refund_tax: string;
98
+ /** 本批次预扣税费总额 */
99
+ total_tax: string;
100
+ /** 本批次实缴税费总额 */
101
+ receive_total_tax: string;
102
+ /** 本批次退补给用户税费总额 */
103
+ cur_total_refund_labor_tax: string;
104
+ /** 本批次退补给平台企业税费总额 */
105
+ cur_total_refund_dealer_tax: string;
106
+ /** 本批次退补给云账户税费总额 */
107
+ cur_total_refund_broker_tax: string;
108
+ /** 批次号 */
109
+ batch_id: string;
110
+ /** 批次退补税状态 */
111
+ batch_refund_tax_status: string;
112
+ /** 批次生成时间 */
113
+ batch_create_time: string;
114
+ /** 批次退补税成功时间 */
115
+ batch_refund_tax_finished_time: string;
116
+ /** 已完成税费退补的用户数量 */
117
+ refund_tax_finished_labor_num: string;
118
+ /** 已完成的税费退补总额 */
119
+ refund_tax_finished_amount: string;
120
+ }
121
+
122
+ /** GetRefundTaxInfoRequest 查询税费退补完成结果请求 */
123
+ interface GetRefundTaxInfoRequest {
124
+ /** 综合服务主体 ID */
125
+ broker_id: string;
126
+ /** 平台企业 ID */
127
+ dealer_id: string;
128
+ /** 报税属期 */
129
+ tax_month: string;
130
+ /** 批次号 */
131
+ batch_id: string;
132
+ }
133
+
134
+ export declare class TaxClearRefundClient extends YZHclient {
135
+ constructor(conf: {
136
+ dealer_id: string;
137
+ broker_id: string;
138
+ app_key: string;
139
+ des3_key: string;
140
+ private_key: string;
141
+ yzh_public_key: string;
142
+ sign_type: 'rsa' | 'sha256';
143
+ base_url?: string;
144
+ timeout?: number;
145
+ })
146
+ GetClearTaxInfo(
147
+ req: GetClearTaxInfoRequest,
148
+ cb?: (error: null | string, rep: GetClearTaxInfoResponse) => void
149
+ ): Promise<GetClearTaxInfoResponse>;
150
+ GetClearTaxFile(
151
+ req: GetClearTaxFileRequest,
152
+ cb?: (error: null | string, rep: GetClearTaxFileResponse) => void
153
+ ): Promise<GetClearTaxFileResponse>;
154
+ GetRefundTaxInfo(
155
+ req: GetRefundTaxInfoRequest,
156
+ cb?: (error: null | string, rep: RefundTaxData) => void
157
+ ): Promise<RefundTaxData>;
158
+ }
159
+
160
+ export {};
@@ -0,0 +1,41 @@
1
+ 'use strict';
2
+ Object.defineProperty(exports, '__esModule', { value: true });
3
+ exports.TaxClearRefundClient = void 0;
4
+ const client_1 = require('../../common/client');
5
+ class TaxClearRefundClient extends client_1.default {
6
+ // eslint-disable-next-line no-useless-constructor
7
+ constructor(conf) {
8
+ super(conf);
9
+ }
10
+ // GetClearTaxInfo 查询税费清缴完成结果
11
+ async GetClearTaxInfo(req, cb) {
12
+ return this.request(
13
+ 'get',
14
+ '/api/payment/v1/query-clear-tax',
15
+ req,
16
+ { encryption: (req === null || req === void 0 ? void 0 : req.data_type) === 'encryption' },
17
+ cb
18
+ );
19
+ }
20
+ // GetClearTaxFile 查询税费清缴明细文件
21
+ async GetClearTaxFile(req, cb) {
22
+ return this.request(
23
+ 'get',
24
+ '/api/payment/v1/query-clear-tax/file',
25
+ req,
26
+ { encryption: (req === null || req === void 0 ? void 0 : req.data_type) === 'encryption' },
27
+ cb
28
+ );
29
+ }
30
+ // GetRefundTaxInfo 查询税费退补完成结果
31
+ async GetRefundTaxInfo(req, cb) {
32
+ return this.request(
33
+ 'get',
34
+ '/api/payment/v1/query-clear-status',
35
+ req,
36
+ { encryption: (req === null || req === void 0 ? void 0 : req.data_type) === 'encryption' },
37
+ cb
38
+ );
39
+ }
40
+ }
41
+ exports.TaxClearRefundClient = TaxClearRefundClient;