@pxlabz/tasq-mcp 0.1.20 → 0.1.21
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/dist/tasq-mcp.js +51 -7
- package/package.json +1 -1
package/dist/tasq-mcp.js
CHANGED
|
@@ -22649,6 +22649,11 @@ var TasqClient = class _TasqClient {
|
|
|
22649
22649
|
)).fields,
|
|
22650
22650
|
/** Set a task's value; null, `[]` or `false` clears it. */
|
|
22651
22651
|
setTaskValue: (slug, taskId, fieldKey, value) => this.dispatch("task.setField", slug, { taskId, fieldKey, value }),
|
|
22652
|
+
/**
|
|
22653
|
+
* Set one value on up to 100 tasks, all or nothing: a task whose team
|
|
22654
|
+
* has the field off refuses the whole set.
|
|
22655
|
+
*/
|
|
22656
|
+
bulkSetTaskValue: (slug, taskIds, fieldKey, value) => this.dispatch("task.bulkSetField", slug, { taskIds, fieldKey, value }),
|
|
22652
22657
|
/** Set a project field's value; null clears it. */
|
|
22653
22658
|
setProjectValue: (slug, projectId, fieldKey, value) => this.dispatch("project.setField", slug, { projectId, fieldKey, value })
|
|
22654
22659
|
};
|
|
@@ -30762,7 +30767,7 @@ var EMPTY_COMPLETION_RESULT = {
|
|
|
30762
30767
|
// package.json
|
|
30763
30768
|
var package_default = {
|
|
30764
30769
|
name: "@pxlabz/tasq-mcp",
|
|
30765
|
-
version: "0.1.
|
|
30770
|
+
version: "0.1.21",
|
|
30766
30771
|
description: "MCP stdio server for Tasq: tasks, threads, comments and mentions for MCP-capable agents",
|
|
30767
30772
|
keywords: [
|
|
30768
30773
|
"tasq",
|
|
@@ -31513,6 +31518,12 @@ var definitions = [
|
|
|
31513
31518
|
action.projectId = await resolveProjectId(client, slug, input.project);
|
|
31514
31519
|
}
|
|
31515
31520
|
if (parentTaskId !== void 0) action.parentTaskId = parentTaskId;
|
|
31521
|
+
if (fieldEdits.length > 0) {
|
|
31522
|
+
action.fields = fieldEdits.map((edit) => ({
|
|
31523
|
+
fieldKey: edit.key,
|
|
31524
|
+
value: edit.value
|
|
31525
|
+
}));
|
|
31526
|
+
}
|
|
31516
31527
|
const steps = new StepRunner();
|
|
31517
31528
|
const created = await steps.run(
|
|
31518
31529
|
"create",
|
|
@@ -31534,12 +31545,8 @@ var definitions = [
|
|
|
31534
31545
|
})
|
|
31535
31546
|
);
|
|
31536
31547
|
}
|
|
31537
|
-
const lines =
|
|
31538
|
-
|
|
31539
|
-
slug,
|
|
31540
|
-
steps,
|
|
31541
|
-
created.result.task.id,
|
|
31542
|
-
fieldEdits
|
|
31548
|
+
const lines = fieldEdits.length === 0 ? [] : created.result.fields.map(
|
|
31549
|
+
(field) => field.display === null ? `${field.name}: cleared.` : `${field.name}: ${field.display}.`
|
|
31543
31550
|
);
|
|
31544
31551
|
return { data: created.result, lines };
|
|
31545
31552
|
}
|
|
@@ -31665,6 +31672,43 @@ var definitions = [
|
|
|
31665
31672
|
return { data: response.result };
|
|
31666
31673
|
}
|
|
31667
31674
|
}),
|
|
31675
|
+
define({
|
|
31676
|
+
name: "task_set_field",
|
|
31677
|
+
description: "Set one custom field to one value on up to 100 tasks at once, all or nothing.",
|
|
31678
|
+
schema: external_exports.object({
|
|
31679
|
+
...workspaceFields,
|
|
31680
|
+
ids: external_exports.array(external_exports.string()).min(1).max(100).describe("Task keys such as ENG-42, or task ids."),
|
|
31681
|
+
field: external_exports.string().describe("The field's key; call field_list for keys."),
|
|
31682
|
+
value: FIELD_VALUE_INPUT.describe(
|
|
31683
|
+
"The value: options and people by name, null clears."
|
|
31684
|
+
)
|
|
31685
|
+
}),
|
|
31686
|
+
run: async ({ client, config: config2 }, input) => {
|
|
31687
|
+
const slug = requireWorkspace(config2, input);
|
|
31688
|
+
const [edit] = await resolveFieldEdits(
|
|
31689
|
+
client,
|
|
31690
|
+
slug,
|
|
31691
|
+
/* @__PURE__ */ new Map([[input.field, input.value]])
|
|
31692
|
+
);
|
|
31693
|
+
if (!edit) throw new UsageError(`Unknown field "${input.field}".`);
|
|
31694
|
+
const taskIds = [];
|
|
31695
|
+
for (const id of input.ids) taskIds.push(await resolveTaskId(client, slug, id));
|
|
31696
|
+
const uniqueIds = [...new Set(taskIds)];
|
|
31697
|
+
const response = await client.fields.bulkSetTaskValue(
|
|
31698
|
+
slug,
|
|
31699
|
+
uniqueIds,
|
|
31700
|
+
edit.key,
|
|
31701
|
+
edit.value
|
|
31702
|
+
);
|
|
31703
|
+
const { field, changedTaskIds } = response.result;
|
|
31704
|
+
return {
|
|
31705
|
+
data: response.result,
|
|
31706
|
+
lines: [
|
|
31707
|
+
`${field.name} ${edit.value === null ? "cleared" : "set"} on ${changedTaskIds.length} of ${uniqueIds.length} tasks; the rest already held it.`
|
|
31708
|
+
]
|
|
31709
|
+
};
|
|
31710
|
+
}
|
|
31711
|
+
}),
|
|
31668
31712
|
define({
|
|
31669
31713
|
name: "field_list",
|
|
31670
31714
|
description: "List the workspace's custom fields: the keys task_create and task_update take in fields, with types and option names.",
|