@larksuiteoapi/node-sdk 1.28.1 → 1.30.0
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.
- package/es/index.js +1237 -21
- package/lib/index.js +1237 -21
- package/package.json +1 -1
- package/types/index.d.ts +7804 -378
package/es/index.js
CHANGED
|
@@ -221,7 +221,7 @@ const formatErrors = (e) => {
|
|
|
221
221
|
};
|
|
222
222
|
|
|
223
223
|
// auto gen
|
|
224
|
-
class Client
|
|
224
|
+
class Client$$ {
|
|
225
225
|
constructor() {
|
|
226
226
|
/**
|
|
227
227
|
* 智能门禁
|
|
@@ -1194,11 +1194,11 @@ class Client$Z {
|
|
|
1194
1194
|
}
|
|
1195
1195
|
|
|
1196
1196
|
// auto gen
|
|
1197
|
-
class Client$
|
|
1197
|
+
class Client$_ extends Client$$ {
|
|
1198
1198
|
constructor() {
|
|
1199
1199
|
super(...arguments);
|
|
1200
1200
|
/**
|
|
1201
|
-
*
|
|
1201
|
+
* 管理后台-企业勋章
|
|
1202
1202
|
*/
|
|
1203
1203
|
this.admin = {
|
|
1204
1204
|
/**
|
|
@@ -1320,6 +1320,8 @@ class Client$Y extends Client$Z {
|
|
|
1320
1320
|
* {@link https://open.feishu.cn/api-explorer?project=admin&resource=audit_info&apiName=list&version=v1 click to debug }
|
|
1321
1321
|
*
|
|
1322
1322
|
* {@link https://open.feishu.cn/document/ukTMukTMukTM/uQjM5YjL0ITO24CNykjN/audit_log/audit_data_get document }
|
|
1323
|
+
*
|
|
1324
|
+
* 用户行为日志搜索
|
|
1323
1325
|
*/
|
|
1324
1326
|
list: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
1325
1327
|
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
@@ -1840,6 +1842,8 @@ class Client$Y extends Client$Z {
|
|
|
1840
1842
|
* {@link https://open.feishu.cn/api-explorer?project=admin&resource=audit_info&apiName=list&version=v1 click to debug }
|
|
1841
1843
|
*
|
|
1842
1844
|
* {@link https://open.feishu.cn/document/ukTMukTMukTM/uQjM5YjL0ITO24CNykjN/audit_log/audit_data_get document }
|
|
1845
|
+
*
|
|
1846
|
+
* 用户行为日志搜索
|
|
1843
1847
|
*/
|
|
1844
1848
|
list: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
1845
1849
|
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
@@ -2246,7 +2250,376 @@ class Client$Y extends Client$Z {
|
|
|
2246
2250
|
}
|
|
2247
2251
|
|
|
2248
2252
|
// auto gen
|
|
2249
|
-
class Client$
|
|
2253
|
+
class Client$Z extends Client$_ {
|
|
2254
|
+
constructor() {
|
|
2255
|
+
super(...arguments);
|
|
2256
|
+
/**
|
|
2257
|
+
|
|
2258
|
+
*/
|
|
2259
|
+
this.aily = {
|
|
2260
|
+
v1: {
|
|
2261
|
+
/**
|
|
2262
|
+
* aily_session.aily_message
|
|
2263
|
+
*/
|
|
2264
|
+
ailySessionAilyMessage: {
|
|
2265
|
+
/**
|
|
2266
|
+
* {@link https://open.feishu.cn/api-explorer?project=aily&resource=aily_session.aily_message&apiName=create&version=v1 click to debug }
|
|
2267
|
+
*
|
|
2268
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=create&project=aily&resource=aily_session.aily_message&version=v1 document }
|
|
2269
|
+
*
|
|
2270
|
+
* 该 API 用于向某个飞书智能伙伴应用发送一条消息(Message)。
|
|
2271
|
+
*/
|
|
2272
|
+
create: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
2273
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
2274
|
+
return this.httpInstance
|
|
2275
|
+
.request({
|
|
2276
|
+
url: fillApiPath(`${this.domain}/open-apis/aily/v1/sessions/:aily_session_id/messages`, path),
|
|
2277
|
+
method: "POST",
|
|
2278
|
+
data,
|
|
2279
|
+
params,
|
|
2280
|
+
headers,
|
|
2281
|
+
})
|
|
2282
|
+
.catch((e) => {
|
|
2283
|
+
this.logger.error(formatErrors(e));
|
|
2284
|
+
throw e;
|
|
2285
|
+
});
|
|
2286
|
+
}),
|
|
2287
|
+
/**
|
|
2288
|
+
* {@link https://open.feishu.cn/api-explorer?project=aily&resource=aily_session.aily_message&apiName=get&version=v1 click to debug }
|
|
2289
|
+
*
|
|
2290
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=get&project=aily&resource=aily_session.aily_message&version=v1 document }
|
|
2291
|
+
*
|
|
2292
|
+
* 该 API 用于获取某个飞书智能伙伴应用的消息(Message)的详细信息;包括消息的内容、发送人等。
|
|
2293
|
+
*/
|
|
2294
|
+
get: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
2295
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
2296
|
+
return this.httpInstance
|
|
2297
|
+
.request({
|
|
2298
|
+
url: fillApiPath(`${this.domain}/open-apis/aily/v1/sessions/:aily_session_id/messages/:aily_message_id`, path),
|
|
2299
|
+
method: "GET",
|
|
2300
|
+
data,
|
|
2301
|
+
params,
|
|
2302
|
+
headers,
|
|
2303
|
+
})
|
|
2304
|
+
.catch((e) => {
|
|
2305
|
+
this.logger.error(formatErrors(e));
|
|
2306
|
+
throw e;
|
|
2307
|
+
});
|
|
2308
|
+
}),
|
|
2309
|
+
listWithIterator: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
2310
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
2311
|
+
const sendRequest = (innerPayload) => __awaiter(this, void 0, void 0, function* () {
|
|
2312
|
+
const res = yield this.httpInstance
|
|
2313
|
+
.request({
|
|
2314
|
+
url: fillApiPath(`${this.domain}/open-apis/aily/v1/sessions/:aily_session_id/messages`, path),
|
|
2315
|
+
method: "GET",
|
|
2316
|
+
headers: pickBy(innerPayload.headers, identity),
|
|
2317
|
+
params: pickBy(innerPayload.params, identity),
|
|
2318
|
+
data,
|
|
2319
|
+
})
|
|
2320
|
+
.catch((e) => {
|
|
2321
|
+
this.logger.error(formatErrors(e));
|
|
2322
|
+
});
|
|
2323
|
+
return res;
|
|
2324
|
+
});
|
|
2325
|
+
const Iterable = {
|
|
2326
|
+
[Symbol.asyncIterator]() {
|
|
2327
|
+
return __asyncGenerator(this, arguments, function* _a() {
|
|
2328
|
+
let hasMore = true;
|
|
2329
|
+
let pageToken;
|
|
2330
|
+
while (hasMore) {
|
|
2331
|
+
try {
|
|
2332
|
+
const res = yield __await(sendRequest({
|
|
2333
|
+
headers,
|
|
2334
|
+
params: Object.assign(Object.assign({}, params), { page_token: pageToken }),
|
|
2335
|
+
data,
|
|
2336
|
+
}));
|
|
2337
|
+
const _b = get(res, "data") || {}, {
|
|
2338
|
+
// @ts-ignore
|
|
2339
|
+
has_more,
|
|
2340
|
+
// @ts-ignore
|
|
2341
|
+
page_token,
|
|
2342
|
+
// @ts-ignore
|
|
2343
|
+
next_page_token } = _b, rest = __rest(_b, ["has_more", "page_token", "next_page_token"]);
|
|
2344
|
+
yield yield __await(rest);
|
|
2345
|
+
hasMore = Boolean(has_more);
|
|
2346
|
+
pageToken = page_token || next_page_token;
|
|
2347
|
+
}
|
|
2348
|
+
catch (e) {
|
|
2349
|
+
yield yield __await(null);
|
|
2350
|
+
break;
|
|
2351
|
+
}
|
|
2352
|
+
}
|
|
2353
|
+
});
|
|
2354
|
+
},
|
|
2355
|
+
};
|
|
2356
|
+
return Iterable;
|
|
2357
|
+
}),
|
|
2358
|
+
/**
|
|
2359
|
+
* {@link https://open.feishu.cn/api-explorer?project=aily&resource=aily_session.aily_message&apiName=list&version=v1 click to debug }
|
|
2360
|
+
*
|
|
2361
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=list&project=aily&resource=aily_session.aily_message&version=v1 document }
|
|
2362
|
+
*
|
|
2363
|
+
* 该 API 用于批量获取飞书智能伙伴应用的消息(Message)的详细信息
|
|
2364
|
+
*/
|
|
2365
|
+
list: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
2366
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
2367
|
+
return this.httpInstance
|
|
2368
|
+
.request({
|
|
2369
|
+
url: fillApiPath(`${this.domain}/open-apis/aily/v1/sessions/:aily_session_id/messages`, path),
|
|
2370
|
+
method: "GET",
|
|
2371
|
+
data,
|
|
2372
|
+
params,
|
|
2373
|
+
headers,
|
|
2374
|
+
})
|
|
2375
|
+
.catch((e) => {
|
|
2376
|
+
this.logger.error(formatErrors(e));
|
|
2377
|
+
throw e;
|
|
2378
|
+
});
|
|
2379
|
+
}),
|
|
2380
|
+
},
|
|
2381
|
+
/**
|
|
2382
|
+
* aily_session
|
|
2383
|
+
*/
|
|
2384
|
+
ailySession: {
|
|
2385
|
+
/**
|
|
2386
|
+
* {@link https://open.feishu.cn/api-explorer?project=aily&resource=aily_session&apiName=create&version=v1 click to debug }
|
|
2387
|
+
*
|
|
2388
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=create&project=aily&resource=aily_session&version=v1 document }
|
|
2389
|
+
*
|
|
2390
|
+
* 该 API 用于创建与某个飞书智能伙伴应用的一次会话(Session)。
|
|
2391
|
+
*/
|
|
2392
|
+
create: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
2393
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
2394
|
+
return this.httpInstance
|
|
2395
|
+
.request({
|
|
2396
|
+
url: fillApiPath(`${this.domain}/open-apis/aily/v1/sessions`, path),
|
|
2397
|
+
method: "POST",
|
|
2398
|
+
data,
|
|
2399
|
+
params,
|
|
2400
|
+
headers,
|
|
2401
|
+
})
|
|
2402
|
+
.catch((e) => {
|
|
2403
|
+
this.logger.error(formatErrors(e));
|
|
2404
|
+
throw e;
|
|
2405
|
+
});
|
|
2406
|
+
}),
|
|
2407
|
+
/**
|
|
2408
|
+
* {@link https://open.feishu.cn/api-explorer?project=aily&resource=aily_session&apiName=delete&version=v1 click to debug }
|
|
2409
|
+
*
|
|
2410
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=delete&project=aily&resource=aily_session&version=v1 document }
|
|
2411
|
+
*
|
|
2412
|
+
* 该 API 用于销毁与某个飞书智能伙伴应用的一次会话(Session),当会话销毁后、无法继续在会话中创建 / 拉取消息。
|
|
2413
|
+
*/
|
|
2414
|
+
delete: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
2415
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
2416
|
+
return this.httpInstance
|
|
2417
|
+
.request({
|
|
2418
|
+
url: fillApiPath(`${this.domain}/open-apis/aily/v1/sessions/:aily_session_id`, path),
|
|
2419
|
+
method: "DELETE",
|
|
2420
|
+
data,
|
|
2421
|
+
params,
|
|
2422
|
+
headers,
|
|
2423
|
+
})
|
|
2424
|
+
.catch((e) => {
|
|
2425
|
+
this.logger.error(formatErrors(e));
|
|
2426
|
+
throw e;
|
|
2427
|
+
});
|
|
2428
|
+
}),
|
|
2429
|
+
/**
|
|
2430
|
+
* {@link https://open.feishu.cn/api-explorer?project=aily&resource=aily_session&apiName=get&version=v1 click to debug }
|
|
2431
|
+
*
|
|
2432
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=get&project=aily&resource=aily_session&version=v1 document }
|
|
2433
|
+
*
|
|
2434
|
+
* 该 API 用于获取与某个飞书智能伙伴应用的一次会话(Session)的详细信息,包括会话的状态、渠道信息、创建时间等。
|
|
2435
|
+
*/
|
|
2436
|
+
get: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
2437
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
2438
|
+
return this.httpInstance
|
|
2439
|
+
.request({
|
|
2440
|
+
url: fillApiPath(`${this.domain}/open-apis/aily/v1/sessions/:aily_session_id`, path),
|
|
2441
|
+
method: "GET",
|
|
2442
|
+
data,
|
|
2443
|
+
params,
|
|
2444
|
+
headers,
|
|
2445
|
+
})
|
|
2446
|
+
.catch((e) => {
|
|
2447
|
+
this.logger.error(formatErrors(e));
|
|
2448
|
+
throw e;
|
|
2449
|
+
});
|
|
2450
|
+
}),
|
|
2451
|
+
/**
|
|
2452
|
+
* {@link https://open.feishu.cn/api-explorer?project=aily&resource=aily_session&apiName=update&version=v1 click to debug }
|
|
2453
|
+
*
|
|
2454
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=update&project=aily&resource=aily_session&version=v1 document }
|
|
2455
|
+
*
|
|
2456
|
+
* 该 API 用于更新与某个飞书智能伙伴应用的一次会话(Session)。
|
|
2457
|
+
*/
|
|
2458
|
+
update: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
2459
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
2460
|
+
return this.httpInstance
|
|
2461
|
+
.request({
|
|
2462
|
+
url: fillApiPath(`${this.domain}/open-apis/aily/v1/sessions/:aily_session_id`, path),
|
|
2463
|
+
method: "PUT",
|
|
2464
|
+
data,
|
|
2465
|
+
params,
|
|
2466
|
+
headers,
|
|
2467
|
+
})
|
|
2468
|
+
.catch((e) => {
|
|
2469
|
+
this.logger.error(formatErrors(e));
|
|
2470
|
+
throw e;
|
|
2471
|
+
});
|
|
2472
|
+
}),
|
|
2473
|
+
},
|
|
2474
|
+
/**
|
|
2475
|
+
* aily_session.run
|
|
2476
|
+
*/
|
|
2477
|
+
ailySessionRun: {
|
|
2478
|
+
/**
|
|
2479
|
+
* {@link https://open.feishu.cn/api-explorer?project=aily&resource=aily_session.run&apiName=cancel&version=v1 click to debug }
|
|
2480
|
+
*
|
|
2481
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=cancel&project=aily&resource=aily_session.run&version=v1 document }
|
|
2482
|
+
*
|
|
2483
|
+
* 该 API 用于取消指定的运行(Run)。
|
|
2484
|
+
*/
|
|
2485
|
+
cancel: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
2486
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
2487
|
+
return this.httpInstance
|
|
2488
|
+
.request({
|
|
2489
|
+
url: fillApiPath(`${this.domain}/open-apis/aily/v1/sessions/:aily_session_id/runs/:run_id/cancel`, path),
|
|
2490
|
+
method: "POST",
|
|
2491
|
+
data,
|
|
2492
|
+
params,
|
|
2493
|
+
headers,
|
|
2494
|
+
})
|
|
2495
|
+
.catch((e) => {
|
|
2496
|
+
this.logger.error(formatErrors(e));
|
|
2497
|
+
throw e;
|
|
2498
|
+
});
|
|
2499
|
+
}),
|
|
2500
|
+
/**
|
|
2501
|
+
* {@link https://open.feishu.cn/api-explorer?project=aily&resource=aily_session.run&apiName=create&version=v1 click to debug }
|
|
2502
|
+
*
|
|
2503
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=create&project=aily&resource=aily_session.run&version=v1 document }
|
|
2504
|
+
*
|
|
2505
|
+
* 该 API 用于启动一次运行(Run)。
|
|
2506
|
+
*/
|
|
2507
|
+
create: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
2508
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
2509
|
+
return this.httpInstance
|
|
2510
|
+
.request({
|
|
2511
|
+
url: fillApiPath(`${this.domain}/open-apis/aily/v1/sessions/:aily_session_id/runs`, path),
|
|
2512
|
+
method: "POST",
|
|
2513
|
+
data,
|
|
2514
|
+
params,
|
|
2515
|
+
headers,
|
|
2516
|
+
})
|
|
2517
|
+
.catch((e) => {
|
|
2518
|
+
this.logger.error(formatErrors(e));
|
|
2519
|
+
throw e;
|
|
2520
|
+
});
|
|
2521
|
+
}),
|
|
2522
|
+
/**
|
|
2523
|
+
* {@link https://open.feishu.cn/api-explorer?project=aily&resource=aily_session.run&apiName=get&version=v1 click to debug }
|
|
2524
|
+
*
|
|
2525
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=get&project=aily&resource=aily_session.run&version=v1 document }
|
|
2526
|
+
*
|
|
2527
|
+
* 该 API 用于获取运行(Run)的详细信息。
|
|
2528
|
+
*/
|
|
2529
|
+
get: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
2530
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
2531
|
+
return this.httpInstance
|
|
2532
|
+
.request({
|
|
2533
|
+
url: fillApiPath(`${this.domain}/open-apis/aily/v1/sessions/:aily_session_id/runs/:run_id`, path),
|
|
2534
|
+
method: "GET",
|
|
2535
|
+
data,
|
|
2536
|
+
params,
|
|
2537
|
+
headers,
|
|
2538
|
+
})
|
|
2539
|
+
.catch((e) => {
|
|
2540
|
+
this.logger.error(formatErrors(e));
|
|
2541
|
+
throw e;
|
|
2542
|
+
});
|
|
2543
|
+
}),
|
|
2544
|
+
listWithIterator: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
2545
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
2546
|
+
const sendRequest = (innerPayload) => __awaiter(this, void 0, void 0, function* () {
|
|
2547
|
+
const res = yield this.httpInstance
|
|
2548
|
+
.request({
|
|
2549
|
+
url: fillApiPath(`${this.domain}/open-apis/aily/v1/sessions/:aily_session_id/runs`, path),
|
|
2550
|
+
method: "GET",
|
|
2551
|
+
headers: pickBy(innerPayload.headers, identity),
|
|
2552
|
+
params: pickBy(innerPayload.params, identity),
|
|
2553
|
+
data,
|
|
2554
|
+
})
|
|
2555
|
+
.catch((e) => {
|
|
2556
|
+
this.logger.error(formatErrors(e));
|
|
2557
|
+
});
|
|
2558
|
+
return res;
|
|
2559
|
+
});
|
|
2560
|
+
const Iterable = {
|
|
2561
|
+
[Symbol.asyncIterator]() {
|
|
2562
|
+
return __asyncGenerator(this, arguments, function* _a() {
|
|
2563
|
+
let hasMore = true;
|
|
2564
|
+
let pageToken;
|
|
2565
|
+
while (hasMore) {
|
|
2566
|
+
try {
|
|
2567
|
+
const res = yield __await(sendRequest({
|
|
2568
|
+
headers,
|
|
2569
|
+
params: Object.assign(Object.assign({}, params), { page_token: pageToken }),
|
|
2570
|
+
data,
|
|
2571
|
+
}));
|
|
2572
|
+
const _b = get(res, "data") || {}, {
|
|
2573
|
+
// @ts-ignore
|
|
2574
|
+
has_more,
|
|
2575
|
+
// @ts-ignore
|
|
2576
|
+
page_token,
|
|
2577
|
+
// @ts-ignore
|
|
2578
|
+
next_page_token } = _b, rest = __rest(_b, ["has_more", "page_token", "next_page_token"]);
|
|
2579
|
+
yield yield __await(rest);
|
|
2580
|
+
hasMore = Boolean(has_more);
|
|
2581
|
+
pageToken = page_token || next_page_token;
|
|
2582
|
+
}
|
|
2583
|
+
catch (e) {
|
|
2584
|
+
yield yield __await(null);
|
|
2585
|
+
break;
|
|
2586
|
+
}
|
|
2587
|
+
}
|
|
2588
|
+
});
|
|
2589
|
+
},
|
|
2590
|
+
};
|
|
2591
|
+
return Iterable;
|
|
2592
|
+
}),
|
|
2593
|
+
/**
|
|
2594
|
+
* {@link https://open.feishu.cn/api-explorer?project=aily&resource=aily_session.run&apiName=list&version=v1 click to debug }
|
|
2595
|
+
*
|
|
2596
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=list&project=aily&resource=aily_session.run&version=v1 document }
|
|
2597
|
+
*
|
|
2598
|
+
* 该 API 用于批量获取运行(Run)的详细信息。
|
|
2599
|
+
*/
|
|
2600
|
+
list: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
2601
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
2602
|
+
return this.httpInstance
|
|
2603
|
+
.request({
|
|
2604
|
+
url: fillApiPath(`${this.domain}/open-apis/aily/v1/sessions/:aily_session_id/runs`, path),
|
|
2605
|
+
method: "GET",
|
|
2606
|
+
data,
|
|
2607
|
+
params,
|
|
2608
|
+
headers,
|
|
2609
|
+
})
|
|
2610
|
+
.catch((e) => {
|
|
2611
|
+
this.logger.error(formatErrors(e));
|
|
2612
|
+
throw e;
|
|
2613
|
+
});
|
|
2614
|
+
}),
|
|
2615
|
+
},
|
|
2616
|
+
},
|
|
2617
|
+
};
|
|
2618
|
+
}
|
|
2619
|
+
}
|
|
2620
|
+
|
|
2621
|
+
// auto gen
|
|
2622
|
+
class Client$Y extends Client$Z {
|
|
2250
2623
|
constructor() {
|
|
2251
2624
|
super(...arguments);
|
|
2252
2625
|
/**
|
|
@@ -3472,7 +3845,7 @@ class Client$X extends Client$Y {
|
|
|
3472
3845
|
}
|
|
3473
3846
|
|
|
3474
3847
|
// auto gen
|
|
3475
|
-
class Client$
|
|
3848
|
+
class Client$X extends Client$Y {
|
|
3476
3849
|
constructor() {
|
|
3477
3850
|
super(...arguments);
|
|
3478
3851
|
/**
|
|
@@ -3480,7 +3853,7 @@ class Client$W extends Client$X {
|
|
|
3480
3853
|
*/
|
|
3481
3854
|
this.approval = {
|
|
3482
3855
|
/**
|
|
3483
|
-
*
|
|
3856
|
+
* 事件
|
|
3484
3857
|
*/
|
|
3485
3858
|
approval: {
|
|
3486
3859
|
/**
|
|
@@ -4449,7 +4822,7 @@ class Client$W extends Client$X {
|
|
|
4449
4822
|
},
|
|
4450
4823
|
v4: {
|
|
4451
4824
|
/**
|
|
4452
|
-
*
|
|
4825
|
+
* 事件
|
|
4453
4826
|
*/
|
|
4454
4827
|
approval: {
|
|
4455
4828
|
/**
|
|
@@ -5422,7 +5795,7 @@ class Client$W extends Client$X {
|
|
|
5422
5795
|
}
|
|
5423
5796
|
|
|
5424
5797
|
// auto gen
|
|
5425
|
-
class Client$
|
|
5798
|
+
class Client$W extends Client$X {
|
|
5426
5799
|
constructor() {
|
|
5427
5800
|
super(...arguments);
|
|
5428
5801
|
/**
|
|
@@ -7370,7 +7743,7 @@ class Client$V extends Client$W {
|
|
|
7370
7743
|
}
|
|
7371
7744
|
|
|
7372
7745
|
// auto gen
|
|
7373
|
-
class Client$
|
|
7746
|
+
class Client$V extends Client$W {
|
|
7374
7747
|
constructor() {
|
|
7375
7748
|
super(...arguments);
|
|
7376
7749
|
/**
|
|
@@ -7614,7 +7987,7 @@ class Client$U extends Client$V {
|
|
|
7614
7987
|
}
|
|
7615
7988
|
|
|
7616
7989
|
// auto gen
|
|
7617
|
-
class Client$
|
|
7990
|
+
class Client$U extends Client$V {
|
|
7618
7991
|
constructor() {
|
|
7619
7992
|
super(...arguments);
|
|
7620
7993
|
/**
|
|
@@ -7878,7 +8251,7 @@ class Client$T extends Client$U {
|
|
|
7878
8251
|
}
|
|
7879
8252
|
|
|
7880
8253
|
// auto gen
|
|
7881
|
-
class Client$
|
|
8254
|
+
class Client$T extends Client$U {
|
|
7882
8255
|
constructor() {
|
|
7883
8256
|
super(...arguments);
|
|
7884
8257
|
/**
|
|
@@ -7889,7 +8262,7 @@ class Client$S extends Client$T {
|
|
|
7889
8262
|
}
|
|
7890
8263
|
|
|
7891
8264
|
// auto gen
|
|
7892
|
-
class Client$
|
|
8265
|
+
class Client$S extends Client$T {
|
|
7893
8266
|
constructor() {
|
|
7894
8267
|
super(...arguments);
|
|
7895
8268
|
/**
|
|
@@ -8905,7 +9278,7 @@ class Client$R extends Client$S {
|
|
|
8905
9278
|
}
|
|
8906
9279
|
|
|
8907
9280
|
// auto gen
|
|
8908
|
-
class Client$
|
|
9281
|
+
class Client$R extends Client$S {
|
|
8909
9282
|
constructor() {
|
|
8910
9283
|
super(...arguments);
|
|
8911
9284
|
/**
|
|
@@ -12053,7 +12426,7 @@ class Client$Q extends Client$R {
|
|
|
12053
12426
|
}
|
|
12054
12427
|
|
|
12055
12428
|
// auto gen
|
|
12056
|
-
class Client$
|
|
12429
|
+
class Client$Q extends Client$R {
|
|
12057
12430
|
constructor() {
|
|
12058
12431
|
super(...arguments);
|
|
12059
12432
|
/**
|
|
@@ -12231,7 +12604,7 @@ class Client$P extends Client$Q {
|
|
|
12231
12604
|
}
|
|
12232
12605
|
|
|
12233
12606
|
// auto gen
|
|
12234
|
-
class Client$
|
|
12607
|
+
class Client$P extends Client$Q {
|
|
12235
12608
|
constructor() {
|
|
12236
12609
|
super(...arguments);
|
|
12237
12610
|
/**
|
|
@@ -12272,7 +12645,7 @@ class Client$O extends Client$P {
|
|
|
12272
12645
|
}
|
|
12273
12646
|
|
|
12274
12647
|
// auto gen
|
|
12275
|
-
class Client$
|
|
12648
|
+
class Client$O extends Client$P {
|
|
12276
12649
|
constructor() {
|
|
12277
12650
|
super(...arguments);
|
|
12278
12651
|
/**
|
|
@@ -14860,7 +15233,7 @@ class Client$N extends Client$O {
|
|
|
14860
15233
|
}
|
|
14861
15234
|
|
|
14862
15235
|
// auto gen
|
|
14863
|
-
class Client$
|
|
15236
|
+
class Client$N extends Client$O {
|
|
14864
15237
|
constructor() {
|
|
14865
15238
|
super(...arguments);
|
|
14866
15239
|
/**
|
|
@@ -14870,6 +15243,415 @@ class Client$M extends Client$N {
|
|
|
14870
15243
|
}
|
|
14871
15244
|
}
|
|
14872
15245
|
|
|
15246
|
+
// auto gen
|
|
15247
|
+
class Client$M extends Client$N {
|
|
15248
|
+
constructor() {
|
|
15249
|
+
super(...arguments);
|
|
15250
|
+
/**
|
|
15251
|
+
|
|
15252
|
+
*/
|
|
15253
|
+
this.compensation = {
|
|
15254
|
+
v1: {
|
|
15255
|
+
/**
|
|
15256
|
+
* archive
|
|
15257
|
+
*/
|
|
15258
|
+
archive: {
|
|
15259
|
+
/**
|
|
15260
|
+
* {@link https://open.feishu.cn/api-explorer?project=compensation&resource=archive&apiName=query&version=v1 click to debug }
|
|
15261
|
+
*
|
|
15262
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=query&project=compensation&resource=archive&version=v1 document }
|
|
15263
|
+
*/
|
|
15264
|
+
query: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
15265
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
15266
|
+
return this.httpInstance
|
|
15267
|
+
.request({
|
|
15268
|
+
url: fillApiPath(`${this.domain}/open-apis/compensation/v1/archives/query`, path),
|
|
15269
|
+
method: "POST",
|
|
15270
|
+
data,
|
|
15271
|
+
params,
|
|
15272
|
+
headers,
|
|
15273
|
+
})
|
|
15274
|
+
.catch((e) => {
|
|
15275
|
+
this.logger.error(formatErrors(e));
|
|
15276
|
+
throw e;
|
|
15277
|
+
});
|
|
15278
|
+
}),
|
|
15279
|
+
},
|
|
15280
|
+
/**
|
|
15281
|
+
* change_reason
|
|
15282
|
+
*/
|
|
15283
|
+
changeReason: {
|
|
15284
|
+
listWithIterator: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
15285
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
15286
|
+
const sendRequest = (innerPayload) => __awaiter(this, void 0, void 0, function* () {
|
|
15287
|
+
const res = yield this.httpInstance
|
|
15288
|
+
.request({
|
|
15289
|
+
url: fillApiPath(`${this.domain}/open-apis/compensation/v1/change_reasons`, path),
|
|
15290
|
+
method: "GET",
|
|
15291
|
+
headers: pickBy(innerPayload.headers, identity),
|
|
15292
|
+
params: pickBy(innerPayload.params, identity),
|
|
15293
|
+
data,
|
|
15294
|
+
})
|
|
15295
|
+
.catch((e) => {
|
|
15296
|
+
this.logger.error(formatErrors(e));
|
|
15297
|
+
});
|
|
15298
|
+
return res;
|
|
15299
|
+
});
|
|
15300
|
+
const Iterable = {
|
|
15301
|
+
[Symbol.asyncIterator]() {
|
|
15302
|
+
return __asyncGenerator(this, arguments, function* _a() {
|
|
15303
|
+
let hasMore = true;
|
|
15304
|
+
let pageToken;
|
|
15305
|
+
while (hasMore) {
|
|
15306
|
+
try {
|
|
15307
|
+
const res = yield __await(sendRequest({
|
|
15308
|
+
headers,
|
|
15309
|
+
params: Object.assign(Object.assign({}, params), { page_token: pageToken }),
|
|
15310
|
+
data,
|
|
15311
|
+
}));
|
|
15312
|
+
const _b = get(res, "data") || {}, {
|
|
15313
|
+
// @ts-ignore
|
|
15314
|
+
has_more,
|
|
15315
|
+
// @ts-ignore
|
|
15316
|
+
page_token,
|
|
15317
|
+
// @ts-ignore
|
|
15318
|
+
next_page_token } = _b, rest = __rest(_b, ["has_more", "page_token", "next_page_token"]);
|
|
15319
|
+
yield yield __await(rest);
|
|
15320
|
+
hasMore = Boolean(has_more);
|
|
15321
|
+
pageToken = page_token || next_page_token;
|
|
15322
|
+
}
|
|
15323
|
+
catch (e) {
|
|
15324
|
+
yield yield __await(null);
|
|
15325
|
+
break;
|
|
15326
|
+
}
|
|
15327
|
+
}
|
|
15328
|
+
});
|
|
15329
|
+
},
|
|
15330
|
+
};
|
|
15331
|
+
return Iterable;
|
|
15332
|
+
}),
|
|
15333
|
+
/**
|
|
15334
|
+
* {@link https://open.feishu.cn/api-explorer?project=compensation&resource=change_reason&apiName=list&version=v1 click to debug }
|
|
15335
|
+
*
|
|
15336
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=list&project=compensation&resource=change_reason&version=v1 document }
|
|
15337
|
+
*/
|
|
15338
|
+
list: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
15339
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
15340
|
+
return this.httpInstance
|
|
15341
|
+
.request({
|
|
15342
|
+
url: fillApiPath(`${this.domain}/open-apis/compensation/v1/change_reasons`, path),
|
|
15343
|
+
method: "GET",
|
|
15344
|
+
data,
|
|
15345
|
+
params,
|
|
15346
|
+
headers,
|
|
15347
|
+
})
|
|
15348
|
+
.catch((e) => {
|
|
15349
|
+
this.logger.error(formatErrors(e));
|
|
15350
|
+
throw e;
|
|
15351
|
+
});
|
|
15352
|
+
}),
|
|
15353
|
+
},
|
|
15354
|
+
/**
|
|
15355
|
+
* indicator
|
|
15356
|
+
*/
|
|
15357
|
+
indicator: {
|
|
15358
|
+
listWithIterator: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
15359
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
15360
|
+
const sendRequest = (innerPayload) => __awaiter(this, void 0, void 0, function* () {
|
|
15361
|
+
const res = yield this.httpInstance
|
|
15362
|
+
.request({
|
|
15363
|
+
url: fillApiPath(`${this.domain}/open-apis/compensation/v1/indicators`, path),
|
|
15364
|
+
method: "GET",
|
|
15365
|
+
headers: pickBy(innerPayload.headers, identity),
|
|
15366
|
+
params: pickBy(innerPayload.params, identity),
|
|
15367
|
+
data,
|
|
15368
|
+
})
|
|
15369
|
+
.catch((e) => {
|
|
15370
|
+
this.logger.error(formatErrors(e));
|
|
15371
|
+
});
|
|
15372
|
+
return res;
|
|
15373
|
+
});
|
|
15374
|
+
const Iterable = {
|
|
15375
|
+
[Symbol.asyncIterator]() {
|
|
15376
|
+
return __asyncGenerator(this, arguments, function* _a() {
|
|
15377
|
+
let hasMore = true;
|
|
15378
|
+
let pageToken;
|
|
15379
|
+
while (hasMore) {
|
|
15380
|
+
try {
|
|
15381
|
+
const res = yield __await(sendRequest({
|
|
15382
|
+
headers,
|
|
15383
|
+
params: Object.assign(Object.assign({}, params), { page_token: pageToken }),
|
|
15384
|
+
data,
|
|
15385
|
+
}));
|
|
15386
|
+
const _b = get(res, "data") || {}, {
|
|
15387
|
+
// @ts-ignore
|
|
15388
|
+
has_more,
|
|
15389
|
+
// @ts-ignore
|
|
15390
|
+
page_token,
|
|
15391
|
+
// @ts-ignore
|
|
15392
|
+
next_page_token } = _b, rest = __rest(_b, ["has_more", "page_token", "next_page_token"]);
|
|
15393
|
+
yield yield __await(rest);
|
|
15394
|
+
hasMore = Boolean(has_more);
|
|
15395
|
+
pageToken = page_token || next_page_token;
|
|
15396
|
+
}
|
|
15397
|
+
catch (e) {
|
|
15398
|
+
yield yield __await(null);
|
|
15399
|
+
break;
|
|
15400
|
+
}
|
|
15401
|
+
}
|
|
15402
|
+
});
|
|
15403
|
+
},
|
|
15404
|
+
};
|
|
15405
|
+
return Iterable;
|
|
15406
|
+
}),
|
|
15407
|
+
/**
|
|
15408
|
+
* {@link https://open.feishu.cn/api-explorer?project=compensation&resource=indicator&apiName=list&version=v1 click to debug }
|
|
15409
|
+
*
|
|
15410
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=list&project=compensation&resource=indicator&version=v1 document }
|
|
15411
|
+
*/
|
|
15412
|
+
list: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
15413
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
15414
|
+
return this.httpInstance
|
|
15415
|
+
.request({
|
|
15416
|
+
url: fillApiPath(`${this.domain}/open-apis/compensation/v1/indicators`, path),
|
|
15417
|
+
method: "GET",
|
|
15418
|
+
data,
|
|
15419
|
+
params,
|
|
15420
|
+
headers,
|
|
15421
|
+
})
|
|
15422
|
+
.catch((e) => {
|
|
15423
|
+
this.logger.error(formatErrors(e));
|
|
15424
|
+
throw e;
|
|
15425
|
+
});
|
|
15426
|
+
}),
|
|
15427
|
+
},
|
|
15428
|
+
/**
|
|
15429
|
+
* item
|
|
15430
|
+
*/
|
|
15431
|
+
item: {
|
|
15432
|
+
listWithIterator: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
15433
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
15434
|
+
const sendRequest = (innerPayload) => __awaiter(this, void 0, void 0, function* () {
|
|
15435
|
+
const res = yield this.httpInstance
|
|
15436
|
+
.request({
|
|
15437
|
+
url: fillApiPath(`${this.domain}/open-apis/compensation/v1/items`, path),
|
|
15438
|
+
method: "GET",
|
|
15439
|
+
headers: pickBy(innerPayload.headers, identity),
|
|
15440
|
+
params: pickBy(innerPayload.params, identity),
|
|
15441
|
+
data,
|
|
15442
|
+
})
|
|
15443
|
+
.catch((e) => {
|
|
15444
|
+
this.logger.error(formatErrors(e));
|
|
15445
|
+
});
|
|
15446
|
+
return res;
|
|
15447
|
+
});
|
|
15448
|
+
const Iterable = {
|
|
15449
|
+
[Symbol.asyncIterator]() {
|
|
15450
|
+
return __asyncGenerator(this, arguments, function* _a() {
|
|
15451
|
+
let hasMore = true;
|
|
15452
|
+
let pageToken;
|
|
15453
|
+
while (hasMore) {
|
|
15454
|
+
try {
|
|
15455
|
+
const res = yield __await(sendRequest({
|
|
15456
|
+
headers,
|
|
15457
|
+
params: Object.assign(Object.assign({}, params), { page_token: pageToken }),
|
|
15458
|
+
data,
|
|
15459
|
+
}));
|
|
15460
|
+
const _b = get(res, "data") || {}, {
|
|
15461
|
+
// @ts-ignore
|
|
15462
|
+
has_more,
|
|
15463
|
+
// @ts-ignore
|
|
15464
|
+
page_token,
|
|
15465
|
+
// @ts-ignore
|
|
15466
|
+
next_page_token } = _b, rest = __rest(_b, ["has_more", "page_token", "next_page_token"]);
|
|
15467
|
+
yield yield __await(rest);
|
|
15468
|
+
hasMore = Boolean(has_more);
|
|
15469
|
+
pageToken = page_token || next_page_token;
|
|
15470
|
+
}
|
|
15471
|
+
catch (e) {
|
|
15472
|
+
yield yield __await(null);
|
|
15473
|
+
break;
|
|
15474
|
+
}
|
|
15475
|
+
}
|
|
15476
|
+
});
|
|
15477
|
+
},
|
|
15478
|
+
};
|
|
15479
|
+
return Iterable;
|
|
15480
|
+
}),
|
|
15481
|
+
/**
|
|
15482
|
+
* {@link https://open.feishu.cn/api-explorer?project=compensation&resource=item&apiName=list&version=v1 click to debug }
|
|
15483
|
+
*
|
|
15484
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=list&project=compensation&resource=item&version=v1 document }
|
|
15485
|
+
*/
|
|
15486
|
+
list: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
15487
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
15488
|
+
return this.httpInstance
|
|
15489
|
+
.request({
|
|
15490
|
+
url: fillApiPath(`${this.domain}/open-apis/compensation/v1/items`, path),
|
|
15491
|
+
method: "GET",
|
|
15492
|
+
data,
|
|
15493
|
+
params,
|
|
15494
|
+
headers,
|
|
15495
|
+
})
|
|
15496
|
+
.catch((e) => {
|
|
15497
|
+
this.logger.error(formatErrors(e));
|
|
15498
|
+
throw e;
|
|
15499
|
+
});
|
|
15500
|
+
}),
|
|
15501
|
+
},
|
|
15502
|
+
/**
|
|
15503
|
+
* item_category
|
|
15504
|
+
*/
|
|
15505
|
+
itemCategory: {
|
|
15506
|
+
listWithIterator: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
15507
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
15508
|
+
const sendRequest = (innerPayload) => __awaiter(this, void 0, void 0, function* () {
|
|
15509
|
+
const res = yield this.httpInstance
|
|
15510
|
+
.request({
|
|
15511
|
+
url: fillApiPath(`${this.domain}/open-apis/compensation/v1/item_categories`, path),
|
|
15512
|
+
method: "GET",
|
|
15513
|
+
headers: pickBy(innerPayload.headers, identity),
|
|
15514
|
+
params: pickBy(innerPayload.params, identity),
|
|
15515
|
+
data,
|
|
15516
|
+
})
|
|
15517
|
+
.catch((e) => {
|
|
15518
|
+
this.logger.error(formatErrors(e));
|
|
15519
|
+
});
|
|
15520
|
+
return res;
|
|
15521
|
+
});
|
|
15522
|
+
const Iterable = {
|
|
15523
|
+
[Symbol.asyncIterator]() {
|
|
15524
|
+
return __asyncGenerator(this, arguments, function* _a() {
|
|
15525
|
+
let hasMore = true;
|
|
15526
|
+
let pageToken;
|
|
15527
|
+
while (hasMore) {
|
|
15528
|
+
try {
|
|
15529
|
+
const res = yield __await(sendRequest({
|
|
15530
|
+
headers,
|
|
15531
|
+
params: Object.assign(Object.assign({}, params), { page_token: pageToken }),
|
|
15532
|
+
data,
|
|
15533
|
+
}));
|
|
15534
|
+
const _b = get(res, "data") || {}, {
|
|
15535
|
+
// @ts-ignore
|
|
15536
|
+
has_more,
|
|
15537
|
+
// @ts-ignore
|
|
15538
|
+
page_token,
|
|
15539
|
+
// @ts-ignore
|
|
15540
|
+
next_page_token } = _b, rest = __rest(_b, ["has_more", "page_token", "next_page_token"]);
|
|
15541
|
+
yield yield __await(rest);
|
|
15542
|
+
hasMore = Boolean(has_more);
|
|
15543
|
+
pageToken = page_token || next_page_token;
|
|
15544
|
+
}
|
|
15545
|
+
catch (e) {
|
|
15546
|
+
yield yield __await(null);
|
|
15547
|
+
break;
|
|
15548
|
+
}
|
|
15549
|
+
}
|
|
15550
|
+
});
|
|
15551
|
+
},
|
|
15552
|
+
};
|
|
15553
|
+
return Iterable;
|
|
15554
|
+
}),
|
|
15555
|
+
/**
|
|
15556
|
+
* {@link https://open.feishu.cn/api-explorer?project=compensation&resource=item_category&apiName=list&version=v1 click to debug }
|
|
15557
|
+
*
|
|
15558
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=list&project=compensation&resource=item_category&version=v1 document }
|
|
15559
|
+
*/
|
|
15560
|
+
list: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
15561
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
15562
|
+
return this.httpInstance
|
|
15563
|
+
.request({
|
|
15564
|
+
url: fillApiPath(`${this.domain}/open-apis/compensation/v1/item_categories`, path),
|
|
15565
|
+
method: "GET",
|
|
15566
|
+
data,
|
|
15567
|
+
params,
|
|
15568
|
+
headers,
|
|
15569
|
+
})
|
|
15570
|
+
.catch((e) => {
|
|
15571
|
+
this.logger.error(formatErrors(e));
|
|
15572
|
+
throw e;
|
|
15573
|
+
});
|
|
15574
|
+
}),
|
|
15575
|
+
},
|
|
15576
|
+
/**
|
|
15577
|
+
* plan
|
|
15578
|
+
*/
|
|
15579
|
+
plan: {
|
|
15580
|
+
listWithIterator: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
15581
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
15582
|
+
const sendRequest = (innerPayload) => __awaiter(this, void 0, void 0, function* () {
|
|
15583
|
+
const res = yield this.httpInstance
|
|
15584
|
+
.request({
|
|
15585
|
+
url: fillApiPath(`${this.domain}/open-apis/compensation/v1/plans`, path),
|
|
15586
|
+
method: "GET",
|
|
15587
|
+
headers: pickBy(innerPayload.headers, identity),
|
|
15588
|
+
params: pickBy(innerPayload.params, identity),
|
|
15589
|
+
data,
|
|
15590
|
+
})
|
|
15591
|
+
.catch((e) => {
|
|
15592
|
+
this.logger.error(formatErrors(e));
|
|
15593
|
+
});
|
|
15594
|
+
return res;
|
|
15595
|
+
});
|
|
15596
|
+
const Iterable = {
|
|
15597
|
+
[Symbol.asyncIterator]() {
|
|
15598
|
+
return __asyncGenerator(this, arguments, function* _a() {
|
|
15599
|
+
let hasMore = true;
|
|
15600
|
+
let pageToken;
|
|
15601
|
+
while (hasMore) {
|
|
15602
|
+
try {
|
|
15603
|
+
const res = yield __await(sendRequest({
|
|
15604
|
+
headers,
|
|
15605
|
+
params: Object.assign(Object.assign({}, params), { page_token: pageToken }),
|
|
15606
|
+
data,
|
|
15607
|
+
}));
|
|
15608
|
+
const _b = get(res, "data") || {}, {
|
|
15609
|
+
// @ts-ignore
|
|
15610
|
+
has_more,
|
|
15611
|
+
// @ts-ignore
|
|
15612
|
+
page_token,
|
|
15613
|
+
// @ts-ignore
|
|
15614
|
+
next_page_token } = _b, rest = __rest(_b, ["has_more", "page_token", "next_page_token"]);
|
|
15615
|
+
yield yield __await(rest);
|
|
15616
|
+
hasMore = Boolean(has_more);
|
|
15617
|
+
pageToken = page_token || next_page_token;
|
|
15618
|
+
}
|
|
15619
|
+
catch (e) {
|
|
15620
|
+
yield yield __await(null);
|
|
15621
|
+
break;
|
|
15622
|
+
}
|
|
15623
|
+
}
|
|
15624
|
+
});
|
|
15625
|
+
},
|
|
15626
|
+
};
|
|
15627
|
+
return Iterable;
|
|
15628
|
+
}),
|
|
15629
|
+
/**
|
|
15630
|
+
* {@link https://open.feishu.cn/api-explorer?project=compensation&resource=plan&apiName=list&version=v1 click to debug }
|
|
15631
|
+
*
|
|
15632
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=list&project=compensation&resource=plan&version=v1 document }
|
|
15633
|
+
*/
|
|
15634
|
+
list: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
15635
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
15636
|
+
return this.httpInstance
|
|
15637
|
+
.request({
|
|
15638
|
+
url: fillApiPath(`${this.domain}/open-apis/compensation/v1/plans`, path),
|
|
15639
|
+
method: "GET",
|
|
15640
|
+
data,
|
|
15641
|
+
params,
|
|
15642
|
+
headers,
|
|
15643
|
+
})
|
|
15644
|
+
.catch((e) => {
|
|
15645
|
+
this.logger.error(formatErrors(e));
|
|
15646
|
+
throw e;
|
|
15647
|
+
});
|
|
15648
|
+
}),
|
|
15649
|
+
},
|
|
15650
|
+
},
|
|
15651
|
+
};
|
|
15652
|
+
}
|
|
15653
|
+
}
|
|
15654
|
+
|
|
14873
15655
|
// auto gen
|
|
14874
15656
|
class Client$L extends Client$M {
|
|
14875
15657
|
constructor() {
|
|
@@ -19757,6 +20539,80 @@ class Client$I extends Client$J {
|
|
|
19757
20539
|
});
|
|
19758
20540
|
}),
|
|
19759
20541
|
},
|
|
20542
|
+
/**
|
|
20543
|
+
* authorization
|
|
20544
|
+
*/
|
|
20545
|
+
authorization: {
|
|
20546
|
+
/**
|
|
20547
|
+
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=authorization&apiName=get_by_param&version=v1 click to debug }
|
|
20548
|
+
*
|
|
20549
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=get_by_param&project=corehr&resource=authorization&version=v1 document }
|
|
20550
|
+
*
|
|
20551
|
+
* 根据ID查询单个用户授权
|
|
20552
|
+
*/
|
|
20553
|
+
getByParam: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
20554
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
20555
|
+
return this.httpInstance
|
|
20556
|
+
.request({
|
|
20557
|
+
url: fillApiPath(`${this.domain}/open-apis/corehr/v1/authorizations/get_by_param`, path),
|
|
20558
|
+
method: "GET",
|
|
20559
|
+
data,
|
|
20560
|
+
params,
|
|
20561
|
+
headers,
|
|
20562
|
+
})
|
|
20563
|
+
.catch((e) => {
|
|
20564
|
+
this.logger.error(formatErrors(e));
|
|
20565
|
+
throw e;
|
|
20566
|
+
});
|
|
20567
|
+
}),
|
|
20568
|
+
/**
|
|
20569
|
+
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=authorization&apiName=query&version=v1 click to debug }
|
|
20570
|
+
*
|
|
20571
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=query&project=corehr&resource=authorization&version=v1 document }
|
|
20572
|
+
*
|
|
20573
|
+
* 批量查询用户授权
|
|
20574
|
+
*/
|
|
20575
|
+
query: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
20576
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
20577
|
+
return this.httpInstance
|
|
20578
|
+
.request({
|
|
20579
|
+
url: fillApiPath(`${this.domain}/open-apis/corehr/v1/authorizations/query`, path),
|
|
20580
|
+
method: "GET",
|
|
20581
|
+
data,
|
|
20582
|
+
params,
|
|
20583
|
+
headers,
|
|
20584
|
+
})
|
|
20585
|
+
.catch((e) => {
|
|
20586
|
+
this.logger.error(formatErrors(e));
|
|
20587
|
+
throw e;
|
|
20588
|
+
});
|
|
20589
|
+
}),
|
|
20590
|
+
},
|
|
20591
|
+
/**
|
|
20592
|
+
* common_data.id
|
|
20593
|
+
*/
|
|
20594
|
+
commonDataId: {
|
|
20595
|
+
/**
|
|
20596
|
+
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=common_data.id&apiName=convert&version=v1 click to debug }
|
|
20597
|
+
*
|
|
20598
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=convert&project=corehr&resource=common_data.id&version=v1 document }
|
|
20599
|
+
*/
|
|
20600
|
+
convert: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
20601
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
20602
|
+
return this.httpInstance
|
|
20603
|
+
.request({
|
|
20604
|
+
url: fillApiPath(`${this.domain}/open-apis/corehr/v1/common_data/id/convert`, path),
|
|
20605
|
+
method: "POST",
|
|
20606
|
+
data,
|
|
20607
|
+
params,
|
|
20608
|
+
headers,
|
|
20609
|
+
})
|
|
20610
|
+
.catch((e) => {
|
|
20611
|
+
this.logger.error(formatErrors(e));
|
|
20612
|
+
throw e;
|
|
20613
|
+
});
|
|
20614
|
+
}),
|
|
20615
|
+
},
|
|
19760
20616
|
/**
|
|
19761
20617
|
* 公司
|
|
19762
20618
|
*/
|
|
@@ -21595,6 +22451,30 @@ class Client$I extends Client$J {
|
|
|
21595
22451
|
* 个人信息
|
|
21596
22452
|
*/
|
|
21597
22453
|
person: {
|
|
22454
|
+
/**
|
|
22455
|
+
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=person&apiName=create&version=v1 click to debug }
|
|
22456
|
+
*
|
|
22457
|
+
* {@link https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/reference/corehr-v1/person/create document }
|
|
22458
|
+
*
|
|
22459
|
+
* 创建个人信息
|
|
22460
|
+
*
|
|
22461
|
+
* 创建人员的个人信息
|
|
22462
|
+
*/
|
|
22463
|
+
create: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
22464
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
22465
|
+
return this.httpInstance
|
|
22466
|
+
.request({
|
|
22467
|
+
url: fillApiPath(`${this.domain}/open-apis/corehr/v1/persons`, path),
|
|
22468
|
+
method: "POST",
|
|
22469
|
+
data,
|
|
22470
|
+
params,
|
|
22471
|
+
headers,
|
|
22472
|
+
})
|
|
22473
|
+
.catch((e) => {
|
|
22474
|
+
this.logger.error(formatErrors(e));
|
|
22475
|
+
throw e;
|
|
22476
|
+
});
|
|
22477
|
+
}),
|
|
21598
22478
|
/**
|
|
21599
22479
|
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=person&apiName=delete&version=v1 click to debug }
|
|
21600
22480
|
*
|
|
@@ -21643,6 +22523,30 @@ class Client$I extends Client$J {
|
|
|
21643
22523
|
throw e;
|
|
21644
22524
|
});
|
|
21645
22525
|
}),
|
|
22526
|
+
/**
|
|
22527
|
+
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=person&apiName=patch&version=v1 click to debug }
|
|
22528
|
+
*
|
|
22529
|
+
* {@link https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/reference/corehr-v1/person/patch document }
|
|
22530
|
+
*
|
|
22531
|
+
* 更新个人信息
|
|
22532
|
+
*
|
|
22533
|
+
* 更新个人信息
|
|
22534
|
+
*/
|
|
22535
|
+
patch: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
22536
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
22537
|
+
return this.httpInstance
|
|
22538
|
+
.request({
|
|
22539
|
+
url: fillApiPath(`${this.domain}/open-apis/corehr/v1/persons/:person_id`, path),
|
|
22540
|
+
method: "PATCH",
|
|
22541
|
+
data,
|
|
22542
|
+
params,
|
|
22543
|
+
headers,
|
|
22544
|
+
})
|
|
22545
|
+
.catch((e) => {
|
|
22546
|
+
this.logger.error(formatErrors(e));
|
|
22547
|
+
throw e;
|
|
22548
|
+
});
|
|
22549
|
+
}),
|
|
21646
22550
|
/**
|
|
21647
22551
|
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=person&apiName=upload&version=v1 click to debug }
|
|
21648
22552
|
*
|
|
@@ -22171,6 +23075,80 @@ class Client$I extends Client$J {
|
|
|
22171
23075
|
});
|
|
22172
23076
|
}),
|
|
22173
23077
|
},
|
|
23078
|
+
/**
|
|
23079
|
+
* authorization
|
|
23080
|
+
*/
|
|
23081
|
+
authorization: {
|
|
23082
|
+
/**
|
|
23083
|
+
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=authorization&apiName=get_by_param&version=v1 click to debug }
|
|
23084
|
+
*
|
|
23085
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=get_by_param&project=corehr&resource=authorization&version=v1 document }
|
|
23086
|
+
*
|
|
23087
|
+
* 根据ID查询单个用户授权
|
|
23088
|
+
*/
|
|
23089
|
+
getByParam: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
23090
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
23091
|
+
return this.httpInstance
|
|
23092
|
+
.request({
|
|
23093
|
+
url: fillApiPath(`${this.domain}/open-apis/corehr/v1/authorizations/get_by_param`, path),
|
|
23094
|
+
method: "GET",
|
|
23095
|
+
data,
|
|
23096
|
+
params,
|
|
23097
|
+
headers,
|
|
23098
|
+
})
|
|
23099
|
+
.catch((e) => {
|
|
23100
|
+
this.logger.error(formatErrors(e));
|
|
23101
|
+
throw e;
|
|
23102
|
+
});
|
|
23103
|
+
}),
|
|
23104
|
+
/**
|
|
23105
|
+
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=authorization&apiName=query&version=v1 click to debug }
|
|
23106
|
+
*
|
|
23107
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=query&project=corehr&resource=authorization&version=v1 document }
|
|
23108
|
+
*
|
|
23109
|
+
* 批量查询用户授权
|
|
23110
|
+
*/
|
|
23111
|
+
query: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
23112
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
23113
|
+
return this.httpInstance
|
|
23114
|
+
.request({
|
|
23115
|
+
url: fillApiPath(`${this.domain}/open-apis/corehr/v1/authorizations/query`, path),
|
|
23116
|
+
method: "GET",
|
|
23117
|
+
data,
|
|
23118
|
+
params,
|
|
23119
|
+
headers,
|
|
23120
|
+
})
|
|
23121
|
+
.catch((e) => {
|
|
23122
|
+
this.logger.error(formatErrors(e));
|
|
23123
|
+
throw e;
|
|
23124
|
+
});
|
|
23125
|
+
}),
|
|
23126
|
+
},
|
|
23127
|
+
/**
|
|
23128
|
+
* common_data.id
|
|
23129
|
+
*/
|
|
23130
|
+
commonDataId: {
|
|
23131
|
+
/**
|
|
23132
|
+
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=common_data.id&apiName=convert&version=v1 click to debug }
|
|
23133
|
+
*
|
|
23134
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=convert&project=corehr&resource=common_data.id&version=v1 document }
|
|
23135
|
+
*/
|
|
23136
|
+
convert: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
23137
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
23138
|
+
return this.httpInstance
|
|
23139
|
+
.request({
|
|
23140
|
+
url: fillApiPath(`${this.domain}/open-apis/corehr/v1/common_data/id/convert`, path),
|
|
23141
|
+
method: "POST",
|
|
23142
|
+
data,
|
|
23143
|
+
params,
|
|
23144
|
+
headers,
|
|
23145
|
+
})
|
|
23146
|
+
.catch((e) => {
|
|
23147
|
+
this.logger.error(formatErrors(e));
|
|
23148
|
+
throw e;
|
|
23149
|
+
});
|
|
23150
|
+
}),
|
|
23151
|
+
},
|
|
22174
23152
|
/**
|
|
22175
23153
|
* 公司
|
|
22176
23154
|
*/
|
|
@@ -24009,6 +24987,30 @@ class Client$I extends Client$J {
|
|
|
24009
24987
|
* 个人信息
|
|
24010
24988
|
*/
|
|
24011
24989
|
person: {
|
|
24990
|
+
/**
|
|
24991
|
+
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=person&apiName=create&version=v1 click to debug }
|
|
24992
|
+
*
|
|
24993
|
+
* {@link https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/reference/corehr-v1/person/create document }
|
|
24994
|
+
*
|
|
24995
|
+
* 创建个人信息
|
|
24996
|
+
*
|
|
24997
|
+
* 创建人员的个人信息
|
|
24998
|
+
*/
|
|
24999
|
+
create: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
25000
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
25001
|
+
return this.httpInstance
|
|
25002
|
+
.request({
|
|
25003
|
+
url: fillApiPath(`${this.domain}/open-apis/corehr/v1/persons`, path),
|
|
25004
|
+
method: "POST",
|
|
25005
|
+
data,
|
|
25006
|
+
params,
|
|
25007
|
+
headers,
|
|
25008
|
+
})
|
|
25009
|
+
.catch((e) => {
|
|
25010
|
+
this.logger.error(formatErrors(e));
|
|
25011
|
+
throw e;
|
|
25012
|
+
});
|
|
25013
|
+
}),
|
|
24012
25014
|
/**
|
|
24013
25015
|
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=person&apiName=delete&version=v1 click to debug }
|
|
24014
25016
|
*
|
|
@@ -24057,6 +25059,30 @@ class Client$I extends Client$J {
|
|
|
24057
25059
|
throw e;
|
|
24058
25060
|
});
|
|
24059
25061
|
}),
|
|
25062
|
+
/**
|
|
25063
|
+
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=person&apiName=patch&version=v1 click to debug }
|
|
25064
|
+
*
|
|
25065
|
+
* {@link https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/reference/corehr-v1/person/patch document }
|
|
25066
|
+
*
|
|
25067
|
+
* 更新个人信息
|
|
25068
|
+
*
|
|
25069
|
+
* 更新个人信息
|
|
25070
|
+
*/
|
|
25071
|
+
patch: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
25072
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
25073
|
+
return this.httpInstance
|
|
25074
|
+
.request({
|
|
25075
|
+
url: fillApiPath(`${this.domain}/open-apis/corehr/v1/persons/:person_id`, path),
|
|
25076
|
+
method: "PATCH",
|
|
25077
|
+
data,
|
|
25078
|
+
params,
|
|
25079
|
+
headers,
|
|
25080
|
+
})
|
|
25081
|
+
.catch((e) => {
|
|
25082
|
+
this.logger.error(formatErrors(e));
|
|
25083
|
+
throw e;
|
|
25084
|
+
});
|
|
25085
|
+
}),
|
|
24060
25086
|
/**
|
|
24061
25087
|
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=person&apiName=upload&version=v1 click to debug }
|
|
24062
25088
|
*
|
|
@@ -25554,6 +26580,50 @@ class Client$I extends Client$J {
|
|
|
25554
26580
|
throw e;
|
|
25555
26581
|
});
|
|
25556
26582
|
}),
|
|
26583
|
+
/**
|
|
26584
|
+
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=department&apiName=query_multi_timeline&version=v2 click to debug }
|
|
26585
|
+
*
|
|
26586
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=query_multi_timeline&project=corehr&resource=department&version=v2 document }
|
|
26587
|
+
*
|
|
26588
|
+
* 查询任意日期部门信息
|
|
26589
|
+
*/
|
|
26590
|
+
queryMultiTimeline: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
26591
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
26592
|
+
return this.httpInstance
|
|
26593
|
+
.request({
|
|
26594
|
+
url: fillApiPath(`${this.domain}/open-apis/corehr/v2/departments/query_multi_timeline`, path),
|
|
26595
|
+
method: "POST",
|
|
26596
|
+
data,
|
|
26597
|
+
params,
|
|
26598
|
+
headers,
|
|
26599
|
+
})
|
|
26600
|
+
.catch((e) => {
|
|
26601
|
+
this.logger.error(formatErrors(e));
|
|
26602
|
+
throw e;
|
|
26603
|
+
});
|
|
26604
|
+
}),
|
|
26605
|
+
/**
|
|
26606
|
+
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=department&apiName=query_timeline&version=v2 click to debug }
|
|
26607
|
+
*
|
|
26608
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=query_timeline&project=corehr&resource=department&version=v2 document }
|
|
26609
|
+
*
|
|
26610
|
+
* 查询任意日期部门信息
|
|
26611
|
+
*/
|
|
26612
|
+
queryTimeline: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
26613
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
26614
|
+
return this.httpInstance
|
|
26615
|
+
.request({
|
|
26616
|
+
url: fillApiPath(`${this.domain}/open-apis/corehr/v2/departments/query_timeline`, path),
|
|
26617
|
+
method: "POST",
|
|
26618
|
+
data,
|
|
26619
|
+
params,
|
|
26620
|
+
headers,
|
|
26621
|
+
})
|
|
26622
|
+
.catch((e) => {
|
|
26623
|
+
this.logger.error(formatErrors(e));
|
|
26624
|
+
throw e;
|
|
26625
|
+
});
|
|
26626
|
+
}),
|
|
25557
26627
|
searchWithIterator: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
25558
26628
|
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
25559
26629
|
const sendRequest = (innerPayload) => __awaiter(this, void 0, void 0, function* () {
|
|
@@ -25946,6 +27016,33 @@ class Client$I extends Client$J {
|
|
|
25946
27016
|
});
|
|
25947
27017
|
}),
|
|
25948
27018
|
},
|
|
27019
|
+
/**
|
|
27020
|
+
* job_grade
|
|
27021
|
+
*/
|
|
27022
|
+
jobGrade: {
|
|
27023
|
+
/**
|
|
27024
|
+
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=job_grade&apiName=query&version=v2 click to debug }
|
|
27025
|
+
*
|
|
27026
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=query&project=corehr&resource=job_grade&version=v2 document }
|
|
27027
|
+
*
|
|
27028
|
+
* 查询职等信息
|
|
27029
|
+
*/
|
|
27030
|
+
query: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
27031
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
27032
|
+
return this.httpInstance
|
|
27033
|
+
.request({
|
|
27034
|
+
url: fillApiPath(`${this.domain}/open-apis/corehr/v2/job_grades/query`, path),
|
|
27035
|
+
method: "POST",
|
|
27036
|
+
data,
|
|
27037
|
+
params,
|
|
27038
|
+
headers,
|
|
27039
|
+
})
|
|
27040
|
+
.catch((e) => {
|
|
27041
|
+
this.logger.error(formatErrors(e));
|
|
27042
|
+
throw e;
|
|
27043
|
+
});
|
|
27044
|
+
}),
|
|
27045
|
+
},
|
|
25949
27046
|
/**
|
|
25950
27047
|
* job_level
|
|
25951
27048
|
*/
|
|
@@ -26075,6 +27172,50 @@ class Client$I extends Client$J {
|
|
|
26075
27172
|
throw e;
|
|
26076
27173
|
});
|
|
26077
27174
|
}),
|
|
27175
|
+
/**
|
|
27176
|
+
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=pre_hire&apiName=delete&version=v2 click to debug }
|
|
27177
|
+
*
|
|
27178
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=delete&project=corehr&resource=pre_hire&version=v2 document }
|
|
27179
|
+
*
|
|
27180
|
+
* 删除待入职
|
|
27181
|
+
*/
|
|
27182
|
+
delete: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
27183
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
27184
|
+
return this.httpInstance
|
|
27185
|
+
.request({
|
|
27186
|
+
url: fillApiPath(`${this.domain}/open-apis/corehr/v2/pre_hires/:pre_hire_id`, path),
|
|
27187
|
+
method: "DELETE",
|
|
27188
|
+
data,
|
|
27189
|
+
params,
|
|
27190
|
+
headers,
|
|
27191
|
+
})
|
|
27192
|
+
.catch((e) => {
|
|
27193
|
+
this.logger.error(formatErrors(e));
|
|
27194
|
+
throw e;
|
|
27195
|
+
});
|
|
27196
|
+
}),
|
|
27197
|
+
/**
|
|
27198
|
+
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=pre_hire&apiName=patch&version=v2 click to debug }
|
|
27199
|
+
*
|
|
27200
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=patch&project=corehr&resource=pre_hire&version=v2 document }
|
|
27201
|
+
*
|
|
27202
|
+
* 更新待入职
|
|
27203
|
+
*/
|
|
27204
|
+
patch: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
27205
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
27206
|
+
return this.httpInstance
|
|
27207
|
+
.request({
|
|
27208
|
+
url: fillApiPath(`${this.domain}/open-apis/corehr/v2/pre_hires/:pre_hire_id`, path),
|
|
27209
|
+
method: "PATCH",
|
|
27210
|
+
data,
|
|
27211
|
+
params,
|
|
27212
|
+
headers,
|
|
27213
|
+
})
|
|
27214
|
+
.catch((e) => {
|
|
27215
|
+
this.logger.error(formatErrors(e));
|
|
27216
|
+
throw e;
|
|
27217
|
+
});
|
|
27218
|
+
}),
|
|
26078
27219
|
searchWithIterator: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
26079
27220
|
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
26080
27221
|
const sendRequest = (innerPayload) => __awaiter(this, void 0, void 0, function* () {
|
|
@@ -26306,6 +27447,31 @@ class Client$I extends Client$J {
|
|
|
26306
27447
|
});
|
|
26307
27448
|
}),
|
|
26308
27449
|
},
|
|
27450
|
+
/**
|
|
27451
|
+
* process.form_variable_data
|
|
27452
|
+
*/
|
|
27453
|
+
processFormVariableData: {
|
|
27454
|
+
/**
|
|
27455
|
+
* {@link https://open.feishu.cn/api-explorer?project=corehr&resource=process.form_variable_data&apiName=get&version=v2 click to debug }
|
|
27456
|
+
*
|
|
27457
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=get&project=corehr&resource=process.form_variable_data&version=v2 document }
|
|
27458
|
+
*/
|
|
27459
|
+
get: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
27460
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
27461
|
+
return this.httpInstance
|
|
27462
|
+
.request({
|
|
27463
|
+
url: fillApiPath(`${this.domain}/open-apis/corehr/v2/processes/:process_id/form_variable_data`, path),
|
|
27464
|
+
method: "GET",
|
|
27465
|
+
data,
|
|
27466
|
+
params,
|
|
27467
|
+
headers,
|
|
27468
|
+
})
|
|
27469
|
+
.catch((e) => {
|
|
27470
|
+
this.logger.error(formatErrors(e));
|
|
27471
|
+
throw e;
|
|
27472
|
+
});
|
|
27473
|
+
}),
|
|
27474
|
+
},
|
|
26309
27475
|
/**
|
|
26310
27476
|
* process
|
|
26311
27477
|
*/
|
|
@@ -28099,7 +29265,7 @@ class Client$E extends Client$F {
|
|
|
28099
29265
|
}),
|
|
28100
29266
|
},
|
|
28101
29267
|
/**
|
|
28102
|
-
*
|
|
29268
|
+
* 异步任务状态
|
|
28103
29269
|
*/
|
|
28104
29270
|
file: {
|
|
28105
29271
|
/**
|
|
@@ -29798,7 +30964,7 @@ class Client$E extends Client$F {
|
|
|
29798
30964
|
}),
|
|
29799
30965
|
},
|
|
29800
30966
|
/**
|
|
29801
|
-
*
|
|
30967
|
+
* 异步任务状态
|
|
29802
30968
|
*/
|
|
29803
30969
|
file: {
|
|
29804
30970
|
/**
|
|
@@ -36929,6 +38095,31 @@ class Client$u extends Client$v {
|
|
|
36929
38095
|
});
|
|
36930
38096
|
}),
|
|
36931
38097
|
},
|
|
38098
|
+
/**
|
|
38099
|
+
* role
|
|
38100
|
+
*/
|
|
38101
|
+
role: {
|
|
38102
|
+
/**
|
|
38103
|
+
* {@link https://open.feishu.cn/api-explorer?project=hire&resource=role&apiName=get&version=v1 click to debug }
|
|
38104
|
+
*
|
|
38105
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=get&project=hire&resource=role&version=v1 document }
|
|
38106
|
+
*/
|
|
38107
|
+
get: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
38108
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
38109
|
+
return this.httpInstance
|
|
38110
|
+
.request({
|
|
38111
|
+
url: fillApiPath(`${this.domain}/open-apis/hire/v1/roles/:role_id`, path),
|
|
38112
|
+
method: "GET",
|
|
38113
|
+
data,
|
|
38114
|
+
params,
|
|
38115
|
+
headers,
|
|
38116
|
+
})
|
|
38117
|
+
.catch((e) => {
|
|
38118
|
+
this.logger.error(formatErrors(e));
|
|
38119
|
+
throw e;
|
|
38120
|
+
});
|
|
38121
|
+
}),
|
|
38122
|
+
},
|
|
36932
38123
|
/**
|
|
36933
38124
|
* 人才
|
|
36934
38125
|
*/
|
|
@@ -39273,6 +40464,31 @@ class Client$u extends Client$v {
|
|
|
39273
40464
|
});
|
|
39274
40465
|
}),
|
|
39275
40466
|
},
|
|
40467
|
+
/**
|
|
40468
|
+
* role
|
|
40469
|
+
*/
|
|
40470
|
+
role: {
|
|
40471
|
+
/**
|
|
40472
|
+
* {@link https://open.feishu.cn/api-explorer?project=hire&resource=role&apiName=get&version=v1 click to debug }
|
|
40473
|
+
*
|
|
40474
|
+
* {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=get&project=hire&resource=role&version=v1 document }
|
|
40475
|
+
*/
|
|
40476
|
+
get: (payload, options) => __awaiter(this, void 0, void 0, function* () {
|
|
40477
|
+
const { headers, params, data, path } = yield this.formatPayload(payload, options);
|
|
40478
|
+
return this.httpInstance
|
|
40479
|
+
.request({
|
|
40480
|
+
url: fillApiPath(`${this.domain}/open-apis/hire/v1/roles/:role_id`, path),
|
|
40481
|
+
method: "GET",
|
|
40482
|
+
data,
|
|
40483
|
+
params,
|
|
40484
|
+
headers,
|
|
40485
|
+
})
|
|
40486
|
+
.catch((e) => {
|
|
40487
|
+
this.logger.error(formatErrors(e));
|
|
40488
|
+
throw e;
|
|
40489
|
+
});
|
|
40490
|
+
}),
|
|
40491
|
+
},
|
|
39276
40492
|
/**
|
|
39277
40493
|
* 人才
|
|
39278
40494
|
*/
|
|
@@ -40821,7 +42037,7 @@ class Client$s extends Client$t {
|
|
|
40821
42037
|
}),
|
|
40822
42038
|
},
|
|
40823
42039
|
/**
|
|
40824
|
-
* 消息
|
|
42040
|
+
* 消息
|
|
40825
42041
|
*/
|
|
40826
42042
|
message: {
|
|
40827
42043
|
/**
|
|
@@ -42891,7 +44107,7 @@ class Client$s extends Client$t {
|
|
|
42891
44107
|
}),
|
|
42892
44108
|
},
|
|
42893
44109
|
/**
|
|
42894
|
-
* 消息
|
|
44110
|
+
* 消息
|
|
42895
44111
|
*/
|
|
42896
44112
|
message: {
|
|
42897
44113
|
/**
|