@satorijs/adapter-lark 3.10.6 → 3.11.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 (116) hide show
  1. package/lib/index.cjs +2880 -2370
  2. package/lib/internal.d.ts +4 -4
  3. package/lib/types/acs.d.ts +212 -172
  4. package/lib/types/admin.d.ts +331 -291
  5. package/lib/types/aily.d.ts +331 -216
  6. package/lib/types/apaas.d.ts +646 -494
  7. package/lib/types/application.d.ts +559 -458
  8. package/lib/types/approval.d.ts +826 -791
  9. package/lib/types/attendance.d.ts +1094 -994
  10. package/lib/types/auth.d.ts +66 -61
  11. package/lib/types/authen.d.ts +221 -186
  12. package/lib/types/baike.d.ts +258 -233
  13. package/lib/types/base.d.ts +74 -0
  14. package/lib/types/bitable.d.ts +830 -770
  15. package/lib/types/board.d.ts +29 -14
  16. package/lib/types/calendar.d.ts +660 -605
  17. package/lib/types/cardkit.d.ts +149 -134
  18. package/lib/types/compensation.d.ts +84 -49
  19. package/lib/types/contact.d.ts +1279 -1204
  20. package/lib/types/corehr.d.ts +4982 -4526
  21. package/lib/types/directory.d.ts +447 -0
  22. package/lib/types/docs.d.ts +28 -18
  23. package/lib/types/document_ai.d.ts +347 -252
  24. package/lib/types/docx.d.ts +428 -383
  25. package/lib/types/drive.d.ts +1093 -1048
  26. package/lib/types/ehr.d.ts +66 -51
  27. package/lib/types/event.d.ts +16 -6
  28. package/lib/types/helpdesk.d.ts +816 -741
  29. package/lib/types/hire.d.ts +3955 -3589
  30. package/lib/types/human_authentication.d.ts +32 -22
  31. package/lib/types/im.d.ts +1420 -1295
  32. package/lib/types/index.d.ts +1422 -330
  33. package/lib/types/lingo.d.ts +279 -249
  34. package/lib/types/mail.d.ts +1032 -675
  35. package/lib/types/mdm.d.ts +105 -37
  36. package/lib/types/minutes.d.ts +73 -26
  37. package/lib/types/moments.d.ts +23 -13
  38. package/lib/types/okr.d.ts +266 -225
  39. package/lib/types/optical_char_recognition.d.ts +22 -12
  40. package/lib/types/passport.d.ts +58 -48
  41. package/lib/types/payroll.d.ts +210 -53
  42. package/lib/types/performance.d.ts +463 -414
  43. package/lib/types/personal_settings.d.ts +93 -82
  44. package/lib/types/report.d.ts +79 -58
  45. package/lib/types/search.d.ts +265 -235
  46. package/lib/types/security_and_compliance.d.ts +30 -19
  47. package/lib/types/sheets.d.ts +356 -321
  48. package/lib/types/speech_to_text.d.ts +44 -34
  49. package/lib/types/task.d.ts +998 -1087
  50. package/lib/types/tenant.d.ts +25 -15
  51. package/lib/types/translation.d.ts +42 -32
  52. package/lib/types/trust_party.d.ts +81 -0
  53. package/lib/types/vc.d.ts +1218 -1123
  54. package/lib/types/verification.d.ts +11 -6
  55. package/lib/types/wiki.d.ts +270 -235
  56. package/lib/types/workplace.d.ts +58 -38
  57. package/lib/utils.d.ts +2 -2
  58. package/package.json +4 -4
  59. package/src/bot.ts +15 -15
  60. package/src/internal.ts +29 -12
  61. package/src/message.ts +10 -10
  62. package/src/types/acs.ts +234 -186
  63. package/src/types/admin.ts +353 -305
  64. package/src/types/aily.ts +375 -233
  65. package/src/types/apaas.ts +754 -568
  66. package/src/types/application.ts +633 -507
  67. package/src/types/approval.ts +914 -872
  68. package/src/types/attendance.ts +1226 -1104
  69. package/src/types/auth.ts +72 -66
  70. package/src/types/authen.ts +233 -191
  71. package/src/types/baike.ts +276 -246
  72. package/src/types/base.ts +93 -0
  73. package/src/types/bitable.ts +966 -894
  74. package/src/types/board.ts +34 -16
  75. package/src/types/calendar.ts +751 -685
  76. package/src/types/cardkit.ts +164 -146
  77. package/src/types/compensation.ts +97 -55
  78. package/src/types/contact.ts +1465 -1375
  79. package/src/types/corehr.ts +5664 -5077
  80. package/src/types/directory.ts +569 -0
  81. package/src/types/docs.ts +31 -19
  82. package/src/types/document_ai.ts +401 -287
  83. package/src/types/docx.ts +492 -438
  84. package/src/types/drive.ts +1266 -1213
  85. package/src/types/ehr.ts +71 -53
  86. package/src/types/event.ts +19 -7
  87. package/src/types/helpdesk.ts +930 -840
  88. package/src/types/hire.ts +4453 -4019
  89. package/src/types/human_authentication.ts +35 -23
  90. package/src/types/im.ts +1626 -1476
  91. package/src/types/index.ts +1532 -346
  92. package/src/types/lingo.ts +299 -263
  93. package/src/types/mail.ts +1231 -779
  94. package/src/types/mdm.ts +122 -39
  95. package/src/types/minutes.ts +88 -28
  96. package/src/types/moments.ts +26 -14
  97. package/src/types/okr.ts +286 -238
  98. package/src/types/optical_char_recognition.ts +25 -13
  99. package/src/types/passport.ts +62 -50
  100. package/src/types/payroll.ts +254 -57
  101. package/src/types/performance.ts +528 -467
  102. package/src/types/personal_settings.ts +101 -89
  103. package/src/types/report.ts +86 -62
  104. package/src/types/search.ts +285 -249
  105. package/src/types/security_and_compliance.ts +33 -21
  106. package/src/types/sheets.ts +421 -379
  107. package/src/types/speech_to_text.ts +48 -36
  108. package/src/types/task.ts +1152 -1260
  109. package/src/types/tenant.ts +29 -17
  110. package/src/types/translation.ts +46 -34
  111. package/src/types/trust_party.ts +110 -0
  112. package/src/types/vc.ts +1397 -1283
  113. package/src/types/verification.ts +13 -7
  114. package/src/types/wiki.ts +293 -251
  115. package/src/types/workplace.ts +65 -41
  116. package/src/utils.ts +3 -3
@@ -1,58 +1,215 @@
1
- import { AcctItem, CostAllocationPlan, CostAllocationReportData, I18nContent, Paygroup } from '.';
2
- import { Pagination } from '../internal';
1
+ import * as Lark from '.';
2
+ import { Paginated, Pagination } from '../internal';
3
3
  declare module '../internal' {
4
4
  interface Internal {
5
- /**
6
- * 批量查询算薪项
7
- * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/payroll-v1/acct_item/list
8
- */
9
- listPayrollAcctItem(query?: Pagination): Paginated<AcctItem>;
10
- /**
11
- * 查询成本分摊报表汇总数据
12
- * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/payroll-v1/cost_allocation_report/list
13
- */
14
- listPayrollCostAllocationReport(query?: ListPayrollCostAllocationReportQuery): Promise<ListPayrollCostAllocationReportResponse>;
15
- /**
16
- * 批量查询成本分摊方案
17
- * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/payroll-v1/cost_allocation_plan/list
18
- */
19
- listPayrollCostAllocationPlan(query?: ListPayrollCostAllocationPlanQuery): Paginated<CostAllocationPlan>;
20
- /**
21
- * 获取薪资组基本信息
22
- * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/payroll-v1/paygroup/list
23
- */
24
- listPayrollPaygroup(query?: Pagination): Paginated<Paygroup>;
5
+ payroll: Payroll.Methods;
25
6
  }
26
7
  }
27
- export declare const enum ListPayrollCostAllocationReportQueryReportType {
28
- /** 默认 */
29
- Default = 0,
30
- /** 计提 */
31
- Accrued = 1,
32
- /** 实发 */
33
- Paid = 2
34
- }
35
- export interface ListPayrollCostAllocationReportQuery extends Pagination {
36
- /** 成本分摊方案ID */
37
- cost_allocation_plan_id: string;
38
- /** 期间 */
39
- pay_period: string;
40
- /** 报表类型 */
41
- report_type: ListPayrollCostAllocationReportQueryReportType;
42
- }
43
- export interface ListPayrollCostAllocationReportResponse {
44
- /** 期间 */
45
- pay_period?: string;
46
- /** 下一页开始 */
47
- page_token?: string;
48
- /** 是否还有更多数据 */
49
- has_more?: boolean;
50
- /** 报表名称 */
51
- cost_allocation_report_names?: I18nContent[];
52
- /** 汇总数据 */
53
- cost_allocation_report_datas?: CostAllocationReportData[];
54
- }
55
- export interface ListPayrollCostAllocationPlanQuery extends Pagination {
56
- /** 期间 */
57
- pay_period: string;
8
+ export declare namespace Payroll {
9
+ interface Methods {
10
+ paymentActivityDetail: PaymentActivityDetail.Methods;
11
+ paymentDetail: PaymentDetail.Methods;
12
+ paymentActivity: PaymentActivity.Methods;
13
+ datasourceRecord: DatasourceRecord.Methods;
14
+ datasource: Datasource.Methods;
15
+ acctItem: AcctItem.Methods;
16
+ costAllocationReport: CostAllocationReport.Methods;
17
+ costAllocationPlan: CostAllocationPlan.Methods;
18
+ paygroup: Paygroup.Methods;
19
+ }
20
+ namespace PaymentActivityDetail {
21
+ interface Methods {
22
+ /**
23
+ * 查询发薪活动明细列表
24
+ * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/payroll-v1/payment_activity_detail/list
25
+ */
26
+ list(query?: ListQuery): Promise<ListResponse>;
27
+ }
28
+ interface ListQuery {
29
+ /** 页码,第一页从 1 开始 */
30
+ page_index: number;
31
+ /** 每页大小,范围为:[1, 100] */
32
+ page_size: number;
33
+ /** 发薪活动唯一标识 */
34
+ activity_id: string;
35
+ /** 是否需要查询算薪明细的分段信息,如果不传该参数或传 false ,那么只返回发薪活动明细数据;如果该参数传了 true,那么同时返回发薪明细对应的算薪明细分段数据。 */
36
+ include_segment_data?: boolean;
37
+ /** 算薪项 ID 列表。当前参数传空时,接口会返回发薪明细中所有的算薪项;当前参数不为空时,接口只返回发薪明细中与 acct_item_ids 存在交集的算薪项。 */
38
+ acct_item_ids?: string[];
39
+ }
40
+ interface ListResponse {
41
+ /** 发薪明细列表 */
42
+ payment_activity_details?: Lark.PaymentActivityDetail[];
43
+ /** 发薪明细总数 */
44
+ total?: number;
45
+ }
46
+ }
47
+ namespace PaymentDetail {
48
+ interface Methods {
49
+ /**
50
+ * 批量查询发薪明细
51
+ * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/payroll-v1/payment_detail/query
52
+ */
53
+ query(body: QueryRequest): Promise<QueryResponse>;
54
+ }
55
+ interface QueryRequest {
56
+ /** 页码,第一页从 1 开始 */
57
+ page_index: number;
58
+ /** 每页大小,范围为:[1, 100] */
59
+ page_size: number;
60
+ /** 算薪项 ID 列表。当前参数传空时,接口会返回发薪明细中所有的算薪项;当前参数不为空时,接口只返回发薪明细中与 acct_item_ids 存在交集的算薪项。 */
61
+ acct_item_ids?: string[];
62
+ /** 员工的飞书人事雇佣 ID 列表。 */
63
+ employee_ids: string[];
64
+ /** 发薪日开始时间,格式:YYYY-MM-dd,[pay_period_start_date, pay_period_end_date] 是一个左闭右闭区间。 */
65
+ pay_period_start_date?: string;
66
+ /** 发薪日结束时间,格式:YYYY-MM-dd,[pay_period_start_date, pay_period_end_date] 是一个左闭右闭区间,pay_period_start_date 不得晚于 pay_period_end_date ,且 [pay_period_start_date, pay_period_end_date] 最大间隔为 12 个月。 */
67
+ pay_period_end_date?: string;
68
+ /** 发薪活动 ID 列表 */
69
+ activity_ids?: string[];
70
+ /** 是否需要查询算薪明细的分段信息,如果不传该参数或传 false ,那么只返回发薪活动明细数据;如果该参数传了 true,那么同时返回发薪明细对应的算薪明细分段数据。 */
71
+ include_segment_data?: boolean;
72
+ }
73
+ interface QueryResponse {
74
+ /** 发薪明细列表 */
75
+ payment_details?: Lark.PaymentDetail[];
76
+ /** 发薪明细总数 */
77
+ total?: number;
78
+ }
79
+ }
80
+ namespace PaymentActivity {
81
+ interface Methods {
82
+ /**
83
+ * 封存发薪活动
84
+ * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/payroll-v1/payment_activity/archive
85
+ */
86
+ archive(body: ArchiveRequest): Promise<void>;
87
+ /**
88
+ * 查询发薪活动列表
89
+ * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/payroll-v1/payment_activity/list
90
+ */
91
+ list(query?: ListQuery): Paginated<Lark.PaymentActivity, 'payment_activitys'>;
92
+ }
93
+ interface ArchiveRequest {
94
+ /** 发薪活动ID */
95
+ activity_id: string;
96
+ }
97
+ interface ListQuery extends Pagination {
98
+ /** 发薪日开始时间,格式:YYYY-MM-dd,[pay_period_start_date, pay_period_end_date] 是一个左闭右闭区间。 */
99
+ pay_period_start_date: string;
100
+ /** 发薪日结束时间,格式:YYYY-MM-dd,[pay_period_start_date, pay_period_end_date] 是一个左闭右闭区间。 */
101
+ pay_period_end_date: string;
102
+ /** 发薪活动审批状态列表,其中:100-待确认发薪名单;150-待提交审批;200-审批中;300-审批被拒绝;350-审批被撤回;360-审批被撤销;375-审批通过;400-已封存。 */
103
+ statuses?: number[];
104
+ }
105
+ }
106
+ namespace DatasourceRecord {
107
+ interface Methods {
108
+ /**
109
+ * 创建 / 更新外部算薪数据
110
+ * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/payroll-v1/datasource_record/save
111
+ */
112
+ save(body: SaveRequest): Promise<SaveResponse>;
113
+ /**
114
+ * 批量查询外部算薪数据记录
115
+ * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/payroll-v1/datasource_record/query
116
+ */
117
+ query(body: QueryRequest, query?: Pagination): Paginated<Lark.DatasourceRecord, 'records'>;
118
+ }
119
+ interface SaveRequest {
120
+ /** 数据源code */
121
+ source_code: string;
122
+ /** 需保存的记录列表 */
123
+ records: Lark.DatasourceRecord[];
124
+ }
125
+ interface SaveResponse {
126
+ /** 更新的记录条数 */
127
+ affect_counts: string;
128
+ }
129
+ interface QueryRequest {
130
+ /** 数据源编码 */
131
+ source_code: string;
132
+ /** 指定查询的数据源字段。如不传,默认返回所有数据源字段 */
133
+ selected_fields?: string[];
134
+ /** 查询过滤器列表,多个过滤器之间为And关系。本期员工月维度汇总类型数据源,只支持employment_id、payroll_period fieldKey的查询,其中payroll_period必传 */
135
+ field_filters?: Lark.DatasourceRecordFieldFilter[];
136
+ }
137
+ }
138
+ namespace Datasource {
139
+ interface Methods {
140
+ /**
141
+ * 获取外部数据源配置信息
142
+ * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/payroll-v1/datasource/list
143
+ */
144
+ list(query?: Pagination): Paginated<Lark.Datasource, 'datasources'>;
145
+ }
146
+ }
147
+ namespace AcctItem {
148
+ interface Methods {
149
+ /**
150
+ * 批量查询算薪项
151
+ * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/payroll-v1/acct_item/list
152
+ */
153
+ list(query?: Pagination): Paginated<Lark.AcctItem>;
154
+ }
155
+ }
156
+ namespace CostAllocationReport {
157
+ interface Methods {
158
+ /**
159
+ * 查询成本分摊报表汇总数据
160
+ * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/payroll-v1/cost_allocation_report/list
161
+ */
162
+ list(query?: ListQuery): Promise<ListResponse>;
163
+ }
164
+ const enum ListQueryReportType {
165
+ /** 默认 */
166
+ Default = 0,
167
+ /** 计提 */
168
+ Accrued = 1,
169
+ /** 实发 */
170
+ Paid = 2
171
+ }
172
+ interface ListQuery extends Pagination {
173
+ /** 成本分摊方案ID */
174
+ cost_allocation_plan_id: string;
175
+ /** 期间 */
176
+ pay_period: string;
177
+ /** 报表类型 */
178
+ report_type: ListQueryReportType;
179
+ }
180
+ interface ListResponse {
181
+ /** 期间 */
182
+ pay_period?: string;
183
+ /** 下一页开始 */
184
+ page_token?: string;
185
+ /** 是否还有更多数据 */
186
+ has_more?: boolean;
187
+ /** 报表名称 */
188
+ cost_allocation_report_names?: Lark.I18nContent[];
189
+ /** 汇总数据 */
190
+ cost_allocation_report_datas?: Lark.CostAllocationReportData[];
191
+ }
192
+ }
193
+ namespace CostAllocationPlan {
194
+ interface Methods {
195
+ /**
196
+ * 批量查询成本分摊方案
197
+ * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/payroll-v1/cost_allocation_plan/list
198
+ */
199
+ list(query?: ListQuery): Paginated<Lark.CostAllocationPlan>;
200
+ }
201
+ interface ListQuery extends Pagination {
202
+ /** 期间 */
203
+ pay_period: string;
204
+ }
205
+ }
206
+ namespace Paygroup {
207
+ interface Methods {
208
+ /**
209
+ * 获取薪资组基本信息
210
+ * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/payroll-v1/paygroup/list
211
+ */
212
+ list(query?: Pagination): Paginated<Lark.Paygroup>;
213
+ }
214
+ }
58
215
  }