@satorijs/adapter-lark 3.9.1 → 3.9.3

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 (82) hide show
  1. package/lib/index.cjs +1078 -14
  2. package/lib/types/acs.d.ts +19 -19
  3. package/lib/types/admin.d.ts +58 -32
  4. package/lib/types/aily.d.ts +52 -52
  5. package/lib/types/apaas.d.ts +96 -96
  6. package/lib/types/application.d.ts +151 -67
  7. package/lib/types/approval.d.ts +182 -150
  8. package/lib/types/attendance.d.ts +395 -353
  9. package/lib/types/auth.d.ts +18 -18
  10. package/lib/types/authen.d.ts +24 -24
  11. package/lib/types/baike.d.ts +42 -42
  12. package/lib/types/bitable.d.ts +268 -184
  13. package/lib/types/calendar.d.ts +144 -144
  14. package/lib/types/cardkit.d.ts +8 -8
  15. package/lib/types/contact.d.ts +209 -137
  16. package/lib/types/corehr.d.ts +760 -620
  17. package/lib/types/document_ai.d.ts +68 -68
  18. package/lib/types/docx.d.ts +103 -95
  19. package/lib/types/drive.d.ts +236 -236
  20. package/lib/types/ehr.d.ts +26 -2
  21. package/lib/types/helpdesk.d.ts +155 -155
  22. package/lib/types/hire.d.ts +954 -510
  23. package/lib/types/im.d.ts +446 -446
  24. package/lib/types/index.d.ts +72 -30
  25. package/lib/types/lingo.d.ts +28 -28
  26. package/lib/types/mail.d.ts +192 -192
  27. package/lib/types/minutes.d.ts +4 -4
  28. package/lib/types/okr.d.ts +86 -58
  29. package/lib/types/passport.d.ts +13 -5
  30. package/lib/types/payroll.d.ts +13 -5
  31. package/lib/types/performance.d.ts +85 -79
  32. package/lib/types/personal_settings.d.ts +12 -12
  33. package/lib/types/report.d.ts +11 -5
  34. package/lib/types/search.d.ts +48 -24
  35. package/lib/types/sheets.d.ts +64 -64
  36. package/lib/types/speech_to_text.d.ts +4 -4
  37. package/lib/types/task.d.ts +191 -185
  38. package/lib/types/translation.d.ts +4 -4
  39. package/lib/types/vc.d.ts +335 -155
  40. package/lib/types/wiki.d.ts +48 -48
  41. package/package.json +1 -1
  42. package/src/internal.ts +1 -1
  43. package/src/types/acs.ts +24 -24
  44. package/src/types/admin.ts +69 -39
  45. package/src/types/aily.ts +61 -61
  46. package/src/types/apaas.ts +113 -113
  47. package/src/types/application.ts +173 -79
  48. package/src/types/approval.ts +202 -166
  49. package/src/types/attendance.ts +466 -421
  50. package/src/types/auth.ts +20 -20
  51. package/src/types/authen.ts +28 -28
  52. package/src/types/baike.ts +55 -55
  53. package/src/types/bitable.ts +305 -219
  54. package/src/types/calendar.ts +167 -167
  55. package/src/types/cardkit.ts +10 -10
  56. package/src/types/contact.ts +251 -169
  57. package/src/types/corehr.ts +903 -743
  58. package/src/types/document_ai.ts +85 -85
  59. package/src/types/docx.ts +117 -108
  60. package/src/types/drive.ts +298 -298
  61. package/src/types/ehr.ts +28 -2
  62. package/src/types/helpdesk.ts +181 -181
  63. package/src/types/hire.ts +1081 -591
  64. package/src/types/im.ts +521 -521
  65. package/src/types/index.ts +73 -30
  66. package/src/types/lingo.ts +36 -36
  67. package/src/types/mail.ts +215 -215
  68. package/src/types/minutes.ts +5 -5
  69. package/src/types/okr.ts +98 -66
  70. package/src/types/passport.ts +15 -6
  71. package/src/types/payroll.ts +15 -6
  72. package/src/types/performance.ts +98 -91
  73. package/src/types/personal_settings.ts +15 -15
  74. package/src/types/report.ts +13 -6
  75. package/src/types/search.ts +57 -29
  76. package/src/types/sheets.ts +80 -80
  77. package/src/types/speech_to_text.ts +5 -5
  78. package/src/types/task.ts +238 -231
  79. package/src/types/translation.ts +5 -5
  80. package/src/types/vc.ts +386 -186
  81. package/src/types/wiki.ts +59 -59
  82. package/src/utils.ts +12 -7
@@ -699,7 +699,18 @@ export interface AilyMessage {
699
699
  /** 状态 */
700
700
  status?: AilyMessageStatus;
701
701
  }
702
- export type AilyMessageContentType = 'MDX' | 'TEXT' | 'CLIP' | 'SmartCard' | 'JSON';
702
+ export declare const enum AilyMessageContentType {
703
+ /** MDX */
704
+ ContentTypeMDX = "MDX",
705
+ /** TEXT */
706
+ ContentTypeText = "TEXT",
707
+ /** GUI 卡片 */
708
+ ContentTypeClip = "CLIP",
709
+ /** SmartCard */
710
+ ContentTypeSmartCard = "SmartCard",
711
+ /** JSON */
712
+ ContentTypeJSON = "JSON"
713
+ }
703
714
  export interface AilyMessageFile {
704
715
  /** 文件 ID */
705
716
  id?: string;
@@ -720,7 +731,12 @@ export interface AilyMessageFilePreview {
720
731
  /** url 过期时间,秒时间戳 */
721
732
  expired_at?: string;
722
733
  }
723
- export type AilyMessageStatus = 'IN_PROGRESS' | 'COMPLETED';
734
+ export declare const enum AilyMessageStatus {
735
+ /** 生成中 */
736
+ MessageStatusInProgress = "IN_PROGRESS",
737
+ /** 已完成 */
738
+ MessageStatusCompleted = "COMPLETED"
739
+ }
724
740
  export interface AilySender {
725
741
  /** 实体 ID */
726
742
  entity_id?: string;
@@ -731,7 +747,12 @@ export interface AilySender {
731
747
  /** Aily 账号体系下的 ID */
732
748
  aily_id?: string;
733
749
  }
734
- export type AilySenderType = 'USER' | 'ASSISTANT';
750
+ export declare const enum AilySenderType {
751
+ /** 用户 */
752
+ SenderTypeUser = "USER",
753
+ /** 应用 */
754
+ SenderTypeAssistant = "ASSISTANT"
755
+ }
735
756
  export interface AilySession {
736
757
  /** 会话 ID */
737
758
  id: string;
@@ -1387,7 +1408,7 @@ export interface AppRoleTableRole {
1387
1408
  /** 记录筛选条件,在table_perm为1或2时有意义,用于指定可编辑或可阅读某些记录 */
1388
1409
  rec_rule?: AppRoleTableRoleRecRule;
1389
1410
  /** 字段权限,仅在table_perm为2时有意义,设置字段可编辑或可阅读 */
1390
- field_perm?: unknown;
1411
+ field_perm?: Record<string, number>;
1391
1412
  /** 新增记录权限,仅在table_perm为2时有意义,用于设置记录是否可以新增 */
1392
1413
  allow_add_record?: boolean;
1393
1414
  /** 删除记录权限,仅在table_perm为2时有意义,用于设置记录是否可以删除 */
@@ -1773,17 +1794,17 @@ export interface AppTableFormPatchedField {
1773
1794
  }
1774
1795
  export interface AppTableRecord {
1775
1796
  /** 记录字段 */
1776
- fields: unknown;
1797
+ fields: Record<string, unknown>;
1777
1798
  /** 记录Id */
1778
1799
  record_id?: string;
1779
1800
  /** 创建人 */
1780
1801
  created_by?: Person;
1781
1802
  /** 创建时间 */
1782
- created_time?: unknown;
1803
+ created_time?: number;
1783
1804
  /** 修改人 */
1784
1805
  last_modified_by?: Person;
1785
1806
  /** 最近更新时间 */
1786
- last_modified_time?: unknown;
1807
+ last_modified_time?: number;
1787
1808
  /** 记录分享链接(批量获取记录接口将返回该字段) */
1788
1809
  shared_url?: string;
1789
1810
  /** 记录链接(检索记录接口将返回该字段) */
@@ -3967,7 +3988,7 @@ export interface Contract {
3967
3988
  signing_times?: number;
3968
3989
  }
3969
3990
  export interface ContractCompany {
3970
- id?: unknown;
3991
+ id?: number;
3971
3992
  name?: string;
3972
3993
  }
3973
3994
  export interface ContractPeriodInfo {
@@ -4349,9 +4370,9 @@ export interface DataAsset {
4349
4370
  /** 数据知识ID */
4350
4371
  data_asset_id?: string;
4351
4372
  /** 数据知识标题 */
4352
- label?: unknown;
4373
+ label?: Record<string, string>;
4353
4374
  /** 数据知识描述 */
4354
- description?: unknown;
4375
+ description?: Record<string, string>;
4355
4376
  /** 数据资源类型 */
4356
4377
  data_source_type?: 'excel' | 'pdf' | 'pptx' | 'txt' | 'docx' | 'mysql' | 'postgresql' | 'larkbase' | 'salesforce' | 'fenxiangxiaoke' | 'qianchuan' | 'clickhouse' | 'databricks' | 'servicedesk' | 'larkbiz_wiki' | 'larkbiz_doc' | 'larkbiz_docs' | 'larkbiz_docx' | 'larkbiz_pdf' | 'larkbiz_word' | 'larkbiz_pptx' | 'larkbiz_sheets' | 'larkbiz_base' | 'larkbiz_personalfolder' | 'larkbiz_sharedfolder' | 'object';
4357
4378
  /** 数据连接状态 */
@@ -4375,9 +4396,9 @@ export interface DataAssetItem {
4375
4396
  /** 数据知识项标识 */
4376
4397
  api_name?: string;
4377
4398
  /** 数据知识项标题 */
4378
- label?: unknown;
4399
+ label?: Record<string, string>;
4379
4400
  /** 数据知识项描述 */
4380
- description?: unknown;
4401
+ description?: Record<string, string>;
4381
4402
  /** 数据知识资源 */
4382
4403
  resources?: DataAssetResource[];
4383
4404
  }
@@ -5018,7 +5039,8 @@ export interface EducationInfo {
5018
5039
  /** 自定义字段 */
5019
5040
  custom_fields?: ObjectFieldData[];
5020
5041
  }
5021
- export type EeKunlunCommonI18nI18nText = unknown;
5042
+ export type EeKunlunCommonI18nI18nText = Record<EeKunlunCommonI18nLanguageCode, string>;
5043
+ export type EeKunlunCommonI18nLanguageCode = string;
5022
5044
  export interface Email {
5023
5045
  /** 邮箱地址 */
5024
5046
  email: string;
@@ -6708,7 +6730,12 @@ export interface IdEntity {
6708
6730
  /** 识别出字段的文本信息 */
6709
6731
  value?: string;
6710
6732
  }
6711
- export type IdentityProvider = 'AILY' | 'FEISHU';
6733
+ export declare const enum IdentityProvider {
6734
+ /** Aily 账号体系 */
6735
+ IdentityProviderAily = "AILY",
6736
+ /** 飞书账号体系 */
6737
+ IdentityProviderFeishu = "FEISHU"
6738
+ }
6712
6739
  export interface IdInfo {
6713
6740
  /** 传入的 ID */
6714
6741
  id?: string;
@@ -7465,7 +7492,7 @@ export interface JiraIssue {
7465
7492
  key?: string;
7466
7493
  }
7467
7494
  export interface Job {
7468
- id?: unknown;
7495
+ id?: number;
7469
7496
  name?: string;
7470
7497
  }
7471
7498
  export interface JobBasicInfo {
@@ -10272,7 +10299,7 @@ export interface OpenAppFeedCardButton {
10272
10299
  /** 按钮类型 */
10273
10300
  button_type?: 'default' | 'primary' | 'success';
10274
10301
  /** action 字典 */
10275
- action_map?: unknown;
10302
+ action_map?: Record<string, string>;
10276
10303
  }
10277
10304
  export interface OpenAppFeedCardButtons {
10278
10305
  /** 按钮组合 */
@@ -13148,7 +13175,22 @@ export interface RunError {
13148
13175
  /** 错误信息 */
13149
13176
  message: string;
13150
13177
  }
13151
- export type RunStatus = 'QUEUED' | 'IN_PROGRESS' | 'REQUIRES_MESSAGE' | 'CANCELLED' | 'COMPLETED' | 'FAILED' | 'EXPIRED';
13178
+ export declare const enum RunStatus {
13179
+ /** 排队中 */
13180
+ RunStatusQueued = "QUEUED",
13181
+ /** 执行中 */
13182
+ RunStatusInProgress = "IN_PROGRESS",
13183
+ /** 等待补充消息输入 */
13184
+ RunStatusRequiresMessage = "REQUIRES_MESSAGE",
13185
+ /** 已取消 */
13186
+ RunStatusCancelled = "CANCELLED",
13187
+ /** 已完成 */
13188
+ RunStatusCompleted = "COMPLETED",
13189
+ /** 已失败 */
13190
+ RunStatusFailed = "FAILED",
13191
+ /** 已过期 */
13192
+ RunStatusExpired = "EXPIRED"
13193
+ }
13152
13194
  export interface Schema {
13153
13195
  /** UI项名称 TODO文档 */
13154
13196
  ui_name?: string;
@@ -13852,9 +13894,9 @@ export interface SystemFields {
13852
13894
  /** 入职登记表状态 */
13853
13895
  employee_form_status?: 1 | 2 | 3;
13854
13896
  /** 创建时间 */
13855
- create_time?: unknown;
13897
+ create_time?: number;
13856
13898
  /** 更新时间 */
13857
- update_time?: unknown;
13899
+ update_time?: number;
13858
13900
  }
13859
13901
  export interface SystemStatus {
13860
13902
  /** 系统状态ID */
@@ -14854,11 +14896,11 @@ export interface Ticket {
14854
14896
  /** ticket score */
14855
14897
  score?: number;
14856
14898
  /** the time when the ticket is created */
14857
- created_at?: unknown;
14899
+ created_at?: number;
14858
14900
  /** the time when the ticket is updated */
14859
- updated_at?: unknown;
14901
+ updated_at?: number;
14860
14902
  /** the time when the ticket is closed */
14861
- closed_at?: unknown;
14903
+ closed_at?: number;
14862
14904
  /** 不满意原因 */
14863
14905
  dissatisfaction_reason?: I18n;
14864
14906
  /** agents of this ticket */
@@ -14876,19 +14918,19 @@ export interface Ticket {
14876
14918
  /** 客服服务时长,客服最后一次回复时间距离客服进入时间间隔,单位秒 */
14877
14919
  agent_service_duration?: number;
14878
14920
  /** 客服首次回复时间距离客服进入时间的间隔,单位秒 */
14879
- agent_first_response_duration?: unknown;
14921
+ agent_first_response_duration?: number;
14880
14922
  /** 机器人服务时间:客服进入时间距离工单创建时间的间隔,单位秒 */
14881
- bot_service_duration?: unknown;
14923
+ bot_service_duration?: number;
14882
14924
  /** 客服解决时长,关单时间距离客服进入时间的间隔,单位秒 */
14883
- agent_resolution_time?: unknown;
14925
+ agent_resolution_time?: number;
14884
14926
  /** 工单实际处理时间:从客服进入到关单,单位秒 */
14885
- actual_processing_time?: unknown;
14927
+ actual_processing_time?: number;
14886
14928
  /** 客服进入时间,单位毫秒 */
14887
- agent_entry_time?: unknown;
14929
+ agent_entry_time?: number;
14888
14930
  /** 客服首次回复时间,单位毫秒 */
14889
- agent_first_response_time?: unknown;
14931
+ agent_first_response_time?: number;
14890
14932
  /** 客服最后回复时间,单位毫秒 */
14891
- agent_last_response_time?: unknown;
14933
+ agent_last_response_time?: number;
14892
14934
  /** 主责客服 */
14893
14935
  agent_owner?: TicketUser;
14894
14936
  }
@@ -16404,7 +16446,7 @@ export interface WorkingHoursType {
16404
16446
  custom_fields?: ObjectFieldData[];
16405
16447
  }
16406
16448
  export interface WorkLocation {
16407
- id?: unknown;
16449
+ id?: number;
16408
16450
  name?: string;
16409
16451
  }
16410
16452
  export interface WorkplaceAccessData {
@@ -98,6 +98,9 @@ export interface CreateLingoDraftQuery {
98
98
  /** 此次调用中使用的用户ID的类型 */
99
99
  user_id_type?: 'user_id' | 'union_id' | 'open_id';
100
100
  }
101
+ export interface CreateLingoDraftResponse {
102
+ draft?: Draft;
103
+ }
101
104
  export interface UpdateLingoDraftRequest {
102
105
  /** 实体词 Id */
103
106
  id?: string;
@@ -118,6 +121,9 @@ export interface UpdateLingoDraftQuery {
118
121
  /** 此次调用中使用的用户ID的类型 */
119
122
  user_id_type?: 'user_id' | 'union_id' | 'open_id';
120
123
  }
124
+ export interface UpdateLingoDraftResponse {
125
+ draft?: Draft;
126
+ }
121
127
  export interface CreateLingoEntityRequest {
122
128
  /** 词条名 */
123
129
  main_keys: Term[];
@@ -140,6 +146,9 @@ export interface CreateLingoEntityQuery {
140
146
  /** 此次调用中使用的用户ID的类型 */
141
147
  user_id_type?: 'user_id' | 'union_id' | 'open_id';
142
148
  }
149
+ export interface CreateLingoEntityResponse {
150
+ entity?: Entity;
151
+ }
143
152
  export interface UpdateLingoEntityRequest {
144
153
  /** 词条名 */
145
154
  main_keys: Term[];
@@ -160,6 +169,9 @@ export interface UpdateLingoEntityQuery {
160
169
  /** 此次调用中使用的用户ID的类型 */
161
170
  user_id_type?: 'user_id' | 'union_id' | 'open_id';
162
171
  }
172
+ export interface UpdateLingoEntityResponse {
173
+ entity?: Entity;
174
+ }
163
175
  export interface DeleteLingoEntityQuery {
164
176
  /** 数据提供方(使用时需要将路径中的词条 ID 固定为:enterprise_0,且提供 provider 和 outer_id) */
165
177
  provider?: string;
@@ -174,6 +186,10 @@ export interface GetLingoEntityQuery {
174
186
  /** 此次调用中使用的用户ID的类型 */
175
187
  user_id_type?: 'user_id' | 'union_id' | 'open_id';
176
188
  }
189
+ export interface GetLingoEntityResponse {
190
+ /** 实体词 */
191
+ entity?: Entity;
192
+ }
177
193
  export interface ListLingoEntityQuery extends Pagination {
178
194
  /** 数据提供方【可用来过滤数据】 */
179
195
  provider?: string;
@@ -190,6 +206,10 @@ export interface MatchLingoEntityQuery {
190
206
  /** 词库ID */
191
207
  repo_id?: string;
192
208
  }
209
+ export interface MatchLingoEntityResponse {
210
+ /** 匹配结果 */
211
+ results?: MatchInfo[];
212
+ }
193
213
  export interface SearchLingoEntityRequest {
194
214
  /** 搜索关键词 */
195
215
  query?: string;
@@ -210,44 +230,24 @@ export interface HighlightLingoEntityRequest {
210
230
  /** 需要被识别实体词内容的一句话(不要超过1000字) */
211
231
  text: string;
212
232
  }
233
+ export interface HighlightLingoEntityResponse {
234
+ /** 返回识别到的实体词信息 */
235
+ phrases?: Phrase[];
236
+ }
213
237
  export interface ListLingoClassificationQuery extends Pagination {
214
238
  /** 词库ID */
215
239
  repo_id?: string;
216
240
  }
241
+ export interface ListLingoRepoResponse {
242
+ /** 词库列表 */
243
+ items?: Repo[];
244
+ }
217
245
  export interface UploadLingoFileForm {
218
246
  /** 文件名称,当前仅支持上传图片且图片格式为以下六种:icon、bmp、gif、png、jpeg、webp */
219
247
  name: string;
220
248
  /** 二进制文件内容,高宽像素在 320-4096 像素之间,大小在 3KB-10MB 的图片 */
221
249
  file: Blob;
222
250
  }
223
- export interface CreateLingoDraftResponse {
224
- draft?: Draft;
225
- }
226
- export interface UpdateLingoDraftResponse {
227
- draft?: Draft;
228
- }
229
- export interface CreateLingoEntityResponse {
230
- entity?: Entity;
231
- }
232
- export interface UpdateLingoEntityResponse {
233
- entity?: Entity;
234
- }
235
- export interface GetLingoEntityResponse {
236
- /** 实体词 */
237
- entity?: Entity;
238
- }
239
- export interface MatchLingoEntityResponse {
240
- /** 匹配结果 */
241
- results?: MatchInfo[];
242
- }
243
- export interface HighlightLingoEntityResponse {
244
- /** 返回识别到的实体词信息 */
245
- phrases?: Phrase[];
246
- }
247
- export interface ListLingoRepoResponse {
248
- /** 词库列表 */
249
- items?: Repo[];
250
- }
251
251
  export interface UploadLingoFileResponse {
252
252
  /** 文件 token */
253
253
  file_token?: string;