@satorijs/adapter-lark 3.11.8 → 3.11.9

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.
@@ -7,6 +7,7 @@ declare module '../internal' {
7
7
  }
8
8
  export declare namespace Apaas {
9
9
  interface Methods {
10
+ app: App.Methods;
10
11
  seatAssignment: SeatAssignment.Methods;
11
12
  seatActivity: SeatActivity.Methods;
12
13
  application: Application.Methods;
@@ -14,6 +15,15 @@ export declare namespace Apaas {
14
15
  approvalTask: ApprovalTask.Methods;
15
16
  approvalInstance: ApprovalInstance.Methods;
16
17
  }
18
+ namespace App {
19
+ interface Methods {
20
+ /**
21
+ * 查看应用基本信息
22
+ * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/apaas-v1/app/list
23
+ */
24
+ list(query?: Pagination): Paginated<Lark.App>;
25
+ }
26
+ }
17
27
  namespace SeatAssignment {
18
28
  interface Methods {
19
29
  /**
@@ -43,8 +53,8 @@ export declare namespace Apaas {
43
53
  namespace Application {
44
54
  interface Methods {
45
55
  auditLog: AuditLog.Methods;
46
- role: Role.Methods;
47
56
  recordPermission: RecordPermission.Methods;
57
+ role: Role.Methods;
48
58
  object: Object.Methods;
49
59
  function: Function.Methods;
50
60
  environmentVariable: EnvironmentVariable.Methods;
@@ -150,6 +160,33 @@ export declare namespace Apaas {
150
160
  data?: Lark.AuditLogDetail;
151
161
  }
152
162
  }
163
+ namespace RecordPermission {
164
+ interface Methods {
165
+ member: Member.Methods;
166
+ }
167
+ namespace Member {
168
+ interface Methods {
169
+ /**
170
+ * 批量删除记录权限用户授权
171
+ * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/apaas-v1/application-record_permission-member/batch_remove_authorization
172
+ */
173
+ batchRemoveAuthorization(namespace: string, record_permission_api_name: string, body: BatchRemoveAuthorizationRequest): Promise<void>;
174
+ /**
175
+ * 批量创建记录权限用户授权
176
+ * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/apaas-v1/application-record_permission-member/batch_create_authorization
177
+ */
178
+ batchCreateAuthorization(namespace: string, record_permission_api_name: string, body: BatchCreateAuthorizationRequest): Promise<void>;
179
+ }
180
+ interface BatchRemoveAuthorizationRequest {
181
+ /** 需要删除的用户 ID 列表 */
182
+ user_ids?: string[];
183
+ }
184
+ interface BatchCreateAuthorizationRequest {
185
+ /** 需要新增的用户 ID 列表 */
186
+ user_ids?: string[];
187
+ }
188
+ }
189
+ }
153
190
  namespace Role {
154
191
  interface Methods {
155
192
  member: Member.Methods;
@@ -196,33 +233,6 @@ export declare namespace Apaas {
196
233
  }
197
234
  }
198
235
  }
199
- namespace RecordPermission {
200
- interface Methods {
201
- member: Member.Methods;
202
- }
203
- namespace Member {
204
- interface Methods {
205
- /**
206
- * 批量删除记录权限用户授权
207
- * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/apaas-v1/application-record_permission-member/batch_remove_authorization
208
- */
209
- batchRemoveAuthorization(namespace: string, record_permission_api_name: string, body: BatchRemoveAuthorizationRequest): Promise<void>;
210
- /**
211
- * 批量创建记录权限用户授权
212
- * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/apaas-v1/application-record_permission-member/batch_create_authorization
213
- */
214
- batchCreateAuthorization(namespace: string, record_permission_api_name: string, body: BatchCreateAuthorizationRequest): Promise<void>;
215
- }
216
- interface BatchRemoveAuthorizationRequest {
217
- /** 需要删除的用户 ID 列表 */
218
- user_ids?: string[];
219
- }
220
- interface BatchCreateAuthorizationRequest {
221
- /** 需要新增的用户 ID 列表 */
222
- user_ids?: string[];
223
- }
224
- }
225
- }
226
236
  namespace Object {
227
237
  interface Methods {
228
238
  record: Record.Methods;
@@ -11,20 +11,59 @@ export declare namespace Board {
11
11
  namespace Whiteboard {
12
12
  interface Methods {
13
13
  node: Node.Methods;
14
+ /**
15
+ * 获取画板主题
16
+ * @see https://open.feishu.cn/document/ukTMukTMukTM/uUDN04SN0QjL1QDN/board-v1/whiteboard/theme
17
+ */
18
+ theme(whiteboard_id: string): Promise<ThemeResponse>;
19
+ /**
20
+ * 更新画板主题
21
+ * @see https://open.feishu.cn/document/ukTMukTMukTM/uUDN04SN0QjL1QDN/board-v1/whiteboard/update_theme
22
+ */
23
+ updateTheme(whiteboard_id: string, body: UpdateThemeRequest): Promise<void>;
14
24
  /**
15
25
  * 获取画板缩略图片
16
26
  * @see https://open.feishu.cn/document/ukTMukTMukTM/uUDN04SN0QjL1QDN/board-v1/whiteboard/download_as_image
17
27
  */
18
28
  downloadAsImage(whiteboard_id: string): Promise<ArrayBuffer>;
19
29
  }
30
+ interface ThemeResponse {
31
+ /** 主题 */
32
+ theme: 'classic' | 'minimalist_gray' | 'retro' | 'vibrant_color' | 'minimalist_blue' | 'default';
33
+ }
34
+ interface UpdateThemeRequest {
35
+ /** 主题名称 */
36
+ theme?: string;
37
+ }
20
38
  namespace Node {
21
39
  interface Methods {
40
+ /**
41
+ * 创建节点
42
+ * @see https://open.feishu.cn/document/ukTMukTMukTM/uUDN04SN0QjL1QDN/board-v1/whiteboard-node/create
43
+ */
44
+ create(whiteboard_id: string, body: CreateRequest, query?: CreateQuery): Promise<CreateResponse>;
22
45
  /**
23
46
  * 获取所有节点
24
47
  * @see https://open.feishu.cn/document/ukTMukTMukTM/uUDN04SN0QjL1QDN/board-v1/whiteboard-node/list
25
48
  */
26
49
  list(whiteboard_id: string): Promise<ListResponse>;
27
50
  }
51
+ interface CreateRequest {
52
+ /** 子节点数据 */
53
+ nodes?: Lark.WhiteboardNode[];
54
+ }
55
+ interface CreateQuery {
56
+ /** 操作的唯一标识,与接口返回值的 client_token 相对应,用于幂等的进行更新操作。此值为空表示将发起一次新的请求,此值非空表示幂等的进行更新操作 */
57
+ client_token?: string;
58
+ /** 此次调用中使用的用户ID的类型 */
59
+ user_id_type?: 'user_id' | 'union_id' | 'open_id';
60
+ }
61
+ interface CreateResponse {
62
+ /** 所创建的节点 id 列表 */
63
+ ids: string[];
64
+ /** 操作的唯一标识,更新请求中使用此值表示幂等的进行此次更新 */
65
+ client_token?: string;
66
+ }
28
67
  interface ListResponse {
29
68
  /** 查询结果 */
30
69
  nodes?: Lark.WhiteboardNode[];
@@ -28,11 +28,21 @@ export declare namespace Calendar {
28
28
  * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/reference/calendar-v4/calendar/primary
29
29
  */
30
30
  primary(query?: PrimaryQuery): Promise<PrimaryResponse>;
31
+ /**
32
+ * 批量获取主日历信息
33
+ * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/reference/calendar-v4/calendar/primarys
34
+ */
35
+ primarys(body: PrimarysRequest, query?: PrimarysQuery): Promise<PrimarysResponse>;
31
36
  /**
32
37
  * 查询日历信息
33
38
  * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/reference/calendar-v4/calendar/get
34
39
  */
35
40
  get(calendar_id: string): Promise<GetResponse>;
41
+ /**
42
+ * 批量查询日历信息
43
+ * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/reference/calendar-v4/calendar/mget
44
+ */
45
+ mget(body: MgetRequest): Promise<MgetResponse>;
36
46
  /**
37
47
  * 查询日历列表
38
48
  * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/reference/calendar-v4/calendar/list
@@ -93,6 +103,18 @@ export declare namespace Calendar {
93
103
  /** 主日历列表 */
94
104
  calendars?: Lark.UserCalendar[];
95
105
  }
106
+ interface PrimarysRequest {
107
+ /** 用户ID列表 */
108
+ user_ids: string[];
109
+ }
110
+ interface PrimarysQuery {
111
+ /** 此次调用中使用的用户ID的类型 */
112
+ user_id_type?: 'user_id' | 'union_id' | 'open_id';
113
+ }
114
+ interface PrimarysResponse {
115
+ /** 主日历列表 */
116
+ calendars?: Lark.UserCalendar[];
117
+ }
96
118
  interface GetResponse {
97
119
  /** 日历OpenId */
98
120
  calendar_id: string;
@@ -115,6 +137,14 @@ export declare namespace Calendar {
115
137
  /** 当前身份对于该日历的访问权限 */
116
138
  role?: 'unknown' | 'free_busy_reader' | 'reader' | 'writer' | 'owner';
117
139
  }
140
+ interface MgetRequest {
141
+ /** 日历ID列表 */
142
+ calendar_ids: string[];
143
+ }
144
+ interface MgetResponse {
145
+ /** 日历列表 */
146
+ calendars?: Lark.Calendar[];
147
+ }
118
148
  interface ListQuery extends Pagination {
119
149
  /** 上次请求Response返回的增量同步标记,分页请求未结束时为空 */
120
150
  sync_token?: string;
@@ -166,6 +196,11 @@ export declare namespace Calendar {
166
196
  * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/reference/calendar-v4/freebusy/list
167
197
  */
168
198
  list(body: ListRequest, query?: ListQuery): Promise<ListResponse>;
199
+ /**
200
+ * 批量查询主日历日程忙闲信息
201
+ * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/reference/calendar-v4/freebusy/batch
202
+ */
203
+ batch(body: BatchRequest, query?: BatchQuery): Promise<BatchResponse>;
169
204
  }
170
205
  interface ListRequest {
171
206
  /** 查询时段开始时间,需要url编码 */
@@ -189,6 +224,26 @@ export declare namespace Calendar {
189
224
  /** 日历上请求时间区间内的忙闲信息 */
190
225
  freebusy_list?: Lark.Freebusy[];
191
226
  }
227
+ interface BatchRequest {
228
+ /** 获取忙闲信息的开始时间,RFC3339 date_time格式;time_min与time_max的时间区间不能超过3个月。 */
229
+ time_min: string;
230
+ /** 获取忙闲信息的开始时间,RFC3339 date_time格式;time_min与time_max的时间区间不能超过3个月。 */
231
+ time_max: string;
232
+ /** 用户ID列表 */
233
+ user_ids: string[];
234
+ /** 是否包含绑定的三方日历中的日程,不传默认为true,即包含。 */
235
+ include_external_calendar?: boolean;
236
+ /** 是否包含标记为空闲的日程,不传默认为true,即包含空闲日程。 */
237
+ only_busy?: boolean;
238
+ }
239
+ interface BatchQuery {
240
+ /** 此次调用中使用的用户ID的类型 */
241
+ user_id_type?: 'user_id' | 'union_id' | 'open_id';
242
+ }
243
+ interface BatchResponse {
244
+ /** 用户忙闲信息列表 */
245
+ freebusy_lists?: Lark.UserFreebusy[];
246
+ }
192
247
  }
193
248
  namespace Acl {
194
249
  interface Methods {
@@ -17,12 +17,12 @@ export declare namespace Cardkit {
17
17
  */
18
18
  create(body: CreateRequest): Promise<CreateResponse>;
19
19
  /**
20
- * 更新卡片配置
20
+ * 更新卡片实体配置
21
21
  * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/cardkit-v1/card/settings
22
22
  */
23
23
  settings(card_id: string, body: SettingsRequest): Promise<void>;
24
24
  /**
25
- * 批量更新卡片实体
25
+ * 局部更新卡片实体
26
26
  * @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/cardkit-v1/card/batch_update
27
27
  */
28
28
  batchUpdate(card_id: string, body: BatchUpdateRequest): Promise<void>;