@dain-os/mcp-server 0.19.1 → 0.21.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/dist/index.js +0 -0
- package/dist/meta.d.ts +1 -1
- package/dist/meta.js +1 -1
- package/dist/tools/cadence.d.ts +4 -0
- package/dist/tools/cadence.d.ts.map +1 -0
- package/dist/tools/cadence.js +245 -0
- package/dist/tools/cadence.js.map +1 -0
- package/dist/tools/comments.d.ts +3 -0
- package/dist/tools/comments.d.ts.map +1 -0
- package/dist/tools/comments.js +19 -0
- package/dist/tools/comments.js.map +1 -0
- package/dist/tools/developer.d.ts +3 -0
- package/dist/tools/developer.d.ts.map +1 -0
- package/dist/tools/developer.js +349 -0
- package/dist/tools/developer.js.map +1 -0
- package/dist/tools/iam.d.ts +3 -0
- package/dist/tools/iam.d.ts.map +1 -0
- package/dist/tools/iam.js +38 -0
- package/dist/tools/iam.js.map +1 -0
- package/dist/tools/log-time-entry.d.ts +3 -0
- package/dist/tools/log-time-entry.d.ts.map +1 -0
- package/dist/tools/log-time-entry.js +54 -0
- package/dist/tools/log-time-entry.js.map +1 -0
- package/dist/tools/pr-review.d.ts +3 -0
- package/dist/tools/pr-review.d.ts.map +1 -0
- package/dist/tools/pr-review.js +83 -0
- package/dist/tools/pr-review.js.map +1 -0
- package/dist/tools/products.d.ts +3 -0
- package/dist/tools/products.d.ts.map +1 -0
- package/dist/tools/products.js +37 -0
- package/dist/tools/products.js.map +1 -0
- package/dist/tools/projects.d.ts +3 -0
- package/dist/tools/projects.d.ts.map +1 -0
- package/dist/tools/projects.js +151 -0
- package/dist/tools/projects.js.map +1 -0
- package/dist/tools/proposal-content.d.ts +3 -0
- package/dist/tools/proposal-content.d.ts.map +1 -0
- package/dist/tools/proposal-content.js +136 -0
- package/dist/tools/proposal-content.js.map +1 -0
- package/dist/tools/proposal-options.d.ts +3 -0
- package/dist/tools/proposal-options.d.ts.map +1 -0
- package/dist/tools/proposal-options.js +132 -0
- package/dist/tools/proposal-options.js.map +1 -0
- package/dist/tools/proposals.d.ts +22 -0
- package/dist/tools/proposals.d.ts.map +1 -0
- package/dist/tools/proposals.js +179 -0
- package/dist/tools/proposals.js.map +1 -0
- package/dist/tools/registry.d.ts.map +1 -1
- package/dist/tools/registry.js +28 -5
- package/dist/tools/registry.js.map +1 -1
- package/dist/tools/semantic/cadence.d.ts.map +1 -1
- package/dist/tools/semantic/cadence.js +5 -2
- package/dist/tools/semantic/cadence.js.map +1 -1
- package/dist/tools/semantic/tasks.d.ts.map +1 -1
- package/dist/tools/semantic/tasks.js +9 -2
- package/dist/tools/semantic/tasks.js.map +1 -1
- package/dist/tools/tasks.d.ts +3 -0
- package/dist/tools/tasks.d.ts.map +1 -0
- package/dist/tools/tasks.js +255 -0
- package/dist/tools/tasks.js.map +1 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
File without changes
|
package/dist/meta.d.ts
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
* it here removes that drift between the two transports.
|
|
10
10
|
*/
|
|
11
11
|
export declare const SERVER_NAME = "dainos";
|
|
12
|
-
export declare const SERVER_VERSION = "0.
|
|
12
|
+
export declare const SERVER_VERSION = "0.21.0";
|
|
13
13
|
/**
|
|
14
14
|
* Instructions advertised to MCP clients in the `initialize` response.
|
|
15
15
|
*
|
package/dist/meta.js
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
* it here removes that drift between the two transports.
|
|
10
10
|
*/
|
|
11
11
|
export const SERVER_NAME = 'dainos';
|
|
12
|
-
export const SERVER_VERSION = '0.
|
|
12
|
+
export const SERVER_VERSION = '0.21.0';
|
|
13
13
|
/**
|
|
14
14
|
* Instructions advertised to MCP clients in the `initialize` response.
|
|
15
15
|
*
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cadence.d.ts","sourceRoot":"","sources":["../../src/tools/cadence.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAoRjD,kCAAkC;AAClC,eAAO,MAAM,YAAY,EAAE,cAAc,EAKxC,CAAC"}
|
|
@@ -0,0 +1,245 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
/**
|
|
3
|
+
* Cadence MCP tools: AI agent feed for the Sprint + Cadence feature.
|
|
4
|
+
*
|
|
5
|
+
* Four tools for agents (Claude Code, Otto) to interact with the sprint plan:
|
|
6
|
+
* claim_next_task — fetch the highest-ranked open task from the sprint
|
|
7
|
+
* report_task_progress — append a one-liner progress note with agent identity
|
|
8
|
+
* mark_blocked — flag a task as blocked with a reason
|
|
9
|
+
* request_unblock — signal that a task needs human attention to unblock
|
|
10
|
+
*
|
|
11
|
+
* Audit trail: all writes carry metadata.via='mcp' and metadata.client so the
|
|
12
|
+
* cadence_actions record shows "Claude Code" rather than "system". The API
|
|
13
|
+
* side uses this to attribute agent activity in the sprint timeline.
|
|
14
|
+
*
|
|
15
|
+
* @builder ship-api-builder (Round 4, R4-T1)
|
|
16
|
+
*/
|
|
17
|
+
// ---------------------------------------------------------------------------
|
|
18
|
+
// claim_next_task
|
|
19
|
+
// ---------------------------------------------------------------------------
|
|
20
|
+
const claimNextTask = {
|
|
21
|
+
name: 'claim_next_task',
|
|
22
|
+
description: 'Fetch the highest-ranked open task from the Cadence sprint feed. ' +
|
|
23
|
+
'Returns the task object with its Cadence ranking rationale and score. ' +
|
|
24
|
+
'Call this at the start of an autonomous work session to find what to work on next. ' +
|
|
25
|
+
'Filters by sprintId, projectId, or assigneeId when provided.',
|
|
26
|
+
inputSchema: z.object({
|
|
27
|
+
sprintId: z
|
|
28
|
+
.string()
|
|
29
|
+
.uuid()
|
|
30
|
+
.optional()
|
|
31
|
+
.describe('Restrict to tasks in a specific sprint.'),
|
|
32
|
+
projectId: z
|
|
33
|
+
.string()
|
|
34
|
+
.uuid()
|
|
35
|
+
.optional()
|
|
36
|
+
.describe('Restrict to tasks in a specific project.'),
|
|
37
|
+
assigneeId: z
|
|
38
|
+
.string()
|
|
39
|
+
.uuid()
|
|
40
|
+
.optional()
|
|
41
|
+
.describe('Restrict to tasks assigned to a specific IAM user.'),
|
|
42
|
+
client: z
|
|
43
|
+
.string()
|
|
44
|
+
.max(100)
|
|
45
|
+
.optional()
|
|
46
|
+
.describe('Caller identity for the audit trail (e.g. "claude-code", "otto"). ' +
|
|
47
|
+
'Logged as metadata.client on the resulting cadence_actions row.'),
|
|
48
|
+
}),
|
|
49
|
+
handler: async (client, input) => {
|
|
50
|
+
const params = new URLSearchParams();
|
|
51
|
+
if (input.sprintId)
|
|
52
|
+
params.set('sprintId', input.sprintId);
|
|
53
|
+
if (input.projectId)
|
|
54
|
+
params.set('projectId', input.projectId);
|
|
55
|
+
if (input.assigneeId)
|
|
56
|
+
params.set('assigneeId', input.assigneeId);
|
|
57
|
+
const query = params.toString() ? `?${params.toString()}` : '';
|
|
58
|
+
// GET /api/v1/cadence/feed/next-task returns { task: RankedTask | null }
|
|
59
|
+
// The ranked task includes rationale and ranking score from CadenceRankerService.
|
|
60
|
+
return client.get(`/cadence/feed/next-task${query}`);
|
|
61
|
+
},
|
|
62
|
+
};
|
|
63
|
+
// ---------------------------------------------------------------------------
|
|
64
|
+
// report_task_progress
|
|
65
|
+
// ---------------------------------------------------------------------------
|
|
66
|
+
const reportTaskProgress = {
|
|
67
|
+
name: 'report_task_progress',
|
|
68
|
+
description: 'Append a one-line progress note to a task and record it in the Cadence audit trail. ' +
|
|
69
|
+
'Use this after completing a meaningful unit of work on a task (e.g. "Implemented ' +
|
|
70
|
+
'the migration file and ran npx prisma generate"). ' +
|
|
71
|
+
'The note is written to the task\'s AI progress log section and creates a ' +
|
|
72
|
+
'cadence_actions row with action_type=progress_note for the sprint timeline. ' +
|
|
73
|
+
'Provide your client identity so the audit trail reads "Claude Code" not "system".',
|
|
74
|
+
inputSchema: z.object({
|
|
75
|
+
taskId: z
|
|
76
|
+
.string()
|
|
77
|
+
.uuid()
|
|
78
|
+
.describe('The task to update.'),
|
|
79
|
+
note: z
|
|
80
|
+
.string()
|
|
81
|
+
.min(1)
|
|
82
|
+
.max(500)
|
|
83
|
+
.describe('One-line progress note in plain English. ' +
|
|
84
|
+
'Will be appended inside the AI-progress-log sentinel block in the task description. ' +
|
|
85
|
+
'Example: "Added Zod schema and controller handler for POST /cadence/draft."'),
|
|
86
|
+
client: z
|
|
87
|
+
.string()
|
|
88
|
+
.max(100)
|
|
89
|
+
.optional()
|
|
90
|
+
.describe('Caller identity for the audit trail (e.g. "claude-code"). ' +
|
|
91
|
+
'Logged as metadata.client on the cadence_actions row.'),
|
|
92
|
+
}),
|
|
93
|
+
handler: async (client, input) => {
|
|
94
|
+
// Step 1: fetch the current task description so we can append to the AI progress block.
|
|
95
|
+
const task = await client.get(`/tasks/${input.taskId}`);
|
|
96
|
+
const now = new Date().toISOString();
|
|
97
|
+
const clientLabel = input.client ?? 'mcp-agent';
|
|
98
|
+
const newLine = `[${now}] (${clientLabel}) ${input.note}`;
|
|
99
|
+
const BEGIN_MARKER = '<!-- BEGIN AI-PROGRESS-LOG -->';
|
|
100
|
+
const END_MARKER = '<!-- END AI-PROGRESS-LOG -->';
|
|
101
|
+
const existing = task.description ?? '';
|
|
102
|
+
let updatedDescription;
|
|
103
|
+
if (existing.includes(BEGIN_MARKER) && existing.includes(END_MARKER)) {
|
|
104
|
+
// Append before the closing marker.
|
|
105
|
+
updatedDescription = existing.replace(END_MARKER, `${newLine}\n${END_MARKER}`);
|
|
106
|
+
}
|
|
107
|
+
else {
|
|
108
|
+
// No sentinel block yet — append one at the end.
|
|
109
|
+
updatedDescription =
|
|
110
|
+
existing.trimEnd() +
|
|
111
|
+
`\n\n${BEGIN_MARKER}\n${newLine}\n${END_MARKER}`;
|
|
112
|
+
}
|
|
113
|
+
// Step 2: update the task description.
|
|
114
|
+
await client.put(`/tasks/${input.taskId}`, { description: updatedDescription });
|
|
115
|
+
// Step 3: write a cadence_actions row for the sprint timeline.
|
|
116
|
+
// action_type='progress_note', target_type='task', payload carries the note + client identity.
|
|
117
|
+
await client.post('/cadence/actions', {
|
|
118
|
+
actionType: 'progress_note',
|
|
119
|
+
targetType: 'task',
|
|
120
|
+
targetId: input.taskId,
|
|
121
|
+
rationale: input.note,
|
|
122
|
+
payload: {
|
|
123
|
+
via: 'mcp',
|
|
124
|
+
client: clientLabel,
|
|
125
|
+
timestamp: now,
|
|
126
|
+
},
|
|
127
|
+
});
|
|
128
|
+
return { success: true, taskId: input.taskId, note: input.note };
|
|
129
|
+
},
|
|
130
|
+
};
|
|
131
|
+
// ---------------------------------------------------------------------------
|
|
132
|
+
// mark_blocked
|
|
133
|
+
// ---------------------------------------------------------------------------
|
|
134
|
+
const markBlocked = {
|
|
135
|
+
name: 'mark_blocked',
|
|
136
|
+
description: 'Mark a task as blocked and record the reason in the Cadence audit trail. ' +
|
|
137
|
+
'Use when you hit a genuine blocker while working on a task autonomously ' +
|
|
138
|
+
'(e.g. missing API key, conflicting schema, waiting on another task). ' +
|
|
139
|
+
'The task status changes to "blocked" and a cadence_actions row is created ' +
|
|
140
|
+
'so the sprint timeline shows the block and the human can address it. ' +
|
|
141
|
+
'The reason must be specific enough for a human to act on without asking you.',
|
|
142
|
+
inputSchema: z.object({
|
|
143
|
+
taskId: z
|
|
144
|
+
.string()
|
|
145
|
+
.uuid()
|
|
146
|
+
.describe('The task to mark blocked.'),
|
|
147
|
+
reason: z
|
|
148
|
+
.string()
|
|
149
|
+
.min(1)
|
|
150
|
+
.max(500)
|
|
151
|
+
.describe('Plain English description of the blocker. Be specific: ' +
|
|
152
|
+
'"Waiting on OPENAI_API_KEY in the api .env" is actionable. ' +
|
|
153
|
+
'"It\'s blocked" is not. Minimum 1 character, maximum 500.'),
|
|
154
|
+
client: z
|
|
155
|
+
.string()
|
|
156
|
+
.max(100)
|
|
157
|
+
.optional()
|
|
158
|
+
.describe('Caller identity for the audit trail (e.g. "claude-code").'),
|
|
159
|
+
}),
|
|
160
|
+
handler: async (client, input) => {
|
|
161
|
+
const clientLabel = input.client ?? 'mcp-agent';
|
|
162
|
+
const now = new Date().toISOString();
|
|
163
|
+
// Step 1: update task status to blocked.
|
|
164
|
+
await client.put(`/tasks/${input.taskId}`, { status: 'blocked' });
|
|
165
|
+
// Step 2: create a cadence_actions row for the audit trail.
|
|
166
|
+
await client.post('/cadence/actions', {
|
|
167
|
+
actionType: 'mark_blocked',
|
|
168
|
+
targetType: 'task',
|
|
169
|
+
targetId: input.taskId,
|
|
170
|
+
rationale: input.reason,
|
|
171
|
+
payload: {
|
|
172
|
+
via: 'mcp',
|
|
173
|
+
client: clientLabel,
|
|
174
|
+
timestamp: now,
|
|
175
|
+
reason: input.reason,
|
|
176
|
+
},
|
|
177
|
+
});
|
|
178
|
+
return { success: true, taskId: input.taskId, reason: input.reason };
|
|
179
|
+
},
|
|
180
|
+
};
|
|
181
|
+
// ---------------------------------------------------------------------------
|
|
182
|
+
// request_unblock
|
|
183
|
+
// ---------------------------------------------------------------------------
|
|
184
|
+
const requestUnblock = {
|
|
185
|
+
name: 'request_unblock',
|
|
186
|
+
description: 'Signal that a blocked task needs human attention to unblock. ' +
|
|
187
|
+
'Use after mark_blocked if you want to escalate urgency or add additional context ' +
|
|
188
|
+
'beyond the original block reason. ' +
|
|
189
|
+
'Creates a cadence_actions row with action_type=request_unblock which surfaces ' +
|
|
190
|
+
'in the next Cadence daily scan and CadenceSidebarPanel stale items list. ' +
|
|
191
|
+
'Does not change task status (task stays blocked until a human acts).',
|
|
192
|
+
inputSchema: z.object({
|
|
193
|
+
taskId: z
|
|
194
|
+
.string()
|
|
195
|
+
.uuid()
|
|
196
|
+
.describe('The blocked task that needs human attention.'),
|
|
197
|
+
context: z
|
|
198
|
+
.string()
|
|
199
|
+
.min(1)
|
|
200
|
+
.max(500)
|
|
201
|
+
.optional()
|
|
202
|
+
.describe('Additional context for the human — e.g. what you tried, what you need to proceed. ' +
|
|
203
|
+
'Optional but strongly recommended for actionability.'),
|
|
204
|
+
client: z
|
|
205
|
+
.string()
|
|
206
|
+
.max(100)
|
|
207
|
+
.optional()
|
|
208
|
+
.describe('Caller identity for the audit trail (e.g. "claude-code").'),
|
|
209
|
+
}),
|
|
210
|
+
handler: async (client, input) => {
|
|
211
|
+
const clientLabel = input.client ?? 'mcp-agent';
|
|
212
|
+
const now = new Date().toISOString();
|
|
213
|
+
// Write a cadence_actions row with action_type='request_unblock'.
|
|
214
|
+
// The next daily scan will pick this up and surface it in the stale items list.
|
|
215
|
+
await client.post('/cadence/actions', {
|
|
216
|
+
actionType: 'request_unblock',
|
|
217
|
+
targetType: 'task',
|
|
218
|
+
targetId: input.taskId,
|
|
219
|
+
rationale: input.context ?? 'Agent requested human unblock.',
|
|
220
|
+
payload: {
|
|
221
|
+
via: 'mcp',
|
|
222
|
+
client: clientLabel,
|
|
223
|
+
timestamp: now,
|
|
224
|
+
context: input.context ?? null,
|
|
225
|
+
},
|
|
226
|
+
});
|
|
227
|
+
return {
|
|
228
|
+
success: true,
|
|
229
|
+
taskId: input.taskId,
|
|
230
|
+
message: 'Unblock request recorded. The next Cadence daily scan will surface this task ' +
|
|
231
|
+
'in the sprint sidebar for human review.',
|
|
232
|
+
};
|
|
233
|
+
},
|
|
234
|
+
};
|
|
235
|
+
// ---------------------------------------------------------------------------
|
|
236
|
+
// Export
|
|
237
|
+
// ---------------------------------------------------------------------------
|
|
238
|
+
/** All four Cadence MCP tools. */
|
|
239
|
+
export const cadenceTools = [
|
|
240
|
+
claimNextTask,
|
|
241
|
+
reportTaskProgress,
|
|
242
|
+
markBlocked,
|
|
243
|
+
requestUnblock,
|
|
244
|
+
];
|
|
245
|
+
//# sourceMappingURL=cadence.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cadence.js","sourceRoot":"","sources":["../../src/tools/cadence.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB;;;;;;;;;;;;;;GAcG;AAEH,8EAA8E;AAC9E,kBAAk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AM;YACpB,OAAO,EACL,+EAA+E;gBAC/E,yCAAyC;SAC5C,CAAC;IACJ,CAAC;CACF,CAAC;AAEF,8EAA8E;AAC9E,SAAS;AACT,8EAA8E;AAE9E,kCAAkC;AAClC,MAAM,CAAC,MAAM,YAAY,GAAqB;IAC5C,aAAa;IACb,kBAAkB;IAClB,WAAW;IACX,cAAc;CACf,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"comments.d.ts","sourceRoot":"","sources":["../../src/tools/comments.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAoBjD,eAAO,MAAM,YAAY,EAAE,cAAc,EAAqB,CAAC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
const addTaskComment = {
|
|
3
|
+
name: 'add_task_comment',
|
|
4
|
+
description: 'Add a comment to a task. Comments are internal by default (visible to the workspace, not to clients on the portal). Pass isInternal: false to make the comment client-visible.',
|
|
5
|
+
inputSchema: z.object({
|
|
6
|
+
taskId: z.string().uuid(),
|
|
7
|
+
content: z.string().min(1).max(10000),
|
|
8
|
+
isInternal: z
|
|
9
|
+
.boolean()
|
|
10
|
+
.optional()
|
|
11
|
+
.describe('Defaults to true. Set false to make the comment client-visible.'),
|
|
12
|
+
}),
|
|
13
|
+
handler: async (client, input) => {
|
|
14
|
+
const { taskId, ...body } = input;
|
|
15
|
+
return client.post(`/tasks/${taskId}/comments`, body);
|
|
16
|
+
},
|
|
17
|
+
};
|
|
18
|
+
export const commentTools = [addTaskComment];
|
|
19
|
+
//# sourceMappingURL=comments.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"comments.js","sourceRoot":"","sources":["../../src/tools/comments.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,MAAM,cAAc,GAAmB;IACrC,IAAI,EAAE,kBAAkB;IACxB,WAAW,EACT,gLAAgL;IAClL,WAAW,EAAE,CAAC,CAAC,MAAM,CAAC;QACpB,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE;QACzB,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,KAAK,CAAC;QACrC,UAAU,EAAE,CAAC;aACV,OAAO,EAAE;aACT,QAAQ,EAAE;aACV,QAAQ,CAAC,iEAAiE,CAAC;KAC/E,CAAC;IACF,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,EAAE;QAC/B,MAAM,EAAE,MAAM,EAAE,GAAG,IAAI,EAAE,GAAG,KAAK,CAAC;QAClC,OAAO,MAAM,CAAC,IAAI,CAAC,UAAU,MAAM,WAAW,EAAE,IAAI,CAAC,CAAC;IACxD,CAAC;CACF,CAAC;AAEF,MAAM,CAAC,MAAM,YAAY,GAAqB,CAAC,cAAc,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"developer.d.ts","sourceRoot":"","sources":["../../src/tools/developer.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAyXjD,eAAO,MAAM,cAAc,EAAE,cAAc,EAW1C,CAAC"}
|