@larksuiteoapi/node-sdk 1.37.2 → 1.38.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.
Files changed (4) hide show
  1. package/es/index.js +472 -12
  2. package/lib/index.js +472 -12
  3. package/package.json +1 -1
  4. package/types/index.d.ts +14249 -2757
package/es/index.js CHANGED
@@ -236,7 +236,7 @@ const formatErrors = (e) => {
236
236
  const errors = [filteredErrorInfo];
237
237
  const specificError = get(e, 'response.data');
238
238
  if (specificError) {
239
- errors.push(specificError);
239
+ errors.push(Object.assign(Object.assign({}, specificError), (specificError.error ? specificError.error : {})));
240
240
  }
241
241
  return errors;
242
242
  }
@@ -1305,7 +1305,7 @@ class Client$_ extends Client$$ {
1305
1305
  constructor() {
1306
1306
  super(...arguments);
1307
1307
  /**
1308
- * 管理后台-企业勋章
1308
+ * 管理后台-密码
1309
1309
  */
1310
1310
  this.admin = {
1311
1311
  /**
@@ -4213,7 +4213,7 @@ class Client$X extends Client$Y {
4213
4213
  */
4214
4214
  this.approval = {
4215
4215
  /**
4216
- * 事件
4216
+ * 原生审批定义
4217
4217
  */
4218
4218
  approval: {
4219
4219
  /**
@@ -4508,7 +4508,7 @@ class Client$X extends Client$Y {
4508
4508
  }),
4509
4509
  },
4510
4510
  /**
4511
- * 原生审批实例
4511
+ * 审批查询
4512
4512
  */
4513
4513
  instance: {
4514
4514
  /**
@@ -5010,7 +5010,7 @@ class Client$X extends Client$Y {
5010
5010
  }),
5011
5011
  },
5012
5012
  /**
5013
- * 审批查询
5013
+ * 原生审批任务
5014
5014
  */
5015
5015
  task: {
5016
5016
  /**
@@ -5216,7 +5216,7 @@ class Client$X extends Client$Y {
5216
5216
  },
5217
5217
  v4: {
5218
5218
  /**
5219
- * 事件
5219
+ * 原生审批定义
5220
5220
  */
5221
5221
  approval: {
5222
5222
  /**
@@ -5513,7 +5513,7 @@ class Client$X extends Client$Y {
5513
5513
  }),
5514
5514
  },
5515
5515
  /**
5516
- * 原生审批实例
5516
+ * 审批查询
5517
5517
  */
5518
5518
  instance: {
5519
5519
  /**
@@ -6021,7 +6021,7 @@ class Client$X extends Client$Y {
6021
6021
  }),
6022
6022
  },
6023
6023
  /**
6024
- * 审批查询
6024
+ * 原生审批任务
6025
6025
  */
6026
6026
  task: {
6027
6027
  /**
@@ -23751,6 +23751,48 @@ class Client$I extends Client$J {
23751
23751
  throw e;
23752
23752
  });
23753
23753
  }),
23754
+ /**
23755
+ * {@link https://open.feishu.cn/api-explorer?project=corehr&resource=leave&apiName=work_calendar&version=v1 click to debug }
23756
+ *
23757
+ * {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=work_calendar&project=corehr&resource=leave&version=v1 document }
23758
+ */
23759
+ workCalendar: (payload, options) => __awaiter(this, void 0, void 0, function* () {
23760
+ const { headers, params, data, path } = yield this.formatPayload(payload, options);
23761
+ return this.httpInstance
23762
+ .request({
23763
+ url: fillApiPath(`${this.domain}/open-apis/corehr/v1/leaves/work_calendar`, path),
23764
+ method: "POST",
23765
+ data,
23766
+ params,
23767
+ headers,
23768
+ paramsSerializer: (params) => stringify(params, { arrayFormat: "repeat" }),
23769
+ })
23770
+ .catch((e) => {
23771
+ this.logger.error(formatErrors(e));
23772
+ throw e;
23773
+ });
23774
+ }),
23775
+ /**
23776
+ * {@link https://open.feishu.cn/api-explorer?project=corehr&resource=leave&apiName=work_calendar_date&version=v1 click to debug }
23777
+ *
23778
+ * {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=work_calendar_date&project=corehr&resource=leave&version=v1 document }
23779
+ */
23780
+ workCalendarDate: (payload, options) => __awaiter(this, void 0, void 0, function* () {
23781
+ const { headers, params, data, path } = yield this.formatPayload(payload, options);
23782
+ return this.httpInstance
23783
+ .request({
23784
+ url: fillApiPath(`${this.domain}/open-apis/corehr/v1/leaves/work_calendar_date`, path),
23785
+ method: "POST",
23786
+ data,
23787
+ params,
23788
+ headers,
23789
+ paramsSerializer: (params) => stringify(params, { arrayFormat: "repeat" }),
23790
+ })
23791
+ .catch((e) => {
23792
+ this.logger.error(formatErrors(e));
23793
+ throw e;
23794
+ });
23795
+ }),
23754
23796
  },
23755
23797
  /**
23756
23798
  * leave_granting_record
@@ -26534,6 +26576,48 @@ class Client$I extends Client$J {
26534
26576
  throw e;
26535
26577
  });
26536
26578
  }),
26579
+ /**
26580
+ * {@link https://open.feishu.cn/api-explorer?project=corehr&resource=leave&apiName=work_calendar&version=v1 click to debug }
26581
+ *
26582
+ * {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=work_calendar&project=corehr&resource=leave&version=v1 document }
26583
+ */
26584
+ workCalendar: (payload, options) => __awaiter(this, void 0, void 0, function* () {
26585
+ const { headers, params, data, path } = yield this.formatPayload(payload, options);
26586
+ return this.httpInstance
26587
+ .request({
26588
+ url: fillApiPath(`${this.domain}/open-apis/corehr/v1/leaves/work_calendar`, path),
26589
+ method: "POST",
26590
+ data,
26591
+ params,
26592
+ headers,
26593
+ paramsSerializer: (params) => stringify(params, { arrayFormat: "repeat" }),
26594
+ })
26595
+ .catch((e) => {
26596
+ this.logger.error(formatErrors(e));
26597
+ throw e;
26598
+ });
26599
+ }),
26600
+ /**
26601
+ * {@link https://open.feishu.cn/api-explorer?project=corehr&resource=leave&apiName=work_calendar_date&version=v1 click to debug }
26602
+ *
26603
+ * {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=work_calendar_date&project=corehr&resource=leave&version=v1 document }
26604
+ */
26605
+ workCalendarDate: (payload, options) => __awaiter(this, void 0, void 0, function* () {
26606
+ const { headers, params, data, path } = yield this.formatPayload(payload, options);
26607
+ return this.httpInstance
26608
+ .request({
26609
+ url: fillApiPath(`${this.domain}/open-apis/corehr/v1/leaves/work_calendar_date`, path),
26610
+ method: "POST",
26611
+ data,
26612
+ params,
26613
+ headers,
26614
+ paramsSerializer: (params) => stringify(params, { arrayFormat: "repeat" }),
26615
+ })
26616
+ .catch((e) => {
26617
+ this.logger.error(formatErrors(e));
26618
+ throw e;
26619
+ });
26620
+ }),
26537
26621
  },
26538
26622
  /**
26539
26623
  * leave_granting_record
@@ -28124,6 +28208,84 @@ class Client$I extends Client$J {
28124
28208
  });
28125
28209
  }),
28126
28210
  },
28211
+ /**
28212
+ * basic_info.language
28213
+ */
28214
+ basicInfoLanguage: {
28215
+ searchWithIterator: (payload, options) => __awaiter(this, void 0, void 0, function* () {
28216
+ const { headers, params, data, path } = yield this.formatPayload(payload, options);
28217
+ const sendRequest = (innerPayload) => __awaiter(this, void 0, void 0, function* () {
28218
+ const res = yield this.httpInstance
28219
+ .request({
28220
+ url: fillApiPath(`${this.domain}/open-apis/corehr/v2/basic_info/languages/search`, path),
28221
+ method: "POST",
28222
+ headers: pickBy(innerPayload.headers, identity),
28223
+ params: pickBy(innerPayload.params, identity),
28224
+ data,
28225
+ paramsSerializer: (params) => stringify(params, {
28226
+ arrayFormat: "repeat",
28227
+ }),
28228
+ })
28229
+ .catch((e) => {
28230
+ this.logger.error(formatErrors(e));
28231
+ });
28232
+ return res;
28233
+ });
28234
+ const Iterable = {
28235
+ [Symbol.asyncIterator]() {
28236
+ return __asyncGenerator(this, arguments, function* _a() {
28237
+ let hasMore = true;
28238
+ let pageToken;
28239
+ while (hasMore) {
28240
+ try {
28241
+ const res = yield __await(sendRequest({
28242
+ headers,
28243
+ params: Object.assign(Object.assign({}, params), { page_token: pageToken }),
28244
+ data,
28245
+ }));
28246
+ const _b = get(res, "data") || {}, {
28247
+ // @ts-ignore
28248
+ has_more,
28249
+ // @ts-ignore
28250
+ page_token,
28251
+ // @ts-ignore
28252
+ next_page_token } = _b, rest = __rest(_b, ["has_more", "page_token", "next_page_token"]);
28253
+ yield yield __await(rest);
28254
+ hasMore = Boolean(has_more);
28255
+ pageToken = page_token || next_page_token;
28256
+ }
28257
+ catch (e) {
28258
+ yield yield __await(null);
28259
+ break;
28260
+ }
28261
+ }
28262
+ });
28263
+ },
28264
+ };
28265
+ return Iterable;
28266
+ }),
28267
+ /**
28268
+ * {@link https://open.feishu.cn/api-explorer?project=corehr&resource=basic_info.language&apiName=search&version=v2 click to debug }
28269
+ *
28270
+ * {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=search&project=corehr&resource=basic_info.language&version=v2 document }
28271
+ */
28272
+ search: (payload, options) => __awaiter(this, void 0, void 0, function* () {
28273
+ const { headers, params, data, path } = yield this.formatPayload(payload, options);
28274
+ return this.httpInstance
28275
+ .request({
28276
+ url: fillApiPath(`${this.domain}/open-apis/corehr/v2/basic_info/languages/search`, path),
28277
+ method: "POST",
28278
+ data,
28279
+ params,
28280
+ headers,
28281
+ paramsSerializer: (params) => stringify(params, { arrayFormat: "repeat" }),
28282
+ })
28283
+ .catch((e) => {
28284
+ this.logger.error(formatErrors(e));
28285
+ throw e;
28286
+ });
28287
+ }),
28288
+ },
28127
28289
  /**
28128
28290
  * basic_info.nationality
28129
28291
  */
@@ -28202,6 +28364,84 @@ class Client$I extends Client$J {
28202
28364
  });
28203
28365
  }),
28204
28366
  },
28367
+ /**
28368
+ * basic_info.time_zone
28369
+ */
28370
+ basicInfoTimeZone: {
28371
+ searchWithIterator: (payload, options) => __awaiter(this, void 0, void 0, function* () {
28372
+ const { headers, params, data, path } = yield this.formatPayload(payload, options);
28373
+ const sendRequest = (innerPayload) => __awaiter(this, void 0, void 0, function* () {
28374
+ const res = yield this.httpInstance
28375
+ .request({
28376
+ url: fillApiPath(`${this.domain}/open-apis/corehr/v2/basic_info/time_zones/search`, path),
28377
+ method: "POST",
28378
+ headers: pickBy(innerPayload.headers, identity),
28379
+ params: pickBy(innerPayload.params, identity),
28380
+ data,
28381
+ paramsSerializer: (params) => stringify(params, {
28382
+ arrayFormat: "repeat",
28383
+ }),
28384
+ })
28385
+ .catch((e) => {
28386
+ this.logger.error(formatErrors(e));
28387
+ });
28388
+ return res;
28389
+ });
28390
+ const Iterable = {
28391
+ [Symbol.asyncIterator]() {
28392
+ return __asyncGenerator(this, arguments, function* _a() {
28393
+ let hasMore = true;
28394
+ let pageToken;
28395
+ while (hasMore) {
28396
+ try {
28397
+ const res = yield __await(sendRequest({
28398
+ headers,
28399
+ params: Object.assign(Object.assign({}, params), { page_token: pageToken }),
28400
+ data,
28401
+ }));
28402
+ const _b = get(res, "data") || {}, {
28403
+ // @ts-ignore
28404
+ has_more,
28405
+ // @ts-ignore
28406
+ page_token,
28407
+ // @ts-ignore
28408
+ next_page_token } = _b, rest = __rest(_b, ["has_more", "page_token", "next_page_token"]);
28409
+ yield yield __await(rest);
28410
+ hasMore = Boolean(has_more);
28411
+ pageToken = page_token || next_page_token;
28412
+ }
28413
+ catch (e) {
28414
+ yield yield __await(null);
28415
+ break;
28416
+ }
28417
+ }
28418
+ });
28419
+ },
28420
+ };
28421
+ return Iterable;
28422
+ }),
28423
+ /**
28424
+ * {@link https://open.feishu.cn/api-explorer?project=corehr&resource=basic_info.time_zone&apiName=search&version=v2 click to debug }
28425
+ *
28426
+ * {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=search&project=corehr&resource=basic_info.time_zone&version=v2 document }
28427
+ */
28428
+ search: (payload, options) => __awaiter(this, void 0, void 0, function* () {
28429
+ const { headers, params, data, path } = yield this.formatPayload(payload, options);
28430
+ return this.httpInstance
28431
+ .request({
28432
+ url: fillApiPath(`${this.domain}/open-apis/corehr/v2/basic_info/time_zones/search`, path),
28433
+ method: "POST",
28434
+ data,
28435
+ params,
28436
+ headers,
28437
+ paramsSerializer: (params) => stringify(params, { arrayFormat: "repeat" }),
28438
+ })
28439
+ .catch((e) => {
28440
+ this.logger.error(formatErrors(e));
28441
+ throw e;
28442
+ });
28443
+ }),
28444
+ },
28205
28445
  /**
28206
28446
  * bp
28207
28447
  */
@@ -28695,6 +28935,79 @@ class Client$I extends Client$J {
28695
28935
  throw e;
28696
28936
  });
28697
28937
  }),
28938
+ queryRecentChangeWithIterator: (payload, options) => __awaiter(this, void 0, void 0, function* () {
28939
+ const { headers, params, data, path } = yield this.formatPayload(payload, options);
28940
+ const sendRequest = (innerPayload) => __awaiter(this, void 0, void 0, function* () {
28941
+ const res = yield this.httpInstance
28942
+ .request({
28943
+ url: fillApiPath(`${this.domain}/open-apis/corehr/v2/departments/query_recent_change`, path),
28944
+ method: "GET",
28945
+ headers: pickBy(innerPayload.headers, identity),
28946
+ params: pickBy(innerPayload.params, identity),
28947
+ data,
28948
+ paramsSerializer: (params) => stringify(params, {
28949
+ arrayFormat: "repeat",
28950
+ }),
28951
+ })
28952
+ .catch((e) => {
28953
+ this.logger.error(formatErrors(e));
28954
+ });
28955
+ return res;
28956
+ });
28957
+ const Iterable = {
28958
+ [Symbol.asyncIterator]() {
28959
+ return __asyncGenerator(this, arguments, function* _a() {
28960
+ let hasMore = true;
28961
+ let pageToken;
28962
+ while (hasMore) {
28963
+ try {
28964
+ const res = yield __await(sendRequest({
28965
+ headers,
28966
+ params: Object.assign(Object.assign({}, params), { page_token: pageToken }),
28967
+ data,
28968
+ }));
28969
+ const _b = get(res, "data") || {}, {
28970
+ // @ts-ignore
28971
+ has_more,
28972
+ // @ts-ignore
28973
+ page_token,
28974
+ // @ts-ignore
28975
+ next_page_token } = _b, rest = __rest(_b, ["has_more", "page_token", "next_page_token"]);
28976
+ yield yield __await(rest);
28977
+ hasMore = Boolean(has_more);
28978
+ pageToken = page_token || next_page_token;
28979
+ }
28980
+ catch (e) {
28981
+ yield yield __await(null);
28982
+ break;
28983
+ }
28984
+ }
28985
+ });
28986
+ },
28987
+ };
28988
+ return Iterable;
28989
+ }),
28990
+ /**
28991
+ * {@link https://open.feishu.cn/api-explorer?project=corehr&resource=department&apiName=query_recent_change&version=v2 click to debug }
28992
+ *
28993
+ * {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=query_recent_change&project=corehr&resource=department&version=v2 document }
28994
+ */
28995
+ queryRecentChange: (payload, options) => __awaiter(this, void 0, void 0, function* () {
28996
+ const { headers, params, data, path } = yield this.formatPayload(payload, options);
28997
+ return this.httpInstance
28998
+ .request({
28999
+ url: fillApiPath(`${this.domain}/open-apis/corehr/v2/departments/query_recent_change`, path),
29000
+ method: "GET",
29001
+ data,
29002
+ params,
29003
+ headers,
29004
+ paramsSerializer: (params) => stringify(params, { arrayFormat: "repeat" }),
29005
+ })
29006
+ .catch((e) => {
29007
+ this.logger.error(formatErrors(e));
29008
+ throw e;
29009
+ });
29010
+ }),
28698
29011
  /**
28699
29012
  * {@link https://open.feishu.cn/api-explorer?project=corehr&resource=department&apiName=query_timeline&version=v2 click to debug }
28700
29013
  *
@@ -29175,6 +29488,75 @@ class Client$I extends Client$J {
29175
29488
  * job_grade
29176
29489
  */
29177
29490
  jobGrade: {
29491
+ /**
29492
+ * {@link https://open.feishu.cn/api-explorer?project=corehr&resource=job_grade&apiName=create&version=v2 click to debug }
29493
+ *
29494
+ * {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=create&project=corehr&resource=job_grade&version=v2 document }
29495
+ *
29496
+ * 创建职等数据
29497
+ */
29498
+ create: (payload, options) => __awaiter(this, void 0, void 0, function* () {
29499
+ const { headers, params, data, path } = yield this.formatPayload(payload, options);
29500
+ return this.httpInstance
29501
+ .request({
29502
+ url: fillApiPath(`${this.domain}/open-apis/corehr/v2/job_grades`, path),
29503
+ method: "POST",
29504
+ data,
29505
+ params,
29506
+ headers,
29507
+ paramsSerializer: (params) => stringify(params, { arrayFormat: "repeat" }),
29508
+ })
29509
+ .catch((e) => {
29510
+ this.logger.error(formatErrors(e));
29511
+ throw e;
29512
+ });
29513
+ }),
29514
+ /**
29515
+ * {@link https://open.feishu.cn/api-explorer?project=corehr&resource=job_grade&apiName=delete&version=v2 click to debug }
29516
+ *
29517
+ * {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=delete&project=corehr&resource=job_grade&version=v2 document }
29518
+ *
29519
+ * 删除职等信息
29520
+ */
29521
+ delete: (payload, options) => __awaiter(this, void 0, void 0, function* () {
29522
+ const { headers, params, data, path } = yield this.formatPayload(payload, options);
29523
+ return this.httpInstance
29524
+ .request({
29525
+ url: fillApiPath(`${this.domain}/open-apis/corehr/v2/job_grades/:job_grade_id`, path),
29526
+ method: "DELETE",
29527
+ data,
29528
+ params,
29529
+ headers,
29530
+ paramsSerializer: (params) => stringify(params, { arrayFormat: "repeat" }),
29531
+ })
29532
+ .catch((e) => {
29533
+ this.logger.error(formatErrors(e));
29534
+ throw e;
29535
+ });
29536
+ }),
29537
+ /**
29538
+ * {@link https://open.feishu.cn/api-explorer?project=corehr&resource=job_grade&apiName=patch&version=v2 click to debug }
29539
+ *
29540
+ * {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=patch&project=corehr&resource=job_grade&version=v2 document }
29541
+ *
29542
+ * 更新职等信息
29543
+ */
29544
+ patch: (payload, options) => __awaiter(this, void 0, void 0, function* () {
29545
+ const { headers, params, data, path } = yield this.formatPayload(payload, options);
29546
+ return this.httpInstance
29547
+ .request({
29548
+ url: fillApiPath(`${this.domain}/open-apis/corehr/v2/job_grades/:job_grade_id`, path),
29549
+ method: "PATCH",
29550
+ data,
29551
+ params,
29552
+ headers,
29553
+ paramsSerializer: (params) => stringify(params, { arrayFormat: "repeat" }),
29554
+ })
29555
+ .catch((e) => {
29556
+ this.logger.error(formatErrors(e));
29557
+ throw e;
29558
+ });
29559
+ }),
29178
29560
  /**
29179
29561
  * {@link https://open.feishu.cn/api-explorer?project=corehr&resource=job_grade&apiName=query&version=v2 click to debug }
29180
29562
  *
@@ -29936,6 +30318,32 @@ class Client$I extends Client$J {
29936
30318
  });
29937
30319
  }),
29938
30320
  },
30321
+ /**
30322
+ * workforce_plan_detail
30323
+ */
30324
+ workforcePlanDetail: {
30325
+ /**
30326
+ * {@link https://open.feishu.cn/api-explorer?project=corehr&resource=workforce_plan_detail&apiName=batch&version=v2 click to debug }
30327
+ *
30328
+ * {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=batch&project=corehr&resource=workforce_plan_detail&version=v2 document }
30329
+ */
30330
+ batch: (payload, options) => __awaiter(this, void 0, void 0, function* () {
30331
+ const { headers, params, data, path } = yield this.formatPayload(payload, options);
30332
+ return this.httpInstance
30333
+ .request({
30334
+ url: fillApiPath(`${this.domain}/open-apis/corehr/v2/workforce_plan_details/batch`, path),
30335
+ method: "POST",
30336
+ data,
30337
+ params,
30338
+ headers,
30339
+ paramsSerializer: (params) => stringify(params, { arrayFormat: "repeat" }),
30340
+ })
30341
+ .catch((e) => {
30342
+ this.logger.error(formatErrors(e));
30343
+ throw e;
30344
+ });
30345
+ }),
30346
+ },
29939
30347
  },
29940
30348
  };
29941
30349
  }
@@ -30773,6 +31181,32 @@ class Client$F extends Client$G {
30773
31181
  });
30774
31182
  }),
30775
31183
  },
31184
+ /**
31185
+ * document.block.descendant
31186
+ */
31187
+ documentBlockDescendant: {
31188
+ /**
31189
+ * {@link https://open.feishu.cn/api-explorer?project=docx&resource=document.block.descendant&apiName=create&version=v1 click to debug }
31190
+ *
31191
+ * {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=create&project=docx&resource=document.block.descendant&version=v1 document }
31192
+ */
31193
+ create: (payload, options) => __awaiter(this, void 0, void 0, function* () {
31194
+ const { headers, params, data, path } = yield this.formatPayload(payload, options);
31195
+ return this.httpInstance
31196
+ .request({
31197
+ url: fillApiPath(`${this.domain}/open-apis/docx/v1/documents/:document_id/blocks/:block_id/descendant`, path),
31198
+ method: "POST",
31199
+ data,
31200
+ params,
31201
+ headers,
31202
+ paramsSerializer: (params) => stringify(params, { arrayFormat: "repeat" }),
31203
+ })
31204
+ .catch((e) => {
31205
+ this.logger.error(formatErrors(e));
31206
+ throw e;
31207
+ });
31208
+ }),
31209
+ },
30776
31210
  /**
30777
31211
  * 文档
30778
31212
  */
@@ -31183,6 +31617,32 @@ class Client$F extends Client$G {
31183
31617
  });
31184
31618
  }),
31185
31619
  },
31620
+ /**
31621
+ * document.block.descendant
31622
+ */
31623
+ documentBlockDescendant: {
31624
+ /**
31625
+ * {@link https://open.feishu.cn/api-explorer?project=docx&resource=document.block.descendant&apiName=create&version=v1 click to debug }
31626
+ *
31627
+ * {@link https://open.feishu.cn/api-explorer?from=op_doc_tab&apiName=create&project=docx&resource=document.block.descendant&version=v1 document }
31628
+ */
31629
+ create: (payload, options) => __awaiter(this, void 0, void 0, function* () {
31630
+ const { headers, params, data, path } = yield this.formatPayload(payload, options);
31631
+ return this.httpInstance
31632
+ .request({
31633
+ url: fillApiPath(`${this.domain}/open-apis/docx/v1/documents/:document_id/blocks/:block_id/descendant`, path),
31634
+ method: "POST",
31635
+ data,
31636
+ params,
31637
+ headers,
31638
+ paramsSerializer: (params) => stringify(params, { arrayFormat: "repeat" }),
31639
+ })
31640
+ .catch((e) => {
31641
+ this.logger.error(formatErrors(e));
31642
+ throw e;
31643
+ });
31644
+ }),
31645
+ },
31186
31646
  /**
31187
31647
  * 文档
31188
31648
  */
@@ -31706,7 +32166,7 @@ class Client$E extends Client$F {
31706
32166
  }),
31707
32167
  },
31708
32168
  /**
31709
- * 上传
32169
+ * 事件
31710
32170
  */
31711
32171
  file: {
31712
32172
  /**
@@ -32579,7 +33039,7 @@ class Client$E extends Client$F {
32579
33039
  }),
32580
33040
  },
32581
33041
  /**
32582
- * 素材
33042
+ * 分片上传
32583
33043
  */
32584
33044
  media: {
32585
33045
  /**
@@ -33526,7 +33986,7 @@ class Client$E extends Client$F {
33526
33986
  }),
33527
33987
  },
33528
33988
  /**
33529
- * 上传
33989
+ * 事件
33530
33990
  */
33531
33991
  file: {
33532
33992
  /**
@@ -34405,7 +34865,7 @@ class Client$E extends Client$F {
34405
34865
  }),
34406
34866
  },
34407
34867
  /**
34408
- * 素材
34868
+ * 分片上传
34409
34869
  */
34410
34870
  media: {
34411
34871
  /**