@chatablex/erp-pro-tool 3.2.2
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/meta.json +5 -0
- package/package.json +475 -0
package/meta.json
ADDED
package/package.json
ADDED
|
@@ -0,0 +1,475 @@
|
|
|
1
|
+
{
|
|
2
|
+
"author": "Co-Work Official",
|
|
3
|
+
"chatablex": {
|
|
4
|
+
"actions": [
|
|
5
|
+
{
|
|
6
|
+
"confirmation_level": 0,
|
|
7
|
+
"description": "查询 ERP 系统中的用户列表,支持分页、关键词搜索和角色/状态筛选。",
|
|
8
|
+
"endpoint": "GET /api/v1/system/users",
|
|
9
|
+
"name": "user_list",
|
|
10
|
+
"parameters": [
|
|
11
|
+
{
|
|
12
|
+
"default": 1,
|
|
13
|
+
"description": "分页页码,从1开始",
|
|
14
|
+
"name": "page",
|
|
15
|
+
"type": "integer"
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
"default": 20,
|
|
19
|
+
"description": "每页数量,最大100",
|
|
20
|
+
"name": "page_size",
|
|
21
|
+
"type": "integer"
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
"description": "搜索关键词(用户名模糊匹配)",
|
|
25
|
+
"name": "keyword",
|
|
26
|
+
"type": "string"
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
"description": "按角色筛选",
|
|
30
|
+
"enum": [
|
|
31
|
+
"admin",
|
|
32
|
+
"manager",
|
|
33
|
+
"operator",
|
|
34
|
+
"viewer"
|
|
35
|
+
],
|
|
36
|
+
"name": "role",
|
|
37
|
+
"type": "string"
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
"description": "按状态筛选",
|
|
41
|
+
"name": "status",
|
|
42
|
+
"type": "string"
|
|
43
|
+
}
|
|
44
|
+
],
|
|
45
|
+
"when_to_use": "用户询问'有多少用户'、'查看用户列表'、'搜索用户xxx'等场景"
|
|
46
|
+
},
|
|
47
|
+
{
|
|
48
|
+
"confirmation_level": 0,
|
|
49
|
+
"description": "根据用户 ID 获取单个用户的详细信息。",
|
|
50
|
+
"endpoint": "GET /api/v1/system/users/:id",
|
|
51
|
+
"name": "user_get",
|
|
52
|
+
"parameters": [
|
|
53
|
+
{
|
|
54
|
+
"description": "用户ID",
|
|
55
|
+
"name": "user_id",
|
|
56
|
+
"required": true,
|
|
57
|
+
"type": "integer"
|
|
58
|
+
}
|
|
59
|
+
],
|
|
60
|
+
"when_to_use": "用户询问'查看用户ID为xxx的信息'、'这个用户是什么角色'等场景"
|
|
61
|
+
},
|
|
62
|
+
{
|
|
63
|
+
"confirm_mode": "platform",
|
|
64
|
+
"confirmation_level": 1,
|
|
65
|
+
"description": "创建新用户,平台会在执行前弹出确认卡片让用户确认。",
|
|
66
|
+
"endpoint": "POST /api/v1/system/users",
|
|
67
|
+
"name": "user_create",
|
|
68
|
+
"parameters": [
|
|
69
|
+
{
|
|
70
|
+
"description": "手机号(11位)",
|
|
71
|
+
"name": "phone",
|
|
72
|
+
"required": true,
|
|
73
|
+
"type": "string"
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
"description": "初始密码(至少6字符)",
|
|
77
|
+
"name": "password",
|
|
78
|
+
"required": true,
|
|
79
|
+
"type": "string"
|
|
80
|
+
},
|
|
81
|
+
{
|
|
82
|
+
"description": "用户名",
|
|
83
|
+
"name": "username",
|
|
84
|
+
"type": "string"
|
|
85
|
+
},
|
|
86
|
+
{
|
|
87
|
+
"description": "角色",
|
|
88
|
+
"enum": [
|
|
89
|
+
"admin",
|
|
90
|
+
"manager",
|
|
91
|
+
"operator",
|
|
92
|
+
"viewer"
|
|
93
|
+
],
|
|
94
|
+
"name": "role",
|
|
95
|
+
"required": true,
|
|
96
|
+
"type": "string"
|
|
97
|
+
}
|
|
98
|
+
],
|
|
99
|
+
"when_to_use": "用户说'创建新用户'、'添加用户xxx'等场景"
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
"confirm_mode": "platform",
|
|
103
|
+
"confirmation_level": 3,
|
|
104
|
+
"description": "【危险】删除指定用户,不可逆。平台会在执行前弹出危险确认卡片。",
|
|
105
|
+
"endpoint": "DELETE /api/v1/system/users/:id",
|
|
106
|
+
"name": "user_delete",
|
|
107
|
+
"parameters": [
|
|
108
|
+
{
|
|
109
|
+
"description": "要删除的用户ID",
|
|
110
|
+
"name": "user_id",
|
|
111
|
+
"required": true,
|
|
112
|
+
"type": "integer"
|
|
113
|
+
},
|
|
114
|
+
{
|
|
115
|
+
"description": "删除原因(审计日志)",
|
|
116
|
+
"name": "reason",
|
|
117
|
+
"type": "string"
|
|
118
|
+
}
|
|
119
|
+
],
|
|
120
|
+
"warning_level": "dangerous",
|
|
121
|
+
"when_to_use": "用户说'删除用户xxx'、'移除账号'等场景"
|
|
122
|
+
},
|
|
123
|
+
{
|
|
124
|
+
"confirmation_level": 0,
|
|
125
|
+
"description": "查询公司列表,返回所有公司的基本信息。",
|
|
126
|
+
"endpoint": "GET /api/v1/companies",
|
|
127
|
+
"name": "company_list",
|
|
128
|
+
"parameters": [],
|
|
129
|
+
"when_to_use": "用户询问'有哪些公司'、'查看公司列表'等场景"
|
|
130
|
+
},
|
|
131
|
+
{
|
|
132
|
+
"confirm_mode": "platform",
|
|
133
|
+
"confirmation_level": 1,
|
|
134
|
+
"description": "创建新公司,平台会在执行前弹出确认卡片让用户确认。",
|
|
135
|
+
"endpoint": "POST /api/v1/companies",
|
|
136
|
+
"name": "company_create",
|
|
137
|
+
"parameters": [
|
|
138
|
+
{
|
|
139
|
+
"description": "公司名称(1-200字符)",
|
|
140
|
+
"name": "name",
|
|
141
|
+
"required": true,
|
|
142
|
+
"type": "string"
|
|
143
|
+
},
|
|
144
|
+
{
|
|
145
|
+
"description": "公司地址",
|
|
146
|
+
"name": "address",
|
|
147
|
+
"type": "string"
|
|
148
|
+
},
|
|
149
|
+
{
|
|
150
|
+
"description": "联系电话",
|
|
151
|
+
"name": "phone",
|
|
152
|
+
"type": "string"
|
|
153
|
+
},
|
|
154
|
+
{
|
|
155
|
+
"description": "联系邮箱",
|
|
156
|
+
"name": "email",
|
|
157
|
+
"type": "string"
|
|
158
|
+
},
|
|
159
|
+
{
|
|
160
|
+
"description": "公司简介",
|
|
161
|
+
"name": "description",
|
|
162
|
+
"type": "string"
|
|
163
|
+
}
|
|
164
|
+
],
|
|
165
|
+
"when_to_use": "用户说'创建公司'、'新增公司xxx'等场景"
|
|
166
|
+
},
|
|
167
|
+
{
|
|
168
|
+
"confirmation_level": 0,
|
|
169
|
+
"description": "查询商品列表,支持分页、关键词(名称/SKU)和分类/状态筛选。",
|
|
170
|
+
"endpoint": "GET /api/v1/products",
|
|
171
|
+
"name": "product_list",
|
|
172
|
+
"parameters": [
|
|
173
|
+
{
|
|
174
|
+
"default": 1,
|
|
175
|
+
"description": "分页页码",
|
|
176
|
+
"name": "page",
|
|
177
|
+
"type": "integer"
|
|
178
|
+
},
|
|
179
|
+
{
|
|
180
|
+
"default": 20,
|
|
181
|
+
"description": "每页数量,最大100",
|
|
182
|
+
"name": "page_size",
|
|
183
|
+
"type": "integer"
|
|
184
|
+
},
|
|
185
|
+
{
|
|
186
|
+
"description": "关键词(名称或SKU模糊)",
|
|
187
|
+
"name": "keyword",
|
|
188
|
+
"type": "string"
|
|
189
|
+
},
|
|
190
|
+
{
|
|
191
|
+
"description": "分类筛选",
|
|
192
|
+
"name": "category",
|
|
193
|
+
"type": "string"
|
|
194
|
+
},
|
|
195
|
+
{
|
|
196
|
+
"description": "状态筛选",
|
|
197
|
+
"name": "status",
|
|
198
|
+
"type": "string"
|
|
199
|
+
}
|
|
200
|
+
],
|
|
201
|
+
"when_to_use": "用户询问'有哪些商品'、'查商品列表'、'搜索商品xxx'等场景"
|
|
202
|
+
},
|
|
203
|
+
{
|
|
204
|
+
"confirm_mode": "platform",
|
|
205
|
+
"confirmation_level": 1,
|
|
206
|
+
"description": "创建新商品,平台会在执行前弹出确认卡片让用户确认。",
|
|
207
|
+
"endpoint": "POST /api/v1/products",
|
|
208
|
+
"name": "product_create",
|
|
209
|
+
"parameters": [
|
|
210
|
+
{
|
|
211
|
+
"description": "商品编码,唯一",
|
|
212
|
+
"name": "sku",
|
|
213
|
+
"required": true,
|
|
214
|
+
"type": "string"
|
|
215
|
+
},
|
|
216
|
+
{
|
|
217
|
+
"description": "商品名称",
|
|
218
|
+
"name": "name",
|
|
219
|
+
"required": true,
|
|
220
|
+
"type": "string"
|
|
221
|
+
},
|
|
222
|
+
{
|
|
223
|
+
"description": "分类",
|
|
224
|
+
"name": "category",
|
|
225
|
+
"type": "string"
|
|
226
|
+
},
|
|
227
|
+
{
|
|
228
|
+
"description": "单位",
|
|
229
|
+
"name": "unit",
|
|
230
|
+
"type": "string"
|
|
231
|
+
},
|
|
232
|
+
{
|
|
233
|
+
"description": "售价",
|
|
234
|
+
"name": "price",
|
|
235
|
+
"required": true,
|
|
236
|
+
"type": "number"
|
|
237
|
+
},
|
|
238
|
+
{
|
|
239
|
+
"description": "成本",
|
|
240
|
+
"name": "cost",
|
|
241
|
+
"type": "number"
|
|
242
|
+
}
|
|
243
|
+
],
|
|
244
|
+
"when_to_use": "用户说'新建商品'、'添加商品xxx'等场景"
|
|
245
|
+
},
|
|
246
|
+
{
|
|
247
|
+
"confirmation_level": 0,
|
|
248
|
+
"description": "查询库存列表,支持分页和关键词(商品名称/SKU)。",
|
|
249
|
+
"endpoint": "GET /api/v1/inventory",
|
|
250
|
+
"name": "inventory_list",
|
|
251
|
+
"parameters": [
|
|
252
|
+
{
|
|
253
|
+
"default": 1,
|
|
254
|
+
"description": "分页页码",
|
|
255
|
+
"name": "page",
|
|
256
|
+
"type": "integer"
|
|
257
|
+
},
|
|
258
|
+
{
|
|
259
|
+
"default": 20,
|
|
260
|
+
"description": "每页数量",
|
|
261
|
+
"name": "page_size",
|
|
262
|
+
"type": "integer"
|
|
263
|
+
},
|
|
264
|
+
{
|
|
265
|
+
"description": "关键词",
|
|
266
|
+
"name": "keyword",
|
|
267
|
+
"type": "string"
|
|
268
|
+
}
|
|
269
|
+
],
|
|
270
|
+
"when_to_use": "用户询问'库存有多少'、'查库存列表'等场景"
|
|
271
|
+
},
|
|
272
|
+
{
|
|
273
|
+
"confirm_mode": "platform",
|
|
274
|
+
"confirmation_level": 1,
|
|
275
|
+
"description": "调整库存(正数入库、负数出库),平台会在执行前弹出确认卡片。",
|
|
276
|
+
"endpoint": "POST /api/v1/inventory/adjust",
|
|
277
|
+
"name": "inventory_adjust",
|
|
278
|
+
"parameters": [
|
|
279
|
+
{
|
|
280
|
+
"description": "商品ID",
|
|
281
|
+
"name": "product_id",
|
|
282
|
+
"required": true,
|
|
283
|
+
"type": "integer"
|
|
284
|
+
},
|
|
285
|
+
{
|
|
286
|
+
"description": "变动数量,正为入库负为出库",
|
|
287
|
+
"name": "quantity",
|
|
288
|
+
"required": true,
|
|
289
|
+
"type": "integer"
|
|
290
|
+
},
|
|
291
|
+
{
|
|
292
|
+
"description": "备注",
|
|
293
|
+
"name": "remark",
|
|
294
|
+
"type": "string"
|
|
295
|
+
}
|
|
296
|
+
],
|
|
297
|
+
"when_to_use": "用户说'入库xxx件'、'出库xxx'、'调整库存'等场景"
|
|
298
|
+
},
|
|
299
|
+
{
|
|
300
|
+
"confirmation_level": 0,
|
|
301
|
+
"description": "查询订单列表,支持分页、类型(销售/采购)和状态筛选。",
|
|
302
|
+
"endpoint": "GET /api/v1/orders",
|
|
303
|
+
"name": "order_list",
|
|
304
|
+
"parameters": [
|
|
305
|
+
{
|
|
306
|
+
"default": 1,
|
|
307
|
+
"description": "分页页码",
|
|
308
|
+
"name": "page",
|
|
309
|
+
"type": "integer"
|
|
310
|
+
},
|
|
311
|
+
{
|
|
312
|
+
"default": 20,
|
|
313
|
+
"description": "每页数量",
|
|
314
|
+
"name": "page_size",
|
|
315
|
+
"type": "integer"
|
|
316
|
+
},
|
|
317
|
+
{
|
|
318
|
+
"description": "订单类型",
|
|
319
|
+
"enum": [
|
|
320
|
+
"sale",
|
|
321
|
+
"purchase"
|
|
322
|
+
],
|
|
323
|
+
"name": "order_type",
|
|
324
|
+
"type": "string"
|
|
325
|
+
},
|
|
326
|
+
{
|
|
327
|
+
"description": "状态",
|
|
328
|
+
"name": "status",
|
|
329
|
+
"type": "string"
|
|
330
|
+
},
|
|
331
|
+
{
|
|
332
|
+
"description": "订单号模糊",
|
|
333
|
+
"name": "keyword",
|
|
334
|
+
"type": "string"
|
|
335
|
+
}
|
|
336
|
+
],
|
|
337
|
+
"when_to_use": "用户询问'有哪些订单'、'查订单列表'等场景"
|
|
338
|
+
},
|
|
339
|
+
{
|
|
340
|
+
"confirm_mode": "platform",
|
|
341
|
+
"confirmation_level": 1,
|
|
342
|
+
"description": "创建销售单或采购单,平台会在执行前弹出确认卡片让用户确认。",
|
|
343
|
+
"endpoint": "POST /api/v1/orders",
|
|
344
|
+
"name": "order_create",
|
|
345
|
+
"parameters": [
|
|
346
|
+
{
|
|
347
|
+
"description": "订单类型",
|
|
348
|
+
"enum": [
|
|
349
|
+
"sale",
|
|
350
|
+
"purchase"
|
|
351
|
+
],
|
|
352
|
+
"name": "order_type",
|
|
353
|
+
"required": true,
|
|
354
|
+
"type": "string"
|
|
355
|
+
},
|
|
356
|
+
{
|
|
357
|
+
"description": "明细项",
|
|
358
|
+
"name": "items",
|
|
359
|
+
"required": true,
|
|
360
|
+
"type": "array"
|
|
361
|
+
},
|
|
362
|
+
{
|
|
363
|
+
"description": "备注",
|
|
364
|
+
"name": "remark",
|
|
365
|
+
"type": "string"
|
|
366
|
+
}
|
|
367
|
+
],
|
|
368
|
+
"when_to_use": "用户说'开销售单'、'创建采购单'、'下单'等场景"
|
|
369
|
+
},
|
|
370
|
+
{
|
|
371
|
+
"confirmation_level": 0,
|
|
372
|
+
"description": "获取当前登录用户在 ERP 系统中的权限列表。",
|
|
373
|
+
"endpoint": "GET /api/v1/auth/permissions",
|
|
374
|
+
"name": "auth_permissions",
|
|
375
|
+
"parameters": [],
|
|
376
|
+
"when_to_use": "用户询问'我有什么权限'、'我能做什么操作'等场景"
|
|
377
|
+
}
|
|
378
|
+
],
|
|
379
|
+
"auth": {
|
|
380
|
+
"agreement": {
|
|
381
|
+
"documents": [
|
|
382
|
+
{
|
|
383
|
+
"name": "用户协议",
|
|
384
|
+
"url": "https://ersa-org.github.io/co-work-thrid-tool/terms"
|
|
385
|
+
},
|
|
386
|
+
{
|
|
387
|
+
"name": "隐私政策",
|
|
388
|
+
"url": "https://ersa-org.github.io/co-work-thrid-tool/privacy"
|
|
389
|
+
}
|
|
390
|
+
],
|
|
391
|
+
"required": true,
|
|
392
|
+
"summary": "使用本工具需同意用户协议和隐私政策。本工具将以您的 Co-Work 身份访问 ERP Pro 系统,仅读写您授权的数据范围。",
|
|
393
|
+
"title": "ERP Pro 用户协议与隐私政策"
|
|
394
|
+
},
|
|
395
|
+
"cowork_client_id": "42fce22d-fdf9-407b-b1c7-2725ae19b779",
|
|
396
|
+
"endpoints": {
|
|
397
|
+
"login": "/api/v1/auth/login",
|
|
398
|
+
"permissions": "/api/v1/auth/permissions",
|
|
399
|
+
"refresh": "/api/v1/auth/refresh",
|
|
400
|
+
"register": "/api/v1/auth/register",
|
|
401
|
+
"revoke": "/api/v1/auth/revoke",
|
|
402
|
+
"scopes": "/api/v1/auth/scopes",
|
|
403
|
+
"status": "/api/v1/auth/status",
|
|
404
|
+
"token_exchange": "/api/v1/auth/token"
|
|
405
|
+
},
|
|
406
|
+
"grant_types": [
|
|
407
|
+
"cowork_token_exchange",
|
|
408
|
+
"refresh_token"
|
|
409
|
+
],
|
|
410
|
+
"scopes": [
|
|
411
|
+
{
|
|
412
|
+
"default": true,
|
|
413
|
+
"description": "查询所有模块数据",
|
|
414
|
+
"name": "read"
|
|
415
|
+
},
|
|
416
|
+
{
|
|
417
|
+
"default": false,
|
|
418
|
+
"description": "创建、修改数据(需确认)",
|
|
419
|
+
"name": "write"
|
|
420
|
+
},
|
|
421
|
+
{
|
|
422
|
+
"default": false,
|
|
423
|
+
"description": "删除数据(需确认)",
|
|
424
|
+
"name": "delete"
|
|
425
|
+
},
|
|
426
|
+
{
|
|
427
|
+
"default": false,
|
|
428
|
+
"description": "用户管理、系统配置",
|
|
429
|
+
"name": "admin"
|
|
430
|
+
}
|
|
431
|
+
],
|
|
432
|
+
"type": "cowork_oauth2"
|
|
433
|
+
},
|
|
434
|
+
"category": "enterprise",
|
|
435
|
+
"cowork_compatibility": {
|
|
436
|
+
"auth_version": "1.0",
|
|
437
|
+
"confirmation_version": "2.0",
|
|
438
|
+
"min_version": "2.0.0"
|
|
439
|
+
},
|
|
440
|
+
"delivery_mode": "remote_service",
|
|
441
|
+
"displayName": "ERP Pro 进销存系统",
|
|
442
|
+
"execution_mode": "http_proxy",
|
|
443
|
+
"icon": "assets/icon.png",
|
|
444
|
+
"id": "erp-pro-tool",
|
|
445
|
+
"scope": "local-dev",
|
|
446
|
+
"server": {
|
|
447
|
+
"base_url": "http://localhost:8080",
|
|
448
|
+
"health_check": "/health"
|
|
449
|
+
},
|
|
450
|
+
"tags": [
|
|
451
|
+
"erp",
|
|
452
|
+
"enterprise",
|
|
453
|
+
"user-management"
|
|
454
|
+
],
|
|
455
|
+
"type": "tool",
|
|
456
|
+
"urls": {
|
|
457
|
+
"homepage": "https://github.com/ersa-org/co-work-thrid-tool",
|
|
458
|
+
"privacy": "https://ersa-org.github.io/co-work-thrid-tool/privacy",
|
|
459
|
+
"repository": "https://github.com/ersa-org/co-work-thrid-tool.git",
|
|
460
|
+
"terms": "https://ersa-org.github.io/co-work-thrid-tool/terms"
|
|
461
|
+
}
|
|
462
|
+
},
|
|
463
|
+
"description": "企业进销存管理系统,支持用户管理、公司管理等模块。写操作由 Co-Work 平台拦截确认(confirm_mode: platform),第三方 API 无需改造。",
|
|
464
|
+
"files": [
|
|
465
|
+
"*"
|
|
466
|
+
],
|
|
467
|
+
"keywords": [
|
|
468
|
+
"chatablex",
|
|
469
|
+
"tool",
|
|
470
|
+
"tool"
|
|
471
|
+
],
|
|
472
|
+
"license": "MIT",
|
|
473
|
+
"name": "@chatablex/erp-pro-tool",
|
|
474
|
+
"version": "3.2.2"
|
|
475
|
+
}
|