@uipath/tasks-tool 1.0.2 → 1.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/browser.json +3 -0
- package/dist/index.js +20 -42285
- package/dist/tool.js +2159 -2061
- package/package.json +4 -11
- package/src/commands/tasks.ts +22 -7
- package/src/index.ts +6 -7
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@uipath/tasks-tool",
|
|
3
|
-
"version": "1.0
|
|
3
|
+
"version": "1.1.0",
|
|
4
4
|
"description": "Manage Action Center tasks.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/tool.js",
|
|
@@ -10,17 +10,10 @@
|
|
|
10
10
|
"bin": {
|
|
11
11
|
"tasks-tool": "./dist/index.js"
|
|
12
12
|
},
|
|
13
|
-
"scripts": {
|
|
14
|
-
"build": "bun ../../tools/build-tool.ts",
|
|
15
|
-
"test": "vitest run",
|
|
16
|
-
"test:coverage": "vitest run --coverage",
|
|
17
|
-
"lint": "biome check .",
|
|
18
|
-
"lint:fix": "biome check --write ."
|
|
19
|
-
},
|
|
20
13
|
"devDependencies": {
|
|
21
14
|
"@types/node": "^25.5.2",
|
|
22
|
-
"@uipath/auth": "1.0
|
|
23
|
-
"@uipath/common": "1.0
|
|
15
|
+
"@uipath/auth": "1.1.0",
|
|
16
|
+
"@uipath/common": "1.1.0",
|
|
24
17
|
"@uipath/uipath-typescript": "^1.3.7",
|
|
25
18
|
"commander": "^14.0.3",
|
|
26
19
|
"typescript": "^6.0.2"
|
|
@@ -28,5 +21,5 @@
|
|
|
28
21
|
"publishConfig": {
|
|
29
22
|
"registry": "https://registry.npmjs.org/"
|
|
30
23
|
},
|
|
31
|
-
"gitHead": "
|
|
24
|
+
"gitHead": "06e8c8f566df4b87da4a008635483c62f64f33f0"
|
|
32
25
|
}
|
package/src/commands/tasks.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import {
|
|
2
2
|
type CommandExample,
|
|
3
3
|
catchError,
|
|
4
|
+
createHiddenDeprecatedTenantOption,
|
|
4
5
|
extractErrorMessage,
|
|
5
6
|
extractErrorMessageSync,
|
|
6
7
|
OutputFormatter,
|
|
@@ -104,7 +105,9 @@ export const registerTasksCommand = (program: Command) => {
|
|
|
104
105
|
program
|
|
105
106
|
.command("list")
|
|
106
107
|
.description("List tasks across folders")
|
|
107
|
-
.
|
|
108
|
+
.addOption(
|
|
109
|
+
createHiddenDeprecatedTenantOption("-t, --tenant <tenant-name>"),
|
|
110
|
+
)
|
|
108
111
|
.option("--folder-id <id>", "Filter by folder ID")
|
|
109
112
|
.option("--as-admin", "List tasks as admin")
|
|
110
113
|
.option(
|
|
@@ -213,7 +216,9 @@ export const registerTasksCommand = (program: Command) => {
|
|
|
213
216
|
"Get details of a task by ID. Use 'tasks list' to find task IDs.",
|
|
214
217
|
)
|
|
215
218
|
.argument("<id>", "Task ID")
|
|
216
|
-
.
|
|
219
|
+
.addOption(
|
|
220
|
+
createHiddenDeprecatedTenantOption("-t, --tenant <tenant-name>"),
|
|
221
|
+
)
|
|
217
222
|
.option(
|
|
218
223
|
"--task-type <type>",
|
|
219
224
|
"Task type (FormTask, ExternalTask, AppTask, DocumentValidationTask, DocumentClassificationTask, DataLabelingTask)",
|
|
@@ -300,7 +305,9 @@ export const registerTasksCommand = (program: Command) => {
|
|
|
300
305
|
.command("assign")
|
|
301
306
|
.description("Assign a task to a user")
|
|
302
307
|
.argument("<task-id>", "Task ID")
|
|
303
|
-
.
|
|
308
|
+
.addOption(
|
|
309
|
+
createHiddenDeprecatedTenantOption("-t, --tenant <tenant-name>"),
|
|
310
|
+
)
|
|
304
311
|
.option("--user-id <id>", "User ID")
|
|
305
312
|
.option(
|
|
306
313
|
"--user <email>",
|
|
@@ -317,7 +324,9 @@ export const registerTasksCommand = (program: Command) => {
|
|
|
317
324
|
.command("reassign")
|
|
318
325
|
.description("Reassign a task to a different user")
|
|
319
326
|
.argument("<task-id>", "Task ID")
|
|
320
|
-
.
|
|
327
|
+
.addOption(
|
|
328
|
+
createHiddenDeprecatedTenantOption("-t, --tenant <tenant-name>"),
|
|
329
|
+
)
|
|
321
330
|
.option("--user-id <id>", "User ID")
|
|
322
331
|
.option(
|
|
323
332
|
"--user <email>",
|
|
@@ -334,7 +343,9 @@ export const registerTasksCommand = (program: Command) => {
|
|
|
334
343
|
.command("unassign")
|
|
335
344
|
.description("Remove the assignee from a task")
|
|
336
345
|
.argument("<task-id>", "Task ID")
|
|
337
|
-
.
|
|
346
|
+
.addOption(
|
|
347
|
+
createHiddenDeprecatedTenantOption("-t, --tenant <tenant-name>"),
|
|
348
|
+
)
|
|
338
349
|
.trackedAction(
|
|
339
350
|
processContext,
|
|
340
351
|
async (taskId: string, options: { tenant?: string }) => {
|
|
@@ -389,7 +400,9 @@ export const registerTasksCommand = (program: Command) => {
|
|
|
389
400
|
"Task type (FormTask, ExternalTask, AppTask, DocumentValidationTask, DocumentClassificationTask, DataLabelingTask)",
|
|
390
401
|
)
|
|
391
402
|
.requiredOption("--folder-id <id>", "Folder ID (required)")
|
|
392
|
-
.
|
|
403
|
+
.addOption(
|
|
404
|
+
createHiddenDeprecatedTenantOption("-t, --tenant <tenant-name>"),
|
|
405
|
+
)
|
|
393
406
|
.option("--data <json>", "Task data as JSON string")
|
|
394
407
|
.option(
|
|
395
408
|
"--action <action>",
|
|
@@ -499,7 +512,9 @@ export const registerTasksCommand = (program: Command) => {
|
|
|
499
512
|
"List users with task permissions in a folder. Use the user ID with 'tasks assign'.",
|
|
500
513
|
)
|
|
501
514
|
.argument("<folder-id>", "Folder ID")
|
|
502
|
-
.
|
|
515
|
+
.addOption(
|
|
516
|
+
createHiddenDeprecatedTenantOption("-t, --tenant <tenant-name>"),
|
|
517
|
+
)
|
|
503
518
|
.option(
|
|
504
519
|
"-l, --limit <number>",
|
|
505
520
|
"Maximum number of items to return (fetches all if omitted)",
|
package/src/index.ts
CHANGED
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
#!/usr/bin/env bun
|
|
2
2
|
import { Command } from "commander";
|
|
3
|
-
import
|
|
4
|
-
import { registerTasksCommand } from "./commands/tasks";
|
|
3
|
+
import { metadata, registerCommands } from "./tool.js";
|
|
5
4
|
|
|
6
5
|
const program = new Command();
|
|
7
6
|
program
|
|
8
|
-
.name(
|
|
9
|
-
.description(
|
|
10
|
-
.version(
|
|
7
|
+
.name(metadata.name)
|
|
8
|
+
.description(metadata.description)
|
|
9
|
+
.version(metadata.version);
|
|
11
10
|
|
|
12
|
-
|
|
13
|
-
program.
|
|
11
|
+
await registerCommands(program);
|
|
12
|
+
await program.parseAsync(process.argv);
|