@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.
- package/lib/index.cjs +2880 -2370
- package/lib/internal.d.ts +4 -4
- package/lib/types/acs.d.ts +212 -172
- package/lib/types/admin.d.ts +331 -291
- package/lib/types/aily.d.ts +331 -216
- package/lib/types/apaas.d.ts +646 -494
- package/lib/types/application.d.ts +559 -458
- package/lib/types/approval.d.ts +826 -791
- package/lib/types/attendance.d.ts +1094 -994
- package/lib/types/auth.d.ts +66 -61
- package/lib/types/authen.d.ts +221 -186
- package/lib/types/baike.d.ts +258 -233
- package/lib/types/base.d.ts +74 -0
- package/lib/types/bitable.d.ts +830 -770
- package/lib/types/board.d.ts +29 -14
- package/lib/types/calendar.d.ts +660 -605
- package/lib/types/cardkit.d.ts +149 -134
- package/lib/types/compensation.d.ts +84 -49
- package/lib/types/contact.d.ts +1279 -1204
- package/lib/types/corehr.d.ts +4982 -4526
- package/lib/types/directory.d.ts +447 -0
- package/lib/types/docs.d.ts +28 -18
- package/lib/types/document_ai.d.ts +347 -252
- package/lib/types/docx.d.ts +428 -383
- package/lib/types/drive.d.ts +1093 -1048
- package/lib/types/ehr.d.ts +66 -51
- package/lib/types/event.d.ts +16 -6
- package/lib/types/helpdesk.d.ts +816 -741
- package/lib/types/hire.d.ts +3955 -3589
- package/lib/types/human_authentication.d.ts +32 -22
- package/lib/types/im.d.ts +1420 -1295
- package/lib/types/index.d.ts +1422 -330
- package/lib/types/lingo.d.ts +279 -249
- package/lib/types/mail.d.ts +1032 -675
- package/lib/types/mdm.d.ts +105 -37
- package/lib/types/minutes.d.ts +73 -26
- package/lib/types/moments.d.ts +23 -13
- package/lib/types/okr.d.ts +266 -225
- package/lib/types/optical_char_recognition.d.ts +22 -12
- package/lib/types/passport.d.ts +58 -48
- package/lib/types/payroll.d.ts +210 -53
- package/lib/types/performance.d.ts +463 -414
- package/lib/types/personal_settings.d.ts +93 -82
- package/lib/types/report.d.ts +79 -58
- package/lib/types/search.d.ts +265 -235
- package/lib/types/security_and_compliance.d.ts +30 -19
- package/lib/types/sheets.d.ts +356 -321
- package/lib/types/speech_to_text.d.ts +44 -34
- package/lib/types/task.d.ts +998 -1087
- package/lib/types/tenant.d.ts +25 -15
- package/lib/types/translation.d.ts +42 -32
- package/lib/types/trust_party.d.ts +81 -0
- package/lib/types/vc.d.ts +1218 -1123
- package/lib/types/verification.d.ts +11 -6
- package/lib/types/wiki.d.ts +270 -235
- package/lib/types/workplace.d.ts +58 -38
- package/lib/utils.d.ts +2 -2
- package/package.json +4 -4
- package/src/bot.ts +15 -15
- package/src/internal.ts +29 -12
- package/src/message.ts +10 -10
- package/src/types/acs.ts +234 -186
- package/src/types/admin.ts +353 -305
- package/src/types/aily.ts +375 -233
- package/src/types/apaas.ts +754 -568
- package/src/types/application.ts +633 -507
- package/src/types/approval.ts +914 -872
- package/src/types/attendance.ts +1226 -1104
- package/src/types/auth.ts +72 -66
- package/src/types/authen.ts +233 -191
- package/src/types/baike.ts +276 -246
- package/src/types/base.ts +93 -0
- package/src/types/bitable.ts +966 -894
- package/src/types/board.ts +34 -16
- package/src/types/calendar.ts +751 -685
- package/src/types/cardkit.ts +164 -146
- package/src/types/compensation.ts +97 -55
- package/src/types/contact.ts +1465 -1375
- package/src/types/corehr.ts +5664 -5077
- package/src/types/directory.ts +569 -0
- package/src/types/docs.ts +31 -19
- package/src/types/document_ai.ts +401 -287
- package/src/types/docx.ts +492 -438
- package/src/types/drive.ts +1266 -1213
- package/src/types/ehr.ts +71 -53
- package/src/types/event.ts +19 -7
- package/src/types/helpdesk.ts +930 -840
- package/src/types/hire.ts +4453 -4019
- package/src/types/human_authentication.ts +35 -23
- package/src/types/im.ts +1626 -1476
- package/src/types/index.ts +1532 -346
- package/src/types/lingo.ts +299 -263
- package/src/types/mail.ts +1231 -779
- package/src/types/mdm.ts +122 -39
- package/src/types/minutes.ts +88 -28
- package/src/types/moments.ts +26 -14
- package/src/types/okr.ts +286 -238
- package/src/types/optical_char_recognition.ts +25 -13
- package/src/types/passport.ts +62 -50
- package/src/types/payroll.ts +254 -57
- package/src/types/performance.ts +528 -467
- package/src/types/personal_settings.ts +101 -89
- package/src/types/report.ts +86 -62
- package/src/types/search.ts +285 -249
- package/src/types/security_and_compliance.ts +33 -21
- package/src/types/sheets.ts +421 -379
- package/src/types/speech_to_text.ts +48 -36
- package/src/types/task.ts +1152 -1260
- package/src/types/tenant.ts +29 -17
- package/src/types/translation.ts +46 -34
- package/src/types/trust_party.ts +110 -0
- package/src/types/vc.ts +1397 -1283
- package/src/types/verification.ts +13 -7
- package/src/types/wiki.ts +293 -251
- package/src/types/workplace.ts +65 -41
- package/src/utils.ts +3 -3
package/src/types/aily.ts
CHANGED
|
@@ -1,288 +1,430 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { Internal, Pagination } from '../internal'
|
|
1
|
+
import * as Lark from '.'
|
|
2
|
+
import { Internal, Paginated, Pagination } from '../internal'
|
|
3
3
|
|
|
4
4
|
declare module '../internal' {
|
|
5
5
|
interface Internal {
|
|
6
|
-
|
|
7
|
-
* 创建会话
|
|
8
|
-
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session/create
|
|
9
|
-
*/
|
|
10
|
-
createAilyAilySession(body: CreateAilyAilySessionRequest): Promise<CreateAilyAilySessionResponse>
|
|
11
|
-
/**
|
|
12
|
-
* 更新会话
|
|
13
|
-
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session/update
|
|
14
|
-
*/
|
|
15
|
-
updateAilyAilySession(aily_session_id: string, body: UpdateAilyAilySessionRequest): Promise<UpdateAilyAilySessionResponse>
|
|
16
|
-
/**
|
|
17
|
-
* 获取会话
|
|
18
|
-
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session/get
|
|
19
|
-
*/
|
|
20
|
-
getAilyAilySession(aily_session_id: string): Promise<GetAilyAilySessionResponse>
|
|
21
|
-
/**
|
|
22
|
-
* 删除会话
|
|
23
|
-
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session/delete
|
|
24
|
-
*/
|
|
25
|
-
deleteAilyAilySession(aily_session_id: string): Promise<void>
|
|
26
|
-
/**
|
|
27
|
-
* 发送智能伙伴消息
|
|
28
|
-
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session-aily_message/create
|
|
29
|
-
*/
|
|
30
|
-
createAilyAilySessionAilyMessage(aily_session_id: string, body: CreateAilyAilySessionAilyMessageRequest): Promise<CreateAilyAilySessionAilyMessageResponse>
|
|
31
|
-
/**
|
|
32
|
-
* 获取智能伙伴消息
|
|
33
|
-
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session-aily_message/get
|
|
34
|
-
*/
|
|
35
|
-
getAilyAilySessionAilyMessage(aily_session_id: string, aily_message_id: string): Promise<GetAilyAilySessionAilyMessageResponse>
|
|
36
|
-
/**
|
|
37
|
-
* 列出智能伙伴消息
|
|
38
|
-
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session-aily_message/list
|
|
39
|
-
*/
|
|
40
|
-
listAilyAilySessionAilyMessage(aily_session_id: string, query?: ListAilyAilySessionAilyMessageQuery): Paginated<AilyMessage, 'messages'>
|
|
41
|
-
/**
|
|
42
|
-
* 创建运行
|
|
43
|
-
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session-run/create
|
|
44
|
-
*/
|
|
45
|
-
createAilyAilySessionRun(aily_session_id: string, body: CreateAilyAilySessionRunRequest): Promise<CreateAilyAilySessionRunResponse>
|
|
46
|
-
/**
|
|
47
|
-
* 获取运行
|
|
48
|
-
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session-run/get
|
|
49
|
-
*/
|
|
50
|
-
getAilyAilySessionRun(aily_session_id: string, run_id: string): Promise<GetAilyAilySessionRunResponse>
|
|
51
|
-
/**
|
|
52
|
-
* 列出运行
|
|
53
|
-
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session-run/list
|
|
54
|
-
*/
|
|
55
|
-
listAilyAilySessionRun(aily_session_id: string, query?: Pagination): Paginated<Run, 'runs'>
|
|
56
|
-
/**
|
|
57
|
-
* 取消运行
|
|
58
|
-
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session-run/cancel
|
|
59
|
-
*/
|
|
60
|
-
cancelAilyAilySessionRun(aily_session_id: string, run_id: string): Promise<CancelAilyAilySessionRunResponse>
|
|
61
|
-
/**
|
|
62
|
-
* 调用技能
|
|
63
|
-
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/app-skill/start
|
|
64
|
-
*/
|
|
65
|
-
startAilyAppSkill(app_id: string, skill_id: string, body: StartAilyAppSkillRequest): Promise<StartAilyAppSkillResponse>
|
|
66
|
-
/**
|
|
67
|
-
* 获取技能信息
|
|
68
|
-
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/app-skill/get
|
|
69
|
-
*/
|
|
70
|
-
getAilyAppSkill(app_id: string, skill_id: string): Promise<GetAilyAppSkillResponse>
|
|
71
|
-
/**
|
|
72
|
-
* 查询技能列表
|
|
73
|
-
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/app-skill/list
|
|
74
|
-
*/
|
|
75
|
-
listAilyAppSkill(app_id: string, query?: Pagination): Paginated<Skill, 'skills'>
|
|
76
|
-
/**
|
|
77
|
-
* 执行数据知识问答
|
|
78
|
-
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/app-knowledge/ask
|
|
79
|
-
*/
|
|
80
|
-
askAilyAppKnowledge(app_id: string, body: AskAilyAppKnowledgeRequest): Promise<AskAilyAppKnowledgeResponse>
|
|
81
|
-
/**
|
|
82
|
-
* 查询数据知识列表
|
|
83
|
-
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/app-data_asset/list
|
|
84
|
-
*/
|
|
85
|
-
listAilyAppDataAsset(app_id: string, query?: ListAilyAppDataAssetQuery): Paginated<DataAsset>
|
|
86
|
-
/**
|
|
87
|
-
* 获取数据知识分类列表
|
|
88
|
-
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/app-data_asset_tag/list
|
|
89
|
-
*/
|
|
90
|
-
listAilyAppDataAssetTag(app_id: string, query?: ListAilyAppDataAssetTagQuery): Paginated<DataAssetTag>
|
|
6
|
+
aily: Aily.Methods
|
|
91
7
|
}
|
|
92
8
|
}
|
|
93
9
|
|
|
94
|
-
export
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
}
|
|
10
|
+
export namespace Aily {
|
|
11
|
+
export interface Methods {
|
|
12
|
+
ailySession: AilySession.Methods
|
|
13
|
+
app: App.Methods
|
|
14
|
+
}
|
|
100
15
|
|
|
101
|
-
export
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
16
|
+
export namespace AilySession {
|
|
17
|
+
export interface Methods {
|
|
18
|
+
ailyMessage: AilyMessage.Methods
|
|
19
|
+
run: Run.Methods
|
|
20
|
+
/**
|
|
21
|
+
* 创建会话
|
|
22
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session/create
|
|
23
|
+
*/
|
|
24
|
+
create(body: CreateRequest): Promise<CreateResponse>
|
|
25
|
+
/**
|
|
26
|
+
* 更新会话
|
|
27
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session/update
|
|
28
|
+
*/
|
|
29
|
+
update(aily_session_id: string, body: UpdateRequest): Promise<UpdateResponse>
|
|
30
|
+
/**
|
|
31
|
+
* 获取会话
|
|
32
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session/get
|
|
33
|
+
*/
|
|
34
|
+
get(aily_session_id: string): Promise<GetResponse>
|
|
35
|
+
/**
|
|
36
|
+
* 删除会话
|
|
37
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session/delete
|
|
38
|
+
*/
|
|
39
|
+
delete(aily_session_id: string): Promise<void>
|
|
40
|
+
}
|
|
105
41
|
|
|
106
|
-
export interface
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
}
|
|
42
|
+
export interface CreateRequest {
|
|
43
|
+
/** 渠道上下文 */
|
|
44
|
+
channel_context?: string
|
|
45
|
+
/** 其他透传信息 */
|
|
46
|
+
metadata?: string
|
|
47
|
+
}
|
|
112
48
|
|
|
113
|
-
export interface
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
}
|
|
49
|
+
export interface CreateResponse {
|
|
50
|
+
/** 创建的会话信息 */
|
|
51
|
+
session?: Lark.AilySession
|
|
52
|
+
}
|
|
117
53
|
|
|
118
|
-
export interface
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
54
|
+
export interface UpdateRequest {
|
|
55
|
+
/** 渠道上下文 */
|
|
56
|
+
channel_context?: string
|
|
57
|
+
/** 其他透传信息 */
|
|
58
|
+
metadata?: string
|
|
59
|
+
}
|
|
122
60
|
|
|
123
|
-
export interface
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
content_type: AilyMessageContentType
|
|
128
|
-
/** 消息内容 */
|
|
129
|
-
content: string
|
|
130
|
-
/** 消息中包含的文件 ID 列表 */
|
|
131
|
-
file_ids?: string[]
|
|
132
|
-
/** 引用的消息 ID */
|
|
133
|
-
quote_message_id?: string
|
|
134
|
-
/** 被@的实体 */
|
|
135
|
-
mentions?: AilyMention[]
|
|
136
|
-
}
|
|
61
|
+
export interface UpdateResponse {
|
|
62
|
+
/** 会话信息 */
|
|
63
|
+
session?: Lark.AilySession
|
|
64
|
+
}
|
|
137
65
|
|
|
138
|
-
export interface
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
}
|
|
66
|
+
export interface GetResponse {
|
|
67
|
+
/** 会话信息 */
|
|
68
|
+
session?: Lark.AilySession
|
|
69
|
+
}
|
|
142
70
|
|
|
143
|
-
export
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
71
|
+
export namespace AilyMessage {
|
|
72
|
+
export interface Methods {
|
|
73
|
+
/**
|
|
74
|
+
* 发送智能伙伴消息
|
|
75
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session-aily_message/create
|
|
76
|
+
*/
|
|
77
|
+
create(aily_session_id: string, body: CreateRequest): Promise<CreateResponse>
|
|
78
|
+
/**
|
|
79
|
+
* 获取智能伙伴消息
|
|
80
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session-aily_message/get
|
|
81
|
+
*/
|
|
82
|
+
get(aily_session_id: string, aily_message_id: string): Promise<GetResponse>
|
|
83
|
+
/**
|
|
84
|
+
* 列出智能伙伴消息
|
|
85
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session-aily_message/list
|
|
86
|
+
*/
|
|
87
|
+
list(aily_session_id: string, query?: ListQuery): Paginated<Lark.AilyMessage, 'messages'>
|
|
88
|
+
}
|
|
147
89
|
|
|
148
|
-
export interface
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
90
|
+
export interface CreateRequest {
|
|
91
|
+
/** 幂等id,同一 session 下相同的幂等 id 算一条消息,有效期72h */
|
|
92
|
+
idempotent_id: string
|
|
93
|
+
/** 消息内容类型 */
|
|
94
|
+
content_type: Lark.AilyMessageContentType
|
|
95
|
+
/** 消息内容 */
|
|
96
|
+
content: string
|
|
97
|
+
/** 消息中包含的文件 ID 列表 */
|
|
98
|
+
file_ids?: string[]
|
|
99
|
+
/** 引用的消息 ID */
|
|
100
|
+
quote_message_id?: string
|
|
101
|
+
/** 被@的实体 */
|
|
102
|
+
mentions?: Lark.AilyMention[]
|
|
103
|
+
}
|
|
154
104
|
|
|
155
|
-
export interface
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
skill_id?: string
|
|
160
|
-
/** 指定技能 ID 时可以同时指定技能输入 */
|
|
161
|
-
skill_input?: string
|
|
162
|
-
/** 其他透传信息 */
|
|
163
|
-
metadata?: string
|
|
164
|
-
}
|
|
105
|
+
export interface CreateResponse {
|
|
106
|
+
/** 消息信息 */
|
|
107
|
+
message?: Lark.AilyMessage
|
|
108
|
+
}
|
|
165
109
|
|
|
166
|
-
export interface
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
}
|
|
110
|
+
export interface GetResponse {
|
|
111
|
+
/** 消息信息 */
|
|
112
|
+
message?: Lark.AilyMessage
|
|
113
|
+
}
|
|
170
114
|
|
|
171
|
-
export interface
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
115
|
+
export interface ListQuery extends Pagination {
|
|
116
|
+
/** 运行 ID */
|
|
117
|
+
run_id?: string
|
|
118
|
+
/** 返回生成中的消息 */
|
|
119
|
+
with_partial_message?: boolean
|
|
120
|
+
}
|
|
121
|
+
}
|
|
175
122
|
|
|
176
|
-
export
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
123
|
+
export namespace Run {
|
|
124
|
+
export interface Methods {
|
|
125
|
+
/**
|
|
126
|
+
* 创建运行
|
|
127
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session-run/create
|
|
128
|
+
*/
|
|
129
|
+
create(aily_session_id: string, body: CreateRequest): Promise<CreateResponse>
|
|
130
|
+
/**
|
|
131
|
+
* 获取运行
|
|
132
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session-run/get
|
|
133
|
+
*/
|
|
134
|
+
get(aily_session_id: string, run_id: string): Promise<GetResponse>
|
|
135
|
+
/**
|
|
136
|
+
* 列出运行
|
|
137
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session-run/list
|
|
138
|
+
*/
|
|
139
|
+
list(aily_session_id: string, query?: Pagination): Paginated<Lark.Run, 'runs'>
|
|
140
|
+
/**
|
|
141
|
+
* 取消运行
|
|
142
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/aily_session-run/cancel
|
|
143
|
+
*/
|
|
144
|
+
cancel(aily_session_id: string, run_id: string): Promise<CancelResponse>
|
|
145
|
+
}
|
|
180
146
|
|
|
181
|
-
export interface
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
147
|
+
export interface CreateRequest {
|
|
148
|
+
/** 应用 ID */
|
|
149
|
+
app_id: string
|
|
150
|
+
/** 技能 ID */
|
|
151
|
+
skill_id?: string
|
|
152
|
+
/** 指定技能 ID 时可以同时指定技能输入 */
|
|
153
|
+
skill_input?: string
|
|
154
|
+
/** 其他透传信息 */
|
|
155
|
+
metadata?: string
|
|
156
|
+
}
|
|
187
157
|
|
|
188
|
-
export interface
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
status?: string
|
|
193
|
-
}
|
|
158
|
+
export interface CreateResponse {
|
|
159
|
+
/** 运行信息 */
|
|
160
|
+
run?: Lark.Run
|
|
161
|
+
}
|
|
194
162
|
|
|
195
|
-
export interface
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
}
|
|
163
|
+
export interface GetResponse {
|
|
164
|
+
/** 运行信息 */
|
|
165
|
+
run?: Lark.Run
|
|
166
|
+
}
|
|
199
167
|
|
|
200
|
-
export interface
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
data_asset_tag_ids?: string[]
|
|
207
|
-
}
|
|
168
|
+
export interface CancelResponse {
|
|
169
|
+
/** 运行信息 */
|
|
170
|
+
run?: Lark.Run
|
|
171
|
+
}
|
|
172
|
+
}
|
|
173
|
+
}
|
|
208
174
|
|
|
209
|
-
export
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
/** 知识问答运行过程结构化数据,status=finished 且 finish_type=qa 时返回 */
|
|
217
|
-
process_data?: AilyKnowledgeAskProcessData
|
|
218
|
-
/** 匹配标准问答对结果,status=finished 且 finish_type=faq时返回 */
|
|
219
|
-
faq_result?: AilyKnowledgeFaq
|
|
220
|
-
/** 是否有结果,true 则 代表 message 中的内容是通过配置知识而生成的 */
|
|
221
|
-
has_answer?: boolean
|
|
222
|
-
}
|
|
175
|
+
export namespace App {
|
|
176
|
+
export interface Methods {
|
|
177
|
+
skill: Skill.Methods
|
|
178
|
+
knowledge: Knowledge.Methods
|
|
179
|
+
dataAsset: DataAsset.Methods
|
|
180
|
+
dataAssetTag: DataAssetTag.Methods
|
|
181
|
+
}
|
|
223
182
|
|
|
224
|
-
export
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
183
|
+
export namespace Skill {
|
|
184
|
+
export interface Methods {
|
|
185
|
+
/**
|
|
186
|
+
* 调用技能
|
|
187
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/app-skill/start
|
|
188
|
+
*/
|
|
189
|
+
start(app_id: string, skill_id: string, body: StartRequest): Promise<StartResponse>
|
|
190
|
+
/**
|
|
191
|
+
* 获取技能信息
|
|
192
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/app-skill/get
|
|
193
|
+
*/
|
|
194
|
+
get(app_id: string, skill_id: string): Promise<GetResponse>
|
|
195
|
+
/**
|
|
196
|
+
* 查询技能列表
|
|
197
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/app-skill/list
|
|
198
|
+
*/
|
|
199
|
+
list(app_id: string, query?: Pagination): Paginated<Lark.Skill, 'skills'>
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
export interface StartRequest {
|
|
203
|
+
/** 技能的全局变量 */
|
|
204
|
+
global_variable?: Lark.SkillGlobalVariable
|
|
205
|
+
/** 技能的自定义变量 */
|
|
206
|
+
input?: string
|
|
207
|
+
}
|
|
236
208
|
|
|
237
|
-
export interface
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
209
|
+
export interface StartResponse {
|
|
210
|
+
/** 技能的输出 */
|
|
211
|
+
output?: string
|
|
212
|
+
/** 技能的执行状态 */
|
|
213
|
+
status?: string
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
export interface GetResponse {
|
|
217
|
+
/** 技能信息 */
|
|
218
|
+
skill?: Lark.Skill
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
export namespace Knowledge {
|
|
223
|
+
export interface Methods {
|
|
224
|
+
/**
|
|
225
|
+
* 执行数据知识问答
|
|
226
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/app-knowledge/ask
|
|
227
|
+
*/
|
|
228
|
+
ask(app_id: string, body: AskRequest): Promise<AskResponse>
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
export interface AskRequest {
|
|
232
|
+
/** 输入消息(当前仅支持纯文本输入) */
|
|
233
|
+
message: Lark.AilyKnowledgeMessage
|
|
234
|
+
/** 控制知识问答所依据的数据知识范围 */
|
|
235
|
+
data_asset_ids?: string[]
|
|
236
|
+
/** 控制知识问答所依据的数据知识分类范围 */
|
|
237
|
+
data_asset_tag_ids?: string[]
|
|
238
|
+
}
|
|
239
|
+
|
|
240
|
+
export interface AskResponse {
|
|
241
|
+
/** 响应状态,枚举值 */
|
|
242
|
+
status?: 'processing' | 'finished'
|
|
243
|
+
/** 结束类型,枚举值 */
|
|
244
|
+
finish_type?: 'qa' | 'faq'
|
|
245
|
+
/** 响应消息 */
|
|
246
|
+
message?: Lark.AilyKnowledgeMessage
|
|
247
|
+
/** 知识问答运行过程结构化数据,status=finished 且 finish_type=qa 时返回 */
|
|
248
|
+
process_data?: Lark.AilyKnowledgeAskProcessData
|
|
249
|
+
/** 匹配标准问答对结果,status=finished 且 finish_type=faq时返回 */
|
|
250
|
+
faq_result?: Lark.AilyKnowledgeFaq
|
|
251
|
+
/** 是否有结果,true 则 代表 message 中的内容是通过配置知识而生成的 */
|
|
252
|
+
has_answer?: boolean
|
|
253
|
+
}
|
|
254
|
+
}
|
|
255
|
+
|
|
256
|
+
export namespace DataAsset {
|
|
257
|
+
export interface Methods {
|
|
258
|
+
/**
|
|
259
|
+
* 上传文件用于数据知识管理
|
|
260
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/app-data_asset/upload_file
|
|
261
|
+
*/
|
|
262
|
+
uploadFile(app_id: string, form: UploadFileForm, query?: UploadFileQuery): Promise<UploadFileResponse>
|
|
263
|
+
/**
|
|
264
|
+
* 创建数据知识
|
|
265
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/app-data_asset/create
|
|
266
|
+
*/
|
|
267
|
+
create(app_id: string, body: CreateRequest, query?: CreateQuery): Promise<CreateResponse>
|
|
268
|
+
/**
|
|
269
|
+
* 获取数据知识
|
|
270
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/app-data_asset/get
|
|
271
|
+
*/
|
|
272
|
+
get(app_id: string, data_asset_id: string, query?: GetQuery): Promise<GetResponse>
|
|
273
|
+
/**
|
|
274
|
+
* 删除数据知识
|
|
275
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/app-data_asset/delete
|
|
276
|
+
*/
|
|
277
|
+
delete(app_id: string, data_asset_id: string, query?: DeleteQuery): Promise<DeleteResponse>
|
|
278
|
+
/**
|
|
279
|
+
* 查询数据知识列表
|
|
280
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/app-data_asset/list
|
|
281
|
+
*/
|
|
282
|
+
list(app_id: string, query?: ListQuery): Paginated<Lark.DataAsset>
|
|
283
|
+
}
|
|
284
|
+
|
|
285
|
+
export interface UploadFileForm {
|
|
286
|
+
/** 需要上传的文件 */
|
|
287
|
+
file: Blob
|
|
288
|
+
}
|
|
289
|
+
|
|
290
|
+
export interface UploadFileQuery {
|
|
291
|
+
/** 应用环境,默认为线上环境,dev代表开发环境,只支持dev */
|
|
292
|
+
tenant_type?: string
|
|
293
|
+
}
|
|
294
|
+
|
|
295
|
+
export interface UploadFileResponse {
|
|
296
|
+
/** 数据知识文件 */
|
|
297
|
+
file_info?: Lark.DataAssetFile
|
|
298
|
+
}
|
|
299
|
+
|
|
300
|
+
export interface CreateRequest {
|
|
301
|
+
/** 连接类型 */
|
|
302
|
+
connect_type: 'import' | 'direct'
|
|
303
|
+
/** 数据源类型 */
|
|
304
|
+
source_type: 'file' | 'lark_wiki_space' | 'lark_doc' | 'lark_helpdesk'
|
|
305
|
+
/** 知识导入配置 */
|
|
306
|
+
import_knowledge_setting?: Lark.DataAssetImportKnowledgeSetting
|
|
307
|
+
/** 数据知识描述信息 */
|
|
308
|
+
description?: Record<string, string>
|
|
309
|
+
}
|
|
310
|
+
|
|
311
|
+
export interface CreateQuery {
|
|
312
|
+
/** 应用环境,默认为线上环境,dev代表开发环境,只支持dev */
|
|
313
|
+
tenant_type?: string
|
|
314
|
+
}
|
|
315
|
+
|
|
316
|
+
export interface CreateResponse {
|
|
317
|
+
/** 数据知识 */
|
|
318
|
+
data_asset?: Lark.DataAsset
|
|
319
|
+
}
|
|
320
|
+
|
|
321
|
+
export interface GetQuery {
|
|
322
|
+
/** 结果是否包含数据与知识项 */
|
|
323
|
+
with_data_asset_item?: boolean
|
|
324
|
+
/** 结果是否包含数据知识连接状态 */
|
|
325
|
+
with_connect_status?: boolean
|
|
326
|
+
/** 应用环境,默认为线上环境,dev代表开发环境 */
|
|
327
|
+
tenant_type?: string
|
|
328
|
+
}
|
|
329
|
+
|
|
330
|
+
export interface GetResponse {
|
|
331
|
+
/** 数据知识 */
|
|
332
|
+
data_asset?: Lark.DataAsset
|
|
333
|
+
}
|
|
334
|
+
|
|
335
|
+
export interface DeleteQuery {
|
|
336
|
+
/** 应用环境,默认为线上环境,dev代表开发环境,只支持dev */
|
|
337
|
+
tenant_type?: string
|
|
338
|
+
}
|
|
339
|
+
|
|
340
|
+
export interface DeleteResponse {
|
|
341
|
+
/** 数据知识 */
|
|
342
|
+
data_asset?: Lark.DataAsset
|
|
343
|
+
}
|
|
344
|
+
|
|
345
|
+
export interface ListQuery extends Pagination {
|
|
346
|
+
/** 模糊匹配关键词 */
|
|
347
|
+
keyword?: string
|
|
348
|
+
/** 根据数据知识 ID 进行过滤 */
|
|
349
|
+
data_asset_ids?: string[]
|
|
350
|
+
/** 根据数据知识分类 ID 进行过滤 */
|
|
351
|
+
data_asset_tag_ids?: string[]
|
|
352
|
+
/** 结果是否包含数据与知识项目 */
|
|
353
|
+
with_data_asset_item?: boolean
|
|
354
|
+
/** 结果是否包含数据连接状态 */
|
|
355
|
+
with_connect_status?: boolean
|
|
356
|
+
}
|
|
357
|
+
}
|
|
358
|
+
|
|
359
|
+
export namespace DataAssetTag {
|
|
360
|
+
export interface Methods {
|
|
361
|
+
/**
|
|
362
|
+
* 获取数据知识分类列表
|
|
363
|
+
* @see https://open.feishu.cn/document/uAjLw4CM/ukTMukTMukTM/aily-v1/app-data_asset_tag/list
|
|
364
|
+
*/
|
|
365
|
+
list(app_id: string, query?: ListQuery): Paginated<Lark.DataAssetTag>
|
|
366
|
+
}
|
|
367
|
+
|
|
368
|
+
export interface ListQuery extends Pagination {
|
|
369
|
+
/** 模糊匹配分类名称 */
|
|
370
|
+
keyword?: string
|
|
371
|
+
/** 模糊匹配分类名称 */
|
|
372
|
+
data_asset_tag_ids?: string[]
|
|
373
|
+
}
|
|
374
|
+
}
|
|
375
|
+
}
|
|
242
376
|
}
|
|
243
377
|
|
|
244
378
|
Internal.define({
|
|
245
379
|
'/aily/v1/sessions': {
|
|
246
|
-
POST: '
|
|
380
|
+
POST: 'aily.ailySession.create',
|
|
247
381
|
},
|
|
248
382
|
'/aily/v1/sessions/{aily_session_id}': {
|
|
249
|
-
PUT: '
|
|
250
|
-
GET: '
|
|
251
|
-
DELETE: '
|
|
383
|
+
PUT: 'aily.ailySession.update',
|
|
384
|
+
GET: 'aily.ailySession.get',
|
|
385
|
+
DELETE: 'aily.ailySession.delete',
|
|
252
386
|
},
|
|
253
387
|
'/aily/v1/sessions/{aily_session_id}/messages': {
|
|
254
|
-
POST: '
|
|
255
|
-
GET: { name: '
|
|
388
|
+
POST: 'aily.ailySession.ailyMessage.create',
|
|
389
|
+
GET: { name: 'aily.ailySession.ailyMessage.list', pagination: { argIndex: 1, itemsKey: 'messages' } },
|
|
256
390
|
},
|
|
257
391
|
'/aily/v1/sessions/{aily_session_id}/messages/{aily_message_id}': {
|
|
258
|
-
GET: '
|
|
392
|
+
GET: 'aily.ailySession.ailyMessage.get',
|
|
259
393
|
},
|
|
260
394
|
'/aily/v1/sessions/{aily_session_id}/runs': {
|
|
261
|
-
POST: '
|
|
262
|
-
GET: { name: '
|
|
395
|
+
POST: 'aily.ailySession.run.create',
|
|
396
|
+
GET: { name: 'aily.ailySession.run.list', pagination: { argIndex: 1, itemsKey: 'runs' } },
|
|
263
397
|
},
|
|
264
398
|
'/aily/v1/sessions/{aily_session_id}/runs/{run_id}': {
|
|
265
|
-
GET: '
|
|
399
|
+
GET: 'aily.ailySession.run.get',
|
|
266
400
|
},
|
|
267
401
|
'/aily/v1/sessions/{aily_session_id}/runs/{run_id}/cancel': {
|
|
268
|
-
POST: '
|
|
402
|
+
POST: 'aily.ailySession.run.cancel',
|
|
269
403
|
},
|
|
270
404
|
'/aily/v1/apps/{app_id}/skills/{skill_id}/start': {
|
|
271
|
-
POST: '
|
|
405
|
+
POST: 'aily.app.skill.start',
|
|
272
406
|
},
|
|
273
407
|
'/aily/v1/apps/{app_id}/skills/{skill_id}': {
|
|
274
|
-
GET: '
|
|
408
|
+
GET: 'aily.app.skill.get',
|
|
275
409
|
},
|
|
276
410
|
'/aily/v1/apps/{app_id}/skills': {
|
|
277
|
-
GET: { name: '
|
|
411
|
+
GET: { name: 'aily.app.skill.list', pagination: { argIndex: 1, itemsKey: 'skills' } },
|
|
278
412
|
},
|
|
279
413
|
'/aily/v1/apps/{app_id}/knowledges/ask': {
|
|
280
|
-
POST: '
|
|
414
|
+
POST: 'aily.app.knowledge.ask',
|
|
415
|
+
},
|
|
416
|
+
'/aily/v1/apps/{app_id}/data_assets/upload_file': {
|
|
417
|
+
POST: { name: 'aily.app.dataAsset.uploadFile', multipart: true },
|
|
281
418
|
},
|
|
282
419
|
'/aily/v1/apps/{app_id}/data_assets': {
|
|
283
|
-
|
|
420
|
+
POST: 'aily.app.dataAsset.create',
|
|
421
|
+
GET: { name: 'aily.app.dataAsset.list', pagination: { argIndex: 1 } },
|
|
422
|
+
},
|
|
423
|
+
'/aily/v1/apps/{app_id}/data_assets/{data_asset_id}': {
|
|
424
|
+
GET: 'aily.app.dataAsset.get',
|
|
425
|
+
DELETE: 'aily.app.dataAsset.delete',
|
|
284
426
|
},
|
|
285
427
|
'/aily/v1/apps/{app_id}/data_asset_tags': {
|
|
286
|
-
GET: { name: '
|
|
428
|
+
GET: { name: 'aily.app.dataAssetTag.list', pagination: { argIndex: 1 } },
|
|
287
429
|
},
|
|
288
430
|
})
|