closeclaw 3.0.0 → 3.0.1
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/cli-loader.cjs +1 -0
- package/dist/cli.jsc +0 -0
- package/dist/index-loader.cjs +1 -0
- package/dist/index.jsc +0 -0
- package/package.json +1 -1
- package/dist/packages/platform-tools/index.js +0 -160
- package/dist/packages/platform-tools/openclaw.plugin.json +0 -11
- package/dist/packages/platform-tools/package.json +0 -25
package/dist/cli-loader.cjs
CHANGED
package/dist/cli.jsc
CHANGED
|
Binary file
|
package/dist/index-loader.cjs
CHANGED
package/dist/index.jsc
CHANGED
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,160 +0,0 @@
|
|
|
1
|
-
// Platform Tools — OpenClaw plugin for AI Alpha Tech
|
|
2
|
-
// Two tools: update_task + get_task
|
|
3
|
-
// Both call the backend at localhost:3001/internal/* (never touches DB directly)
|
|
4
|
-
|
|
5
|
-
import { definePluginEntry } from "openclaw/plugin-sdk/plugin-entry";
|
|
6
|
-
import { Type } from "@sinclair/typebox";
|
|
7
|
-
|
|
8
|
-
const BACKEND_URL = "http://127.0.0.1:3001";
|
|
9
|
-
|
|
10
|
-
export default definePluginEntry({
|
|
11
|
-
id: "platform-tools",
|
|
12
|
-
name: "Platform Tools",
|
|
13
|
-
description:
|
|
14
|
-
"AI Alpha Tech platform integration. Provides update_task and get_task tools for agents to interact with the project management backend.",
|
|
15
|
-
register(api) {
|
|
16
|
-
// Tool 1: update_task
|
|
17
|
-
api.registerTool({
|
|
18
|
-
name: "update_task",
|
|
19
|
-
label: "Update Task",
|
|
20
|
-
description:
|
|
21
|
-
"Update a platform task's status, plan, or post a comment. " +
|
|
22
|
-
"Use this to move tasks through the workflow, submit plans for review, " +
|
|
23
|
-
"or communicate with the team.",
|
|
24
|
-
parameters: Type.Object({
|
|
25
|
-
task_id: Type.String({ description: "The task ID to update." }),
|
|
26
|
-
status: Type.Optional(
|
|
27
|
-
Type.String({
|
|
28
|
-
description:
|
|
29
|
-
"New task status. Use: ai_planning, ai_discuss, ai_plan_review, ai_in_progress, ai_done.",
|
|
30
|
-
})
|
|
31
|
-
),
|
|
32
|
-
ai_plan: Type.Optional(
|
|
33
|
-
Type.String({
|
|
34
|
-
description: "The plan text to submit for human review.",
|
|
35
|
-
})
|
|
36
|
-
),
|
|
37
|
-
ai_plan_status: Type.Optional(
|
|
38
|
-
Type.String({
|
|
39
|
-
description:
|
|
40
|
-
'Plan status. Use "pending_review" when submitting a plan.',
|
|
41
|
-
})
|
|
42
|
-
),
|
|
43
|
-
comment: Type.Optional(
|
|
44
|
-
Type.String({
|
|
45
|
-
description:
|
|
46
|
-
"A comment to post on the task (visible to the team).",
|
|
47
|
-
})
|
|
48
|
-
),
|
|
49
|
-
}),
|
|
50
|
-
async execute(_toolCallId, params) {
|
|
51
|
-
const res = await fetch(`${BACKEND_URL}/internal/task-update`, {
|
|
52
|
-
method: "POST",
|
|
53
|
-
headers: { "Content-Type": "application/json" },
|
|
54
|
-
body: JSON.stringify(params),
|
|
55
|
-
});
|
|
56
|
-
|
|
57
|
-
if (!res.ok) {
|
|
58
|
-
const text = await res.text().catch(() => "Unknown error");
|
|
59
|
-
return {
|
|
60
|
-
content: [{ type: "text", text: `Failed to update task: ${text}` }],
|
|
61
|
-
details: { status: "failed" },
|
|
62
|
-
};
|
|
63
|
-
}
|
|
64
|
-
|
|
65
|
-
const data = await res.json();
|
|
66
|
-
return {
|
|
67
|
-
content: [
|
|
68
|
-
{
|
|
69
|
-
type: "text",
|
|
70
|
-
text: `Task ${params.task_id} updated successfully.${params.status ? ` Status: ${params.status}.` : ""}${params.comment ? " Comment posted." : ""}${params.ai_plan ? " Plan submitted." : ""}`,
|
|
71
|
-
},
|
|
72
|
-
],
|
|
73
|
-
details: data,
|
|
74
|
-
};
|
|
75
|
-
},
|
|
76
|
-
});
|
|
77
|
-
|
|
78
|
-
// Tool 2: get_task
|
|
79
|
-
api.registerTool({
|
|
80
|
-
name: "get_task",
|
|
81
|
-
label: "Get Task",
|
|
82
|
-
description:
|
|
83
|
-
"Retrieve full details of a platform task including description, " +
|
|
84
|
-
"labels, comments, and checklists. Use this to understand what " +
|
|
85
|
-
"needs to be done before planning or executing.",
|
|
86
|
-
parameters: Type.Object({
|
|
87
|
-
task_id: Type.String({ description: "The task ID to retrieve." }),
|
|
88
|
-
}),
|
|
89
|
-
async execute(_toolCallId, params) {
|
|
90
|
-
const res = await fetch(`${BACKEND_URL}/internal/task-get`, {
|
|
91
|
-
method: "POST",
|
|
92
|
-
headers: { "Content-Type": "application/json" },
|
|
93
|
-
body: JSON.stringify(params),
|
|
94
|
-
});
|
|
95
|
-
|
|
96
|
-
if (!res.ok) {
|
|
97
|
-
const text = await res.text().catch(() => "Unknown error");
|
|
98
|
-
return {
|
|
99
|
-
content: [{ type: "text", text: `Failed to get task: ${text}` }],
|
|
100
|
-
details: { status: "failed" },
|
|
101
|
-
};
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
const data = await res.json();
|
|
105
|
-
const task = data.task;
|
|
106
|
-
|
|
107
|
-
if (!task) {
|
|
108
|
-
return {
|
|
109
|
-
content: [{ type: "text", text: "Task not found." }],
|
|
110
|
-
details: { status: "not_found" },
|
|
111
|
-
};
|
|
112
|
-
}
|
|
113
|
-
|
|
114
|
-
const lines = [
|
|
115
|
-
`# Task: ${task.title}`,
|
|
116
|
-
`ID: ${task.id}`,
|
|
117
|
-
`Status: ${task.status}`,
|
|
118
|
-
`Priority: ${task.priority || "none"}`,
|
|
119
|
-
`Side: ${task.side}`,
|
|
120
|
-
];
|
|
121
|
-
|
|
122
|
-
if (task.description) lines.push(`\n## Description\n${task.description}`);
|
|
123
|
-
if (task.due_date) lines.push(`Due: ${task.due_date}`);
|
|
124
|
-
if (task.story_points != null) lines.push(`Story Points: ${task.story_points}`);
|
|
125
|
-
|
|
126
|
-
const labels = task.task_labels
|
|
127
|
-
?.map((tl) => tl.labels?.name)
|
|
128
|
-
.filter(Boolean);
|
|
129
|
-
if (labels?.length) {
|
|
130
|
-
lines.push(`\nLabels: ${labels.join(", ")}`);
|
|
131
|
-
}
|
|
132
|
-
|
|
133
|
-
const comments = task.comments || [];
|
|
134
|
-
if (comments.length > 0) {
|
|
135
|
-
lines.push("\n## Comments");
|
|
136
|
-
for (const c of comments) {
|
|
137
|
-
const author = c.is_ai_message ? "AI Agent" : "Human";
|
|
138
|
-
lines.push(`[${author}] ${c.content}`);
|
|
139
|
-
}
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
const checklists = task.checklists || [];
|
|
143
|
-
if (checklists.length > 0) {
|
|
144
|
-
lines.push("\n## Checklists");
|
|
145
|
-
for (const cl of checklists) {
|
|
146
|
-
lines.push(`### ${cl.title}`);
|
|
147
|
-
for (const item of cl.checklist_items || []) {
|
|
148
|
-
lines.push(`- [${item.is_checked ? "x" : " "}] ${item.content}`);
|
|
149
|
-
}
|
|
150
|
-
}
|
|
151
|
-
}
|
|
152
|
-
|
|
153
|
-
return {
|
|
154
|
-
content: [{ type: "text", text: lines.join("\n") }],
|
|
155
|
-
details: task,
|
|
156
|
-
};
|
|
157
|
-
},
|
|
158
|
-
});
|
|
159
|
-
},
|
|
160
|
-
});
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"id": "platform-tools",
|
|
3
|
-
"name": "Platform Tools",
|
|
4
|
-
"description": "AI Alpha Tech platform integration — update_task and get_task tools that call the backend API.",
|
|
5
|
-
"version": "1.0.7",
|
|
6
|
-
"configSchema": {
|
|
7
|
-
"type": "object",
|
|
8
|
-
"additionalProperties": false,
|
|
9
|
-
"properties": {}
|
|
10
|
-
}
|
|
11
|
-
}
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@prajwalshete/platform-tools",
|
|
3
|
-
"version": "1.3.0",
|
|
4
|
-
"type": "module",
|
|
5
|
-
"description": "OpenClaw plugin — gives AI agents tools for task management and GitHub integration with worktree isolation (update_task, get_task, list_branches, create_branch, create_pr, commit_and_push, get_pr_status).",
|
|
6
|
-
"openclaw": {
|
|
7
|
-
"extensions": [
|
|
8
|
-
"./index.ts"
|
|
9
|
-
]
|
|
10
|
-
},
|
|
11
|
-
"keywords": [
|
|
12
|
-
"openclaw",
|
|
13
|
-
"openclaw-plugin",
|
|
14
|
-
"platform-tools",
|
|
15
|
-
"agent-tools",
|
|
16
|
-
"task-management"
|
|
17
|
-
],
|
|
18
|
-
"license": "MIT",
|
|
19
|
-
"dependencies": {
|
|
20
|
-
"@sinclair/typebox": "0.34.48"
|
|
21
|
-
},
|
|
22
|
-
"peerDependencies": {
|
|
23
|
-
"openclaw": ">=2026.3.0"
|
|
24
|
-
}
|
|
25
|
-
}
|