@im-more/dsh-dingtalk 0.0.0-stage → 0.1.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/LICENSE +21 -0
- package/cordis.patch.yml +11 -0
- package/lib/index.js +2765 -0
- package/lib/index.js.map +1 -0
- package/lib/types/api/alitrip.d.ts +397 -0
- package/lib/types/api/alitrip.d.ts.map +1 -0
- package/lib/types/api/alitrip.js +21 -0
- package/lib/types/api/alitrip.js.map +1 -0
- package/lib/types/api/attendance.d.ts +63 -0
- package/lib/types/api/attendance.d.ts.map +1 -0
- package/lib/types/api/attendance.js +8 -0
- package/lib/types/api/attendance.js.map +1 -0
- package/lib/types/api/badge.d.ts +233 -0
- package/lib/types/api/badge.d.ts.map +1 -0
- package/lib/types/api/badge.js +19 -0
- package/lib/types/api/badge.js.map +1 -0
- package/lib/types/api/blackboard.d.ts +17 -0
- package/lib/types/api/blackboard.d.ts.map +1 -0
- package/lib/types/api/blackboard.js +6 -0
- package/lib/types/api/blackboard.js.map +1 -0
- package/lib/types/api/calendar.d.ts +621 -0
- package/lib/types/api/calendar.d.ts.map +1 -0
- package/lib/types/api/calendar.js +57 -0
- package/lib/types/api/calendar.js.map +1 -0
- package/lib/types/api/card.d.ts +185 -0
- package/lib/types/api/card.d.ts.map +1 -0
- package/lib/types/api/card.js +13 -0
- package/lib/types/api/card.js.map +1 -0
- package/lib/types/api/conference.d.ts +404 -0
- package/lib/types/api/conference.d.ts.map +1 -0
- package/lib/types/api/conference.js +60 -0
- package/lib/types/api/conference.js.map +1 -0
- package/lib/types/api/connector.d.ts +79 -0
- package/lib/types/api/connector.d.ts.map +1 -0
- package/lib/types/api/connector.js +8 -0
- package/lib/types/api/connector.js.map +1 -0
- package/lib/types/api/contact.d.ts +40 -0
- package/lib/types/api/contact.d.ts.map +1 -0
- package/lib/types/api/contact.js +9 -0
- package/lib/types/api/contact.js.map +1 -0
- package/lib/types/api/convFile.d.ts +135 -0
- package/lib/types/api/convFile.d.ts.map +1 -0
- package/lib/types/api/convFile.js +9 -0
- package/lib/types/api/convFile.js.map +1 -0
- package/lib/types/api/crm.d.ts +662 -0
- package/lib/types/api/crm.d.ts.map +1 -0
- package/lib/types/api/crm.js +59 -0
- package/lib/types/api/crm.js.map +1 -0
- package/lib/types/api/customerService.d.ts +128 -0
- package/lib/types/api/customerService.d.ts.map +1 -0
- package/lib/types/api/customerService.js +13 -0
- package/lib/types/api/customerService.js.map +1 -0
- package/lib/types/api/datacenter.d.ts +506 -0
- package/lib/types/api/datacenter.d.ts.map +1 -0
- package/lib/types/api/datacenter.js +61 -0
- package/lib/types/api/datacenter.js.map +1 -0
- package/lib/types/api/devicemng.d.ts +161 -0
- package/lib/types/api/devicemng.d.ts.map +1 -0
- package/lib/types/api/devicemng.js +20 -0
- package/lib/types/api/devicemng.js.map +1 -0
- package/lib/types/api/diot.d.ts +13 -0
- package/lib/types/api/diot.d.ts.map +1 -0
- package/lib/types/api/diot.js +4 -0
- package/lib/types/api/diot.js.map +1 -0
- package/lib/types/api/doc.d.ts +141 -0
- package/lib/types/api/doc.d.ts.map +1 -0
- package/lib/types/api/doc.js +27 -0
- package/lib/types/api/doc.js.map +1 -0
- package/lib/types/api/drive.d.ts +88 -0
- package/lib/types/api/drive.d.ts.map +1 -0
- package/lib/types/api/drive.js +11 -0
- package/lib/types/api/drive.js.map +1 -0
- package/lib/types/api/edu.d.ts +23 -0
- package/lib/types/api/edu.d.ts.map +1 -0
- package/lib/types/api/edu.js +4 -0
- package/lib/types/api/edu.js.map +1 -0
- package/lib/types/api/esign.d.ts +34 -0
- package/lib/types/api/esign.d.ts.map +1 -0
- package/lib/types/api/esign.js +7 -0
- package/lib/types/api/esign.js.map +1 -0
- package/lib/types/api/exclusive.d.ts +304 -0
- package/lib/types/api/exclusive.d.ts.map +1 -0
- package/lib/types/api/exclusive.js +27 -0
- package/lib/types/api/exclusive.js.map +1 -0
- package/lib/types/api/h3yun.d.ts +438 -0
- package/lib/types/api/h3yun.d.ts.map +1 -0
- package/lib/types/api/h3yun.js +33 -0
- package/lib/types/api/h3yun.js.map +1 -0
- package/lib/types/api/hrm.d.ts +215 -0
- package/lib/types/api/hrm.d.ts.map +1 -0
- package/lib/types/api/hrm.js +20 -0
- package/lib/types/api/hrm.js.map +1 -0
- package/lib/types/api/im.d.ts +773 -0
- package/lib/types/api/im.d.ts.map +1 -0
- package/lib/types/api/im.js +72 -0
- package/lib/types/api/im.js.map +1 -0
- package/lib/types/api/industry.d.ts +118 -0
- package/lib/types/api/industry.d.ts.map +1 -0
- package/lib/types/api/industry.js +14 -0
- package/lib/types/api/industry.js.map +1 -0
- package/lib/types/api/jzcrm.d.ts +255 -0
- package/lib/types/api/jzcrm.d.ts.map +1 -0
- package/lib/types/api/jzcrm.js +18 -0
- package/lib/types/api/jzcrm.js.map +1 -0
- package/lib/types/api/link.d.ts +73 -0
- package/lib/types/api/link.d.ts.map +1 -0
- package/lib/types/api/link.js +9 -0
- package/lib/types/api/link.js.map +1 -0
- package/lib/types/api/live.d.ts +132 -0
- package/lib/types/api/live.d.ts.map +1 -0
- package/lib/types/api/live.js +13 -0
- package/lib/types/api/live.js.map +1 -0
- package/lib/types/api/microApp.d.ts +240 -0
- package/lib/types/api/microApp.d.ts.map +1 -0
- package/lib/types/api/microApp.js +29 -0
- package/lib/types/api/microApp.js.map +1 -0
- package/lib/types/api/oapi.d.ts +3362 -0
- package/lib/types/api/oapi.d.ts.map +1 -0
- package/lib/types/api/oapi.js +247 -0
- package/lib/types/api/oapi.js.map +1 -0
- package/lib/types/api/oauth2.d.ts +115 -0
- package/lib/types/api/oauth2.d.ts.map +1 -0
- package/lib/types/api/oauth2.js +12 -0
- package/lib/types/api/oauth2.js.map +1 -0
- package/lib/types/api/pedia.d.ts +186 -0
- package/lib/types/api/pedia.d.ts.map +1 -0
- package/lib/types/api/pedia.js +13 -0
- package/lib/types/api/pedia.js.map +1 -0
- package/lib/types/api/project.d.ts +1119 -0
- package/lib/types/api/project.d.ts.map +1 -0
- package/lib/types/api/project.js +135 -0
- package/lib/types/api/project.js.map +1 -0
- package/lib/types/api/resident.d.ts +107 -0
- package/lib/types/api/resident.d.ts.map +1 -0
- package/lib/types/api/resident.js +10 -0
- package/lib/types/api/resident.js.map +1 -0
- package/lib/types/api/robot.d.ts +256 -0
- package/lib/types/api/robot.d.ts.map +1 -0
- package/lib/types/api/robot.js +21 -0
- package/lib/types/api/robot.js.map +1 -0
- package/lib/types/api/rooms.d.ts +256 -0
- package/lib/types/api/rooms.d.ts.map +1 -0
- package/lib/types/api/rooms.js +23 -0
- package/lib/types/api/rooms.js.map +1 -0
- package/lib/types/api/serviceGroup.d.ts +176 -0
- package/lib/types/api/serviceGroup.d.ts.map +1 -0
- package/lib/types/api/serviceGroup.js +15 -0
- package/lib/types/api/serviceGroup.js.map +1 -0
- package/lib/types/api/storage.d.ts +1241 -0
- package/lib/types/api/storage.d.ts.map +1 -0
- package/lib/types/api/storage.js +128 -0
- package/lib/types/api/storage.js.map +1 -0
- package/lib/types/api/swform.d.ts +71 -0
- package/lib/types/api/swform.d.ts.map +1 -0
- package/lib/types/api/swform.js +8 -0
- package/lib/types/api/swform.js.map +1 -0
- package/lib/types/api/todo.d.ts +169 -0
- package/lib/types/api/todo.d.ts.map +1 -0
- package/lib/types/api/todo.js +16 -0
- package/lib/types/api/todo.js.map +1 -0
- package/lib/types/api/wiki.d.ts +195 -0
- package/lib/types/api/wiki.d.ts.map +1 -0
- package/lib/types/api/wiki.js +11 -0
- package/lib/types/api/wiki.js.map +1 -0
- package/lib/types/api/workbench.d.ts +46 -0
- package/lib/types/api/workbench.d.ts.map +1 -0
- package/lib/types/api/workbench.js +14 -0
- package/lib/types/api/workbench.js.map +1 -0
- package/lib/types/api/yida.d.ts +1838 -0
- package/lib/types/api/yida.d.ts.map +1 -0
- package/lib/types/api/yida.js +103 -0
- package/lib/types/api/yida.js.map +1 -0
- package/lib/types/bot.d.ts +62 -0
- package/lib/types/bot.d.ts.map +1 -0
- package/lib/types/bot.js +134 -0
- package/lib/types/bot.js.map +1 -0
- package/lib/types/config.d.ts +47 -0
- package/lib/types/config.d.ts.map +1 -0
- package/lib/types/config.js +53 -0
- package/lib/types/config.js.map +1 -0
- package/lib/types/decode.d.ts +36 -0
- package/lib/types/decode.d.ts.map +1 -0
- package/lib/types/decode.js +200 -0
- package/lib/types/decode.js.map +1 -0
- package/lib/types/errors.d.ts +77 -0
- package/lib/types/errors.d.ts.map +1 -0
- package/lib/types/errors.js +249 -0
- package/lib/types/errors.js.map +1 -0
- package/lib/types/index.d.ts +22 -0
- package/lib/types/index.d.ts.map +1 -0
- package/lib/types/index.js +22 -0
- package/lib/types/index.js.map +1 -0
- package/lib/types/internal.d.ts +15 -0
- package/lib/types/internal.d.ts.map +1 -0
- package/lib/types/internal.js +57 -0
- package/lib/types/internal.js.map +1 -0
- package/lib/types/media.d.ts +57 -0
- package/lib/types/media.d.ts.map +1 -0
- package/lib/types/media.js +99 -0
- package/lib/types/media.js.map +1 -0
- package/lib/types/modes/markdown.d.ts +12 -0
- package/lib/types/modes/markdown.d.ts.map +1 -0
- package/lib/types/modes/markdown.js +148 -0
- package/lib/types/modes/markdown.js.map +1 -0
- package/lib/types/modes/shared.d.ts +183 -0
- package/lib/types/modes/shared.d.ts.map +1 -0
- package/lib/types/modes/shared.js +358 -0
- package/lib/types/modes/shared.js.map +1 -0
- package/lib/types/request.d.ts +63 -0
- package/lib/types/request.d.ts.map +1 -0
- package/lib/types/request.js +182 -0
- package/lib/types/request.js.map +1 -0
- package/lib/types/send.d.ts +38 -0
- package/lib/types/send.d.ts.map +1 -0
- package/lib/types/send.js +128 -0
- package/lib/types/send.js.map +1 -0
- package/lib/types/token.d.ts +32 -0
- package/lib/types/token.d.ts.map +1 -0
- package/lib/types/token.js +62 -0
- package/lib/types/token.js.map +1 -0
- package/lib/types/transport/stream.d.ts +89 -0
- package/lib/types/transport/stream.d.ts.map +1 -0
- package/lib/types/transport/stream.js +345 -0
- package/lib/types/transport/stream.js.map +1 -0
- package/lib/types/transport/webhook.d.ts +54 -0
- package/lib/types/transport/webhook.d.ts.map +1 -0
- package/lib/types/transport/webhook.js +159 -0
- package/lib/types/transport/webhook.js.map +1 -0
- package/lib/types/types/index.d.ts +150 -0
- package/lib/types/types/index.d.ts.map +1 -0
- package/lib/types/types/index.js +43 -0
- package/lib/types/types/index.js.map +1 -0
- package/package.json +61 -3
- 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 +211 -0
- package/src/config.ts +88 -0
- package/src/decode.ts +250 -0
- package/src/errors.ts +282 -0
- package/src/index.ts +82 -0
- package/src/internal.ts +60 -0
- package/src/media.ts +149 -0
- package/src/modes/markdown.ts +173 -0
- package/src/modes/shared.ts +473 -0
- package/src/request.ts +262 -0
- package/src/send.ts +195 -0
- package/src/token.ts +72 -0
- package/src/transport/stream.ts +436 -0
- package/src/transport/webhook.ts +198 -0
- package/src/types/index.ts +165 -0
- package/README.md +0 -3
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { Internal } from '../internal.ts'
|
|
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.ts'
|
|
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.ts'
|
|
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.ts'
|
|
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
|
+
}
|