zhengyiming
2 天以前 b626d79c65da6f5e269fdc2af9c71dcd1823bac1
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
/* eslint-disable */
// @ts-ignore
import { request } from '@/utils/request';
 
/** 支付宝资金二级商户KYB代进件 POST /api/user/enterpriseWallet/alipayFundExpandindirectCreate */
export async function alipayFundExpandindirectCreate(
  body: API.AlipayFundExpandindirectCreateCommand,
  options?: API.RequestConfig
) {
  return request<string>('/api/user/enterpriseWallet/alipayFundExpandindirectCreate', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json-patch+json',
    },
    data: body,
    ...(options || {}),
  });
}
 
/** 支付宝资金二级商户KYB代进件状态通知 POST /api/user/enterpriseWallet/alipayFundExpandindirectCreateNotify */
export async function alipayFundExpandindirectCreateNotify(
  body: {
    /** 通知ID */
    notify_id?: string;
    /** 消息发送时的服务端时间 */
    utc_timestamp?: string;
    /** 消息接口名称 */
    msg_method?: string;
    /** 消息接受方的应用id */
    app_id?: string;
    /** 版本号(1.1版本为标准消息) */
    version?: string;
    /** 消息报文 */
    biz_content?: string;
    /** 签名 */
    sign?: string;
    /** 签名类型 */
    sign_type?: string;
    /** 编码集,该字符集为验签和解密所需要的字符集 */
    charset?: string;
  },
  options?: API.RequestConfig
) {
  const formData = new FormData();
 
  Object.keys(body).forEach((ele) => {
    const item = (body as any)[ele];
 
    if (item !== undefined && item !== null) {
      formData.append(
        ele,
        typeof item === 'object' && !(item instanceof File) ? JSON.stringify(item) : item
      );
    }
  });
 
  return request<string>('/api/user/enterpriseWallet/alipayFundExpandindirectCreateNotify', {
    method: 'POST',
    data: formData,
    requestType: 'form',
    ...(options || {}),
  });
}
 
/** 支付宝资金二级商户KYB代进件文件上传接口 POST /api/user/enterpriseWallet/alipayFundExpandindirectImageUpload */
export async function alipayFundExpandindirectImageUpload(
  body: {
    /** 产品码 */
    ProductCode?: string;
    /** 场景码 */
    BizScene?: string;
  },
  File?: File,
  options?: API.RequestConfig
) {
  const formData = new FormData();
 
  if (File) {
    formData.append('File', File);
  }
 
  Object.keys(body).forEach((ele) => {
    const item = (body as any)[ele];
 
    if (item !== undefined && item !== null) {
      formData.append(
        ele,
        typeof item === 'object' && !(item instanceof File) ? JSON.stringify(item) : item
      );
    }
  });
 
  return request<string>('/api/user/enterpriseWallet/alipayFundExpandindirectImageUpload', {
    method: 'POST',
    data: formData,
    requestType: 'form',
    ...(options || {}),
  });
}
 
/** 支付宝资金二级商户KYB代进件单取消接口 POST /api/user/enterpriseWallet/alipayFundExpandindirectOrderCancel */
export async function alipayFundExpandindirectOrderCancel(
  body: API.AlipayFundExpandindirectOrderCancelCommand,
  options?: API.RequestConfig
) {
  return request<string>('/api/user/enterpriseWallet/alipayFundExpandindirectOrderCancel', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json-patch+json',
    },
    data: body,
    ...(options || {}),
  });
}
 
/** 转账 POST /api/user/enterpriseWallet/alipayTransfer */
export async function alipayTransfer(body: API.AlipayTransferCommand, options?: API.RequestConfig) {
  return request<string>('/api/user/enterpriseWallet/alipayTransfer', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json-patch+json',
    },
    data: body,
    ...(options || {}),
  });
}
 
/** 支付宝用户授权协议签约通知 POST /api/user/enterpriseWallet/alipayUserAgreementPageSignNotify */
export async function alipayUserAgreementPageSignNotify(
  body: {
    notify_id?: string;
    notify_time?: string;
    sign_type?: string;
    sign?: string;
    invalid_time?: string;
    sign_scene?: string;
    sign_time?: string;
    alipay_user_id?: string;
    status?: string;
    forex_eligible?: string;
    external_logon_id?: string;
    app_id?: string;
    auth_app_id?: string;
    external_agreement_no?: string;
    personal_product_code?: string;
    valid_time?: string;
    agreement_no?: string;
    zm_open_id?: string;
    alipay_open_id?: string;
    merchant_app_id?: string;
    alipay_logon_id?: string;
    notify_type?: string;
    zm_score?: string;
    single_quota?: string;
    login_token?: string;
    device_id?: string;
    credit_auth_mode?: string;
    specified_sort_assets?: string;
    partner_id?: string;
    modify_type?: string;
    next_deduct_time?: string;
  },
  options?: API.RequestConfig
) {
  const formData = new FormData();
 
  Object.keys(body).forEach((ele) => {
    const item = (body as any)[ele];
 
    if (item !== undefined && item !== null) {
      formData.append(
        ele,
        typeof item === 'object' && !(item instanceof File) ? JSON.stringify(item) : item
      );
    }
  });
 
  return request<boolean>('/api/user/enterpriseWallet/alipayUserAgreementPageSignNotify', {
    method: 'POST',
    data: formData,
    requestType: 'form',
    ...(options || {}),
  });
}
 
/** 关闭企业钱包 POST /api/user/enterpriseWallet/closeEnterpriseWallet */
export async function closeEnterpriseWallet(
  body: API.CloseEnterpriseWalletCommand,
  options?: API.RequestConfig
) {
  return request<string>('/api/user/enterpriseWallet/closeEnterpriseWallet', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json-patch+json',
    },
    data: body,
    ...(options || {}),
  });
}
 
/** 查询支付宝资金二级商户KYB代进件单详情 GET /api/user/enterpriseWallet/getAlipayFundExpandindirectOrder */
export async function getAlipayFundExpandindirectOrder(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.APIgetAlipayFundExpandindirectOrderParams,
  options?: API.RequestConfig
) {
  return request<API.GetAlipayFundExpandindirectOrderQueryResult>(
    '/api/user/enterpriseWallet/getAlipayFundExpandindirectOrder',
    {
      method: 'GET',
      params: {
        ...params,
      },
      ...(options || {}),
    }
  );
}
 
/** 支付宝通知回传 GET /api/user/enterpriseWallet/getAlipayNotify */
export async function getAlipayNotify(
  body: API.GetAlipayNotifyCommand,
  options?: API.RequestConfig
) {
  const formData = new FormData();
 
  Object.keys(body).forEach((ele) => {
    const item = (body as any)[ele];
 
    if (item !== undefined && item !== null) {
      formData.append(
        ele,
        typeof item === 'object' && !(item instanceof File) ? JSON.stringify(item) : item
      );
    }
  });
 
  return request<boolean>('/api/user/enterpriseWallet/getAlipayNotify', {
    method: 'GET',
    data: formData,
    requestType: 'form',
    ...(options || {}),
  });
}
 
/** 查询企业钱包详情 GET /api/user/enterpriseWallet/getEnterpriseWallet */
export async function getEnterpriseWallet(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.APIgetEnterpriseWalletParams,
  options?: API.RequestConfig
) {
  return request<API.GetEnterpriseWalletQueryResult>(
    '/api/user/enterpriseWallet/getEnterpriseWallet',
    {
      method: 'GET',
      params: {
        ...params,
      },
      ...(options || {}),
    }
  );
}
 
/** 开通企业钱包 POST /api/user/enterpriseWallet/openEnterpriseWallet */
export async function openEnterpriseWallet(
  body: API.OpenEnterpriseWalletCommand,
  options?: API.RequestConfig
) {
  return request<API.OpenEnterpriseWalletCommandResult>(
    '/api/user/enterpriseWallet/openEnterpriseWallet',
    {
      method: 'POST',
      headers: {
        'Content-Type': 'application/json-patch+json',
      },
      data: body,
      ...(options || {}),
    }
  );
}