@satorijs/adapter-dingtalk 2.0.3 → 2.0.5
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/bot.d.ts +1 -1
- package/lib/http.d.ts +3 -2
- package/lib/index.js +35 -14
- package/lib/index.js.map +2 -3
- package/package.json +8 -4
- package/src/api/.eslintrc.yml +2 -0
- package/src/api/alitrip.ts +467 -0
- package/src/api/attendance.ts +81 -0
- package/src/api/badge.ts +285 -0
- package/src/api/blackboard.ts +28 -0
- package/src/api/calendar.ts +817 -0
- package/src/api/card.ts +215 -0
- package/src/api/conference.ts +561 -0
- package/src/api/connector.ts +97 -0
- package/src/api/contact.ts +56 -0
- package/src/api/convFile.ts +166 -0
- package/src/api/crm.ts +830 -0
- package/src/api/customerService.ts +156 -0
- package/src/api/datacenter.ts +672 -0
- package/src/api/devicemng.ts +202 -0
- package/src/api/diot.ts +19 -0
- package/src/api/doc.ts +232 -0
- package/src/api/drive.ts +109 -0
- package/src/api/edu.ts +30 -0
- package/src/api/esign.ts +44 -0
- package/src/api/exclusive.ts +372 -0
- package/src/api/h3yun.ts +537 -0
- package/src/api/hrm.ts +272 -0
- package/src/api/im.ts +978 -0
- package/src/api/industry.ts +153 -0
- package/src/api/jzcrm.ts +304 -0
- package/src/api/link.ts +94 -0
- package/src/api/live.ts +162 -0
- package/src/api/microApp.ts +309 -0
- package/src/api/oapi.ts +4083 -0
- package/src/api/oauth2.ts +146 -0
- package/src/api/pedia.ts +222 -0
- package/src/api/project.ts +1519 -0
- package/src/api/resident.ts +133 -0
- package/src/api/robot.ts +326 -0
- package/src/api/rooms.ts +334 -0
- package/src/api/serviceGroup.ts +216 -0
- package/src/api/storage.ts +1701 -0
- package/src/api/swform.ts +94 -0
- package/src/api/todo.ts +220 -0
- package/src/api/wiki.ts +231 -0
- package/src/api/workbench.ts +73 -0
- package/src/api/yida.ts +2165 -0
- package/src/bot.ts +129 -0
- package/src/http.ts +44 -0
- package/src/index.ts +9 -0
- package/src/internal.ts +47 -0
- package/src/message.ts +141 -0
- package/src/types/index.ts +140 -0
- package/src/utils.ts +53 -0
- package/src/ws.ts +55 -0
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { Internal } from '../internal'
|
|
2
|
+
// GENERATED CONTENT
|
|
3
|
+
|
|
4
|
+
export interface GetFormInstanceQuery {
|
|
5
|
+
/** 填表类型。 */
|
|
6
|
+
bizType?: number
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
export interface GetFormInstanceResponse {
|
|
10
|
+
success?: unknown
|
|
11
|
+
result?: {
|
|
12
|
+
createTime?: string
|
|
13
|
+
modifyTime?: string
|
|
14
|
+
formCode?: string
|
|
15
|
+
title?: string
|
|
16
|
+
creator?: string
|
|
17
|
+
forms?: number
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export interface ListFormInstancesQuery {
|
|
22
|
+
/** 填表类型。 */
|
|
23
|
+
bizType?: number
|
|
24
|
+
/** 时间,格式要求为yyyy-MM-dd。 */
|
|
25
|
+
actionDate?: string
|
|
26
|
+
/** 分页游标。 */
|
|
27
|
+
nextToken: number
|
|
28
|
+
/** 每页最大条目数,最大值100。 */
|
|
29
|
+
maxResults: number
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
export interface ListFormInstancesResponse {
|
|
33
|
+
success?: unknown
|
|
34
|
+
result?: {
|
|
35
|
+
hasMore?: number
|
|
36
|
+
nextToken?: number
|
|
37
|
+
list?: number
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
export interface ListFormSchemasByCreatorQuery {
|
|
42
|
+
/** 每页最大条目数,最大值200。 */
|
|
43
|
+
maxResults: number
|
|
44
|
+
/** 填表类型。 */
|
|
45
|
+
bizType?: number
|
|
46
|
+
/** 填表创建人userid。 */
|
|
47
|
+
creator?: string
|
|
48
|
+
/** 分页游标。 */
|
|
49
|
+
nextToken: number
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
export interface ListFormSchemasByCreatorResponse {
|
|
53
|
+
success?: unknown
|
|
54
|
+
result?: {
|
|
55
|
+
hasMore?: number
|
|
56
|
+
nextToken?: number
|
|
57
|
+
list?: number
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
// funcName: isOldApi
|
|
62
|
+
Internal.define({
|
|
63
|
+
'/swform/instances/{formInstanceId}': { GET: { getFormInstance: false } },
|
|
64
|
+
'/swform/forms/{formCode}/instances': { GET: { listFormInstances: false } },
|
|
65
|
+
'/swform/users/forms': { GET: { listFormSchemasByCreator: false } },
|
|
66
|
+
})
|
|
67
|
+
|
|
68
|
+
declare module '../internal' {
|
|
69
|
+
interface Internal {
|
|
70
|
+
/**
|
|
71
|
+
* 获取单条填表实例详情
|
|
72
|
+
* @see https://open.dingtalk.com/document/isvapp/obtains-the-instance-details-of-a-single-fill-table
|
|
73
|
+
*/
|
|
74
|
+
getFormInstance(
|
|
75
|
+
formInstanceId: string,
|
|
76
|
+
query: GetFormInstanceQuery,
|
|
77
|
+
): Promise<GetFormInstanceResponse>
|
|
78
|
+
/**
|
|
79
|
+
* 获取填表实例列表
|
|
80
|
+
* @see https://open.dingtalk.com/document/isvapp/obtain-the-table-filling-instance-list-data
|
|
81
|
+
*/
|
|
82
|
+
listFormInstances(
|
|
83
|
+
formCode: string,
|
|
84
|
+
query: ListFormInstancesQuery,
|
|
85
|
+
): Promise<ListFormInstancesResponse>
|
|
86
|
+
/**
|
|
87
|
+
* 获取用户创建的填表模板列表
|
|
88
|
+
* @see https://open.dingtalk.com/document/isvapp/new-obtains-the-template-that-a-user-creates
|
|
89
|
+
*/
|
|
90
|
+
listFormSchemasByCreator(
|
|
91
|
+
query: ListFormSchemasByCreatorQuery,
|
|
92
|
+
): Promise<ListFormSchemasByCreatorResponse>
|
|
93
|
+
}
|
|
94
|
+
}
|
package/src/api/todo.ts
ADDED
|
@@ -0,0 +1,220 @@
|
|
|
1
|
+
import { Internal } from '../internal'
|
|
2
|
+
// GENERATED CONTENT
|
|
3
|
+
|
|
4
|
+
export interface QueryOrgTodoTasksParams {
|
|
5
|
+
/** 分页游标。 */
|
|
6
|
+
nextToken?: string
|
|
7
|
+
/** 待办完成状态。 */
|
|
8
|
+
isDone?: unknown
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
export interface QueryOrgTodoTasksResponse {
|
|
12
|
+
nextToken?: string
|
|
13
|
+
todoCards?: {
|
|
14
|
+
taskId?: string
|
|
15
|
+
subject?: string
|
|
16
|
+
dueTime?: number
|
|
17
|
+
detailUrl?: number
|
|
18
|
+
todoCardView?: number
|
|
19
|
+
priority?: number
|
|
20
|
+
createdTime?: number
|
|
21
|
+
modifiedTime?: number
|
|
22
|
+
todoStatus?: string
|
|
23
|
+
creatorId?: string
|
|
24
|
+
sourceId?: string
|
|
25
|
+
category?: string
|
|
26
|
+
bizTag?: string
|
|
27
|
+
originalSource?: number
|
|
28
|
+
isDone?: number
|
|
29
|
+
orgInfo?: number
|
|
30
|
+
}[]
|
|
31
|
+
totalCount?: number
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
export interface UpdateTodoTaskExecutorStatusParams {
|
|
35
|
+
/** 执行者状态列表,id需传用户的unionId。 */
|
|
36
|
+
executorStatusList?: object[]
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
export interface UpdateTodoTaskExecutorStatusQuery {
|
|
40
|
+
/** 当前操作者的用户的unionId。 */
|
|
41
|
+
operatorId?: string
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
export interface UpdateTodoTaskExecutorStatusResponse {
|
|
45
|
+
result?: unknown
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
export interface CreateTodoTaskParams {
|
|
49
|
+
/** 业务系统侧的唯一标识ID,即业务ID。 */
|
|
50
|
+
sourceId?: string
|
|
51
|
+
/** 待办标题,最大长度1024。 */
|
|
52
|
+
subject: string
|
|
53
|
+
/** 创建者的unionId。 */
|
|
54
|
+
creatorId?: string
|
|
55
|
+
/** 待办备注描述,最大长度4096。 */
|
|
56
|
+
description?: string
|
|
57
|
+
/** 截止时间,Unix时间戳,单位毫秒。 */
|
|
58
|
+
dueTime?: number
|
|
59
|
+
/** 执行者的unionId,最大数量1000。 */
|
|
60
|
+
executorIds?: string[]
|
|
61
|
+
/** 参与者的unionId,最大数量1000。 */
|
|
62
|
+
participantIds?: string[]
|
|
63
|
+
/** 详情页url跳转地址。 */
|
|
64
|
+
detailUrl?: unknown
|
|
65
|
+
/** 待办卡片内容区表单自定义字段列表 */
|
|
66
|
+
contentFieldList?: object[]
|
|
67
|
+
/** 生成的待办是否仅展示在执行者的待办列表中。 */
|
|
68
|
+
isOnlyShowExecutor?: unknown
|
|
69
|
+
/** 优先级,取值: */
|
|
70
|
+
priority?: number
|
|
71
|
+
/** 待办通知配置。 */
|
|
72
|
+
notifyConfigs?: unknown
|
|
73
|
+
/** 二级分类。 */
|
|
74
|
+
bizCategoryId?: string
|
|
75
|
+
/** 编辑 */
|
|
76
|
+
actionList?: object[]
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
export interface CreateTodoTaskQuery {
|
|
80
|
+
/** 当前操作者用户的unionId。 */
|
|
81
|
+
operatorId?: string
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
export interface CreateTodoTaskResponse {
|
|
85
|
+
id: string
|
|
86
|
+
subject: string
|
|
87
|
+
description?: string
|
|
88
|
+
startTime?: number
|
|
89
|
+
dueTime?: number
|
|
90
|
+
finishTime?: number
|
|
91
|
+
done?: unknown
|
|
92
|
+
executorIds?: string[]
|
|
93
|
+
participantIds?: string[]
|
|
94
|
+
detailUrl?: {
|
|
95
|
+
pcUrl?: string
|
|
96
|
+
appUrl?: string
|
|
97
|
+
}
|
|
98
|
+
source?: string
|
|
99
|
+
sourceId?: string
|
|
100
|
+
createdTime: number
|
|
101
|
+
modifiedTime?: number
|
|
102
|
+
creatorId: string
|
|
103
|
+
modifierId?: string
|
|
104
|
+
tenantId?: string
|
|
105
|
+
tenantType?: string
|
|
106
|
+
bizTag?: string
|
|
107
|
+
requestId?: string
|
|
108
|
+
cardTypeId?: string
|
|
109
|
+
contentFieldList?: {
|
|
110
|
+
fieldKey?: string
|
|
111
|
+
fieldValue?: string
|
|
112
|
+
}[]
|
|
113
|
+
isOnlyShowExecutor?: unknown
|
|
114
|
+
priority?: number
|
|
115
|
+
sourceTitle?: string
|
|
116
|
+
notifyConfigs?: {
|
|
117
|
+
singleChat?: string
|
|
118
|
+
dingNotify?: string
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
export interface UpdateTodoTaskParams {
|
|
123
|
+
/** 待办标题,最大长度1024。 */
|
|
124
|
+
subject?: string
|
|
125
|
+
/** 待办描述,最大长度4096。 */
|
|
126
|
+
description?: string
|
|
127
|
+
/** 截止时间,Unix时间戳,单位毫秒。 */
|
|
128
|
+
dueTime?: number
|
|
129
|
+
/** 完成状态。 */
|
|
130
|
+
done?: unknown
|
|
131
|
+
/** 执行者的unionId列表,最大数量1000。 */
|
|
132
|
+
executorIds?: string[]
|
|
133
|
+
/** 参与者的unionId列表,最大数量1000。 */
|
|
134
|
+
participantIds?: string[]
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
export interface UpdateTodoTaskQuery {
|
|
138
|
+
/** 当前操作者的unionId。 */
|
|
139
|
+
operatorId?: string
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
export interface UpdateTodoTaskResponse {
|
|
143
|
+
result?: unknown
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
export interface DeleteTodoTaskQuery {
|
|
147
|
+
/** 当前操作者的用户的unionId。 */
|
|
148
|
+
operatorId?: string
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
export interface DeleteTodoTaskResponse {
|
|
152
|
+
result?: unknown
|
|
153
|
+
requestId?: string
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
// funcName: isOldApi
|
|
157
|
+
Internal.define({
|
|
158
|
+
'/todo/users/{unionId}/org/tasks/query': {
|
|
159
|
+
POST: { queryOrgTodoTasks: false },
|
|
160
|
+
},
|
|
161
|
+
'/todo/users/{unionId}/tasks/{taskId}/executorStatus': {
|
|
162
|
+
PUT: { updateTodoTaskExecutorStatus: false },
|
|
163
|
+
},
|
|
164
|
+
'/todo/users/{unionId}/tasks': { POST: { createTodoTask: false } },
|
|
165
|
+
'/todo/users/{unionId}/tasks/{taskId}': {
|
|
166
|
+
PUT: { updateTodoTask: false },
|
|
167
|
+
DELETE: { deleteTodoTask: false },
|
|
168
|
+
},
|
|
169
|
+
})
|
|
170
|
+
|
|
171
|
+
declare module '../internal' {
|
|
172
|
+
interface Internal {
|
|
173
|
+
/**
|
|
174
|
+
* 查询企业下用户待办列表
|
|
175
|
+
* @see https://open.dingtalk.com/document/isvapp/query-the-to-do-list-of-enterprise-users
|
|
176
|
+
*/
|
|
177
|
+
queryOrgTodoTasks(
|
|
178
|
+
unionId: string,
|
|
179
|
+
params: QueryOrgTodoTasksParams,
|
|
180
|
+
): Promise<QueryOrgTodoTasksResponse>
|
|
181
|
+
/**
|
|
182
|
+
* 更新钉钉待办执行者状态
|
|
183
|
+
* @see https://open.dingtalk.com/document/isvapp/update-dingtalk-to-do-status
|
|
184
|
+
*/
|
|
185
|
+
updateTodoTaskExecutorStatus(
|
|
186
|
+
unionId: string,
|
|
187
|
+
taskId: string,
|
|
188
|
+
query: UpdateTodoTaskExecutorStatusQuery,
|
|
189
|
+
params: UpdateTodoTaskExecutorStatusParams,
|
|
190
|
+
): Promise<UpdateTodoTaskExecutorStatusResponse>
|
|
191
|
+
/**
|
|
192
|
+
* 创建待办
|
|
193
|
+
* @see https://open.dingtalk.com/document/isvapp/add-dingtalk-to-do-task
|
|
194
|
+
*/
|
|
195
|
+
createTodoTask(
|
|
196
|
+
unionId: string,
|
|
197
|
+
query: CreateTodoTaskQuery,
|
|
198
|
+
params: CreateTodoTaskParams,
|
|
199
|
+
): Promise<CreateTodoTaskResponse>
|
|
200
|
+
/**
|
|
201
|
+
* 更新钉钉待办任务
|
|
202
|
+
* @see https://open.dingtalk.com/document/isvapp/updates-dingtalk-to-do-tasks
|
|
203
|
+
*/
|
|
204
|
+
updateTodoTask(
|
|
205
|
+
unionId: string,
|
|
206
|
+
taskId: string,
|
|
207
|
+
query: UpdateTodoTaskQuery,
|
|
208
|
+
params: UpdateTodoTaskParams,
|
|
209
|
+
): Promise<UpdateTodoTaskResponse>
|
|
210
|
+
/**
|
|
211
|
+
* 删除钉钉待办任务
|
|
212
|
+
* @see https://open.dingtalk.com/document/isvapp/delete-dingtalk-to-do-tasks
|
|
213
|
+
*/
|
|
214
|
+
deleteTodoTask(
|
|
215
|
+
unionId: string,
|
|
216
|
+
taskId: string,
|
|
217
|
+
query: DeleteTodoTaskQuery,
|
|
218
|
+
): Promise<DeleteTodoTaskResponse>
|
|
219
|
+
}
|
|
220
|
+
}
|
package/src/api/wiki.ts
ADDED
|
@@ -0,0 +1,231 @@
|
|
|
1
|
+
import { Internal } from '../internal'
|
|
2
|
+
// GENERATED CONTENT
|
|
3
|
+
|
|
4
|
+
export interface ListNodesQuery {
|
|
5
|
+
/** 父节点id(父节点dentryUuid): */
|
|
6
|
+
parentNodeId: string
|
|
7
|
+
/** 分页游标, 首次拉取不用传。 */
|
|
8
|
+
nextToken?: string
|
|
9
|
+
/** 分页大小,默认值50。 */
|
|
10
|
+
maxResults?: number
|
|
11
|
+
/** 是否获取权限信息: */
|
|
12
|
+
withPermissionRole?: unknown
|
|
13
|
+
/** 操作人unionId。 */
|
|
14
|
+
operatorId: string
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export interface ListNodesResponse {
|
|
18
|
+
nodes?: {
|
|
19
|
+
nodeId?: string
|
|
20
|
+
workspaceId?: string
|
|
21
|
+
name?: string
|
|
22
|
+
size?: number
|
|
23
|
+
type?: string
|
|
24
|
+
category?: string
|
|
25
|
+
extension?: string
|
|
26
|
+
url?: string
|
|
27
|
+
creatorId?: string
|
|
28
|
+
modifierId?: string
|
|
29
|
+
createTime?: string
|
|
30
|
+
modifiedTime?: string
|
|
31
|
+
hasChildren?: number
|
|
32
|
+
statisticalInfo?: number
|
|
33
|
+
permissionRole?: string
|
|
34
|
+
}[]
|
|
35
|
+
nextToken?: string
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export interface GetNodeByUrlParams {
|
|
39
|
+
/** 文档链接 */
|
|
40
|
+
url: string
|
|
41
|
+
/** 可选参数 */
|
|
42
|
+
option?: unknown
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export interface GetNodeByUrlQuery {
|
|
46
|
+
/** 操作人unionId。 */
|
|
47
|
+
operatorId: string
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
export interface GetNodeByUrlResponse {
|
|
51
|
+
node?: {
|
|
52
|
+
nodeId?: string
|
|
53
|
+
workspaceId?: string
|
|
54
|
+
name?: string
|
|
55
|
+
size?: number
|
|
56
|
+
type?: string
|
|
57
|
+
category?: string
|
|
58
|
+
extension?: string
|
|
59
|
+
url?: string
|
|
60
|
+
creatorId?: string
|
|
61
|
+
modifierId?: string
|
|
62
|
+
createTime?: string
|
|
63
|
+
modifiedTime?: string
|
|
64
|
+
hasChildren?: number
|
|
65
|
+
statisticalInfo?: number
|
|
66
|
+
permissionRole?: string
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
export interface GetNodesParams {
|
|
71
|
+
/** 节点id。 */
|
|
72
|
+
nodeIds: string[]
|
|
73
|
+
/** 可选参数。 */
|
|
74
|
+
option?: unknown
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
export interface GetNodesQuery {
|
|
78
|
+
/** 操作人unionId。 */
|
|
79
|
+
operatorId: string
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
export interface GetNodesResponse {
|
|
83
|
+
nodes?: {
|
|
84
|
+
nodeId?: string
|
|
85
|
+
workspaceId?: string
|
|
86
|
+
name?: string
|
|
87
|
+
size?: number
|
|
88
|
+
type?: string
|
|
89
|
+
category?: string
|
|
90
|
+
extension?: string
|
|
91
|
+
url?: string
|
|
92
|
+
creatorId?: string
|
|
93
|
+
modifierId?: string
|
|
94
|
+
createTime?: string
|
|
95
|
+
modifiedTime?: string
|
|
96
|
+
hasChildren?: number
|
|
97
|
+
statisticalInfo?: number
|
|
98
|
+
permissionRole?: string
|
|
99
|
+
}[]
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
export interface GetNodeQuery {
|
|
103
|
+
/** 是否获取统计信息: */
|
|
104
|
+
withStatisticalInfo?: unknown
|
|
105
|
+
/** 是否获取权限信息: */
|
|
106
|
+
withPermissionRole?: unknown
|
|
107
|
+
/** 操作人unionId。 */
|
|
108
|
+
operatorId: string
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
export interface GetNodeResponse {
|
|
112
|
+
node?: {
|
|
113
|
+
nodeId?: string
|
|
114
|
+
workspaceId?: string
|
|
115
|
+
name?: string
|
|
116
|
+
size?: number
|
|
117
|
+
type?: string
|
|
118
|
+
category?: string
|
|
119
|
+
extension?: string
|
|
120
|
+
url?: string
|
|
121
|
+
creatorId?: string
|
|
122
|
+
modifierId?: string
|
|
123
|
+
createTime?: string
|
|
124
|
+
modifiedTime?: string
|
|
125
|
+
hasChildren?: number
|
|
126
|
+
statisticalInfo?: number
|
|
127
|
+
permissionRole?: string
|
|
128
|
+
}
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
export interface WikiWordsDetailQuery {
|
|
132
|
+
/** 词条名称,最大长度50个字符。 */
|
|
133
|
+
wordName: string
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
export interface WikiWordsDetailResponse {
|
|
137
|
+
data: {
|
|
138
|
+
wordName: string
|
|
139
|
+
uuid: number
|
|
140
|
+
gmtCreate: number
|
|
141
|
+
gmtModify: number
|
|
142
|
+
orgName: string
|
|
143
|
+
wordAlias: number
|
|
144
|
+
highLightWordAlias: number
|
|
145
|
+
wordFullName: string
|
|
146
|
+
relatedDoc: number
|
|
147
|
+
relatedLink: number
|
|
148
|
+
creatorName: string
|
|
149
|
+
updaterName: string
|
|
150
|
+
approveName: string
|
|
151
|
+
wordParaphrase: string
|
|
152
|
+
simpleWordParaphrase: string
|
|
153
|
+
contacts: number
|
|
154
|
+
tagsList: number
|
|
155
|
+
appLink: number
|
|
156
|
+
imHighLight: number
|
|
157
|
+
simHighLight: number
|
|
158
|
+
}[]
|
|
159
|
+
errMsg: string
|
|
160
|
+
success: unknown
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
export interface WikiWordsParseParams {
|
|
164
|
+
/** 待匹配词条的文本,最大长度4096个字符。 */
|
|
165
|
+
content: string
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
export interface WikiWordsParseResponse {
|
|
169
|
+
success?: unknown
|
|
170
|
+
errMsg: string
|
|
171
|
+
data: {
|
|
172
|
+
startIndex: number
|
|
173
|
+
endIndex: number
|
|
174
|
+
wordName: string
|
|
175
|
+
}[]
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
// funcName: isOldApi
|
|
179
|
+
Internal.define({
|
|
180
|
+
'/wiki/nodes': { GET: { listNodes: false } },
|
|
181
|
+
'/wiki/nodes/queryByUrl': { POST: { getNodeByUrl: false } },
|
|
182
|
+
'/wiki/nodes/batchQuery': { POST: { getNodes: false } },
|
|
183
|
+
'/wiki/nodes/{nodeId}': { GET: { getNode: false } },
|
|
184
|
+
'/wiki/words/details': { GET: { wikiWordsDetail: false } },
|
|
185
|
+
'/wiki/words/parse': { POST: { wikiWordsParse: false } },
|
|
186
|
+
})
|
|
187
|
+
|
|
188
|
+
declare module '../internal' {
|
|
189
|
+
interface Internal {
|
|
190
|
+
/**
|
|
191
|
+
* 获取节点列表
|
|
192
|
+
* @see https://open.dingtalk.com/document/orgapp/get-node-list
|
|
193
|
+
*/
|
|
194
|
+
listNodes(query: ListNodesQuery): Promise<ListNodesResponse>
|
|
195
|
+
/**
|
|
196
|
+
* 通过链接获取节点
|
|
197
|
+
* @see https://open.dingtalk.com/document/orgapp/get-node-by-link
|
|
198
|
+
*/
|
|
199
|
+
getNodeByUrl(
|
|
200
|
+
query: GetNodeByUrlQuery,
|
|
201
|
+
params: GetNodeByUrlParams,
|
|
202
|
+
): Promise<GetNodeByUrlResponse>
|
|
203
|
+
/**
|
|
204
|
+
* 批量获取节点
|
|
205
|
+
* @see https://open.dingtalk.com/document/orgapp/obtain-nodes-in-batch
|
|
206
|
+
*/
|
|
207
|
+
getNodes(
|
|
208
|
+
query: GetNodesQuery,
|
|
209
|
+
params: GetNodesParams,
|
|
210
|
+
): Promise<GetNodesResponse>
|
|
211
|
+
/**
|
|
212
|
+
* 获取节点
|
|
213
|
+
* @see https://open.dingtalk.com/document/orgapp/get-node
|
|
214
|
+
*/
|
|
215
|
+
getNode(nodeId: string, query: GetNodeQuery): Promise<GetNodeResponse>
|
|
216
|
+
/**
|
|
217
|
+
* 根据词条名称获取该词条释义
|
|
218
|
+
* @see https://open.dingtalk.com/document/orgapp/enterprise-encyclopedia-query-entry-details-by-entry-name
|
|
219
|
+
*/
|
|
220
|
+
wikiWordsDetail(
|
|
221
|
+
query: WikiWordsDetailQuery,
|
|
222
|
+
): Promise<WikiWordsDetailResponse>
|
|
223
|
+
/**
|
|
224
|
+
* 外部传递过来的消息根据百科词库分词
|
|
225
|
+
* @see https://open.dingtalk.com/document/orgapp/enterprise-encyclopedia-match-entries-in-a-text
|
|
226
|
+
*/
|
|
227
|
+
wikiWordsParse(
|
|
228
|
+
params: WikiWordsParseParams,
|
|
229
|
+
): Promise<WikiWordsParseResponse>
|
|
230
|
+
}
|
|
231
|
+
}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import { Internal } from '../internal'
|
|
2
|
+
// GENERATED CONTENT
|
|
3
|
+
|
|
4
|
+
export interface AddRecentUserAppListParams {
|
|
5
|
+
/** 组织CorpId */
|
|
6
|
+
corpId: string
|
|
7
|
+
/** 最近使用应用列表 */
|
|
8
|
+
usedAppDetailList: object[]
|
|
9
|
+
/** 员工staffId */
|
|
10
|
+
userId: string
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export interface AddRecentUserAppListResponse {
|
|
14
|
+
result: unknown
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
export interface GetPluginRuleCheckInfoQuery {
|
|
18
|
+
/** 插件的appId。 */
|
|
19
|
+
miniAppId?: string
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
export interface GetPluginRuleCheckInfoResponse {
|
|
23
|
+
packCode?: string
|
|
24
|
+
pluginRuleCheckDetail?: string
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
export interface GetPluginPermissionPointQuery {
|
|
28
|
+
/** 插件ID。 */
|
|
29
|
+
miniAppId?: string
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
export interface GetPluginPermissionPointResponse {
|
|
33
|
+
permissionPointList?: string[]
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
// funcName: isOldApi
|
|
37
|
+
Internal.define({
|
|
38
|
+
'/workbench/components/recentUsed/batch': {
|
|
39
|
+
POST: { addRecentUserAppList: false },
|
|
40
|
+
},
|
|
41
|
+
'/workbench/plugins/validationRules': {
|
|
42
|
+
GET: { getPluginRuleCheckInfo: false },
|
|
43
|
+
},
|
|
44
|
+
'/workbench/plugins/permissions': {
|
|
45
|
+
GET: { getPluginPermissionPoint: false },
|
|
46
|
+
},
|
|
47
|
+
})
|
|
48
|
+
|
|
49
|
+
declare module '../internal' {
|
|
50
|
+
interface Internal {
|
|
51
|
+
/**
|
|
52
|
+
* 批量添加最近使用记录
|
|
53
|
+
* @see https://open.dingtalk.com/document/app/add-recently-used-apps-in-bulk
|
|
54
|
+
*/
|
|
55
|
+
addRecentUserAppList(
|
|
56
|
+
params: AddRecentUserAppListParams,
|
|
57
|
+
): Promise<AddRecentUserAppListResponse>
|
|
58
|
+
/**
|
|
59
|
+
* 获取插件的校验规则
|
|
60
|
+
* @see https://open.dingtalk.com/document/dashboard/you-can-call-this-operation-to-obtain-the-information-about
|
|
61
|
+
*/
|
|
62
|
+
getPluginRuleCheckInfo(
|
|
63
|
+
query: GetPluginRuleCheckInfoQuery,
|
|
64
|
+
): Promise<GetPluginRuleCheckInfoResponse>
|
|
65
|
+
/**
|
|
66
|
+
* 获取工作台插件的权限点
|
|
67
|
+
* @see https://open.dingtalk.com/document/dashboard/obtain-the-permissions-of-the-workbench-plug-in
|
|
68
|
+
*/
|
|
69
|
+
getPluginPermissionPoint(
|
|
70
|
+
query: GetPluginPermissionPointQuery,
|
|
71
|
+
): Promise<GetPluginPermissionPointResponse>
|
|
72
|
+
}
|
|
73
|
+
}
|