@cat-factory/mcp-server 0.2.1 → 0.3.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/README.md +123 -28
- package/dist/bin.js +11 -19
- package/dist/bin.js.map +1 -1
- package/dist/config.d.ts +29 -1
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +102 -10
- package/dist/config.js.map +1 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -1
- package/dist/index.js.map +1 -1
- package/dist/instructions.d.ts.map +1 -1
- package/dist/instructions.js +66 -5
- package/dist/instructions.js.map +1 -1
- package/dist/result.d.ts +7 -0
- package/dist/result.d.ts.map +1 -1
- package/dist/result.js +66 -12
- package/dist/result.js.map +1 -1
- package/dist/server.d.ts +1 -1
- package/dist/server.d.ts.map +1 -1
- package/dist/server.js +12 -5
- package/dist/server.js.map +1 -1
- package/dist/stdio.d.ts +38 -0
- package/dist/stdio.d.ts.map +1 -0
- package/dist/stdio.js +31 -0
- package/dist/stdio.js.map +1 -0
- package/dist/tools.generated.d.ts +22 -0
- package/dist/tools.generated.d.ts.map +1 -1
- package/dist/tools.generated.js +41 -0
- package/dist/tools.generated.js.map +1 -1
- package/package.json +1 -1
package/dist/tools.generated.js
CHANGED
|
@@ -43,6 +43,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
43
43
|
readOnly: false,
|
|
44
44
|
description: 'Cancel a job\n\nStop a headless job run, freeing its concurrency slot. Idempotent — an already-finished job is returned as-is. Use this to abandon a run parked on a decision you do not intend to answer.\n\nCalls `POST /api/v1/jobs/{id}/cancel` (operation `cancelPublicJob`).',
|
|
45
45
|
inputSchema: { "type": "object", "properties": { "id": { "type": "string", "description": "Path parameter `id`." } }, "additionalProperties": false, "required": ["id"] },
|
|
46
|
+
outputSchema: { "type": "object", "properties": { "createdAt": { "type": "number" }, "error": { "anyOf": [{ "type": "object", "properties": { "code": { "type": "string" }, "message": { "type": "string" } } }, { "type": "null" }] }, "jobId": { "type": "string" }, "pipelineId": { "type": "string" }, "result": { "anyOf": [{ "type": "object", "properties": { "data": { "anyOf": [{}, { "type": "null" }] }, "output": { "type": "string" } } }, { "type": "null" }] }, "status": { "type": "string", "description": "One of: running, succeeded, failed. A newer deployment may report a member not in this list." } } },
|
|
46
47
|
invoke: (client, args) => client.jobs.cancel(str(args, 'id')),
|
|
47
48
|
},
|
|
48
49
|
{
|
|
@@ -51,8 +52,10 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
51
52
|
group: 'jobs',
|
|
52
53
|
operationId: 'createPublicJob',
|
|
53
54
|
readOnly: false,
|
|
55
|
+
hints: { "destructive": true, "idempotent": false },
|
|
54
56
|
description: 'Start a headless job\n\nStart a public, inline pipeline headlessly against a supplied brief. Returns a job id to poll or stream. Nothing is pushed to GitHub.\n\nCalls `POST /api/v1/jobs` (operation `createPublicJob`).',
|
|
55
57
|
inputSchema: { "type": "object", "properties": { "body": { "type": "object", "properties": { "input": { "type": "string", "minLength": 1, "maxLength": 50000 }, "pipelineId": { "type": "string", "minLength": 1 }, "title": { "type": "string", "maxLength": 200 } }, "required": ["input", "pipelineId"], "description": "The request body." } }, "additionalProperties": false, "required": ["body"] },
|
|
58
|
+
outputSchema: { "type": "object", "properties": { "jobId": { "type": "string" }, "links": { "type": "object", "properties": { "events": { "type": "string" }, "self": { "type": "string" } } }, "status": { "type": "string", "description": "One of: running, succeeded, failed. A newer deployment may report a member not in this list." } } },
|
|
56
59
|
invoke: (client, args) => client.jobs.create(args.body),
|
|
57
60
|
},
|
|
58
61
|
{
|
|
@@ -63,6 +66,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
63
66
|
readOnly: true,
|
|
64
67
|
description: 'Get a job\n\nPoll a headless job started through this surface: its status and, once finished, its result.\n\nCalls `GET /api/v1/jobs/{id}` (operation `getPublicJob`).',
|
|
65
68
|
inputSchema: { "type": "object", "properties": { "id": { "type": "string", "description": "Path parameter `id`." } }, "additionalProperties": false, "required": ["id"] },
|
|
69
|
+
outputSchema: { "type": "object", "properties": { "createdAt": { "type": "number" }, "error": { "anyOf": [{ "type": "object", "properties": { "code": { "type": "string" }, "message": { "type": "string" } } }, { "type": "null" }] }, "jobId": { "type": "string" }, "pipelineId": { "type": "string" }, "result": { "anyOf": [{ "type": "object", "properties": { "data": { "anyOf": [{}, { "type": "null" }] }, "output": { "type": "string" } } }, { "type": "null" }] }, "status": { "type": "string", "description": "One of: running, succeeded, failed. A newer deployment may report a member not in this list." } } },
|
|
66
70
|
invoke: (client, args) => client.jobs.get(str(args, 'id')),
|
|
67
71
|
},
|
|
68
72
|
{
|
|
@@ -73,6 +77,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
73
77
|
readOnly: true,
|
|
74
78
|
description: 'List the workspace\'s jobs\n\nList the headless runs THIS surface created, newest first and keyset-paginated. Scoped to internal-anchored runs exactly like the single-job read, so an external key can never enumerate the workspace’s ordinary board runs.\n\nCalls `GET /api/v1/jobs` (operation `listPublicJobs`).',
|
|
75
79
|
inputSchema: { "type": "object", "properties": { "limit": { "type": "integer" }, "cursor": { "type": "string" }, "status": { "type": "string", "enum": ["running", "succeeded", "failed"] }, "since": { "type": "integer" } }, "additionalProperties": false },
|
|
80
|
+
outputSchema: { "type": "object", "properties": { "jobs": { "type": "array", "items": { "type": "object", "properties": { "createdAt": { "type": "number" }, "error": { "anyOf": [{ "type": "object", "properties": { "code": { "type": "string" }, "message": { "type": "string" } } }, { "type": "null" }] }, "jobId": { "type": "string" }, "pipelineId": { "type": "string" }, "result": { "anyOf": [{ "type": "object", "properties": { "data": { "anyOf": [{}, { "type": "null" }] }, "output": { "type": "string" } } }, { "type": "null" }] }, "status": { "type": "string", "description": "One of: running, succeeded, failed. A newer deployment may report a member not in this list." } } } }, "nextCursor": { "anyOf": [{ "type": "string" }, { "type": "null" }] } } },
|
|
76
81
|
invoke: (client, args) => client.jobs.list(pick(args, QUERY_JOBS_LIST)),
|
|
77
82
|
},
|
|
78
83
|
{
|
|
@@ -83,6 +88,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
83
88
|
readOnly: true,
|
|
84
89
|
description: 'List the workspace\'s services\n\nList the board service frames in the key’s workspace, so a caller can discover the serviceId to create/list tasks under.\n\nCalls `GET /api/v1/services` (operation `listPublicServices`).',
|
|
85
90
|
inputSchema: { "type": "object", "properties": {}, "additionalProperties": false },
|
|
91
|
+
outputSchema: { "type": "object", "properties": { "services": { "type": "array", "items": { "type": "object", "properties": { "description": { "type": "string" }, "serviceId": { "type": "string" }, "status": { "type": "string", "description": "One of: planned, ready, in_progress, blocked, pr_ready, done. A newer deployment may report a member not in this list." }, "title": { "type": "string" }, "type": { "type": "string", "description": "One of: frontend, service, library, document, api, database, queue, integration, external, environment. A newer deployment may report a member not in this list." } } } } } },
|
|
86
92
|
invoke: (client, args) => client.services.list(),
|
|
87
93
|
},
|
|
88
94
|
{
|
|
@@ -93,6 +99,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
93
99
|
readOnly: false,
|
|
94
100
|
description: 'Create a task under a service\n\nCreate a task inside a service frame the key’s workspace owns. The task starts in the `planned` state; start it with the start endpoint.\n\nCalls `POST /api/v1/services/{serviceId}/tasks` (operation `createPublicTask`).',
|
|
95
101
|
inputSchema: { "type": "object", "properties": { "serviceId": { "type": "string", "description": "Path parameter `serviceId`." }, "body": { "type": "object", "properties": { "description": { "type": "string", "maxLength": 2000 }, "taskType": { "type": "string", "description": "Usually one of: feature, bug, document, spike, review, ralph. Other values are accepted where the deployment defines them." }, "ticket": { "type": "object", "properties": { "ref": { "type": "string", "minLength": 1, "maxLength": 500 }, "source": { "type": "string", "description": "Usually one of: jira, github, linear. Other values are accepted where the deployment defines them." } }, "required": ["ref", "source"] }, "title": { "type": "string", "minLength": 1, "maxLength": 200 } }, "required": ["title"], "description": "The request body." } }, "additionalProperties": false, "required": ["serviceId", "body"] },
|
|
102
|
+
outputSchema: { "type": "object", "properties": { "description": { "type": "string" }, "progress": { "type": "number" }, "pullRequestUrl": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "runId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "serviceId": { "type": "string" }, "status": { "type": "string", "description": "One of: planned, ready, in_progress, blocked, pr_ready, done. A newer deployment may report a member not in this list." }, "taskId": { "type": "string" }, "taskType": { "type": "string", "description": "Usually one of: feature, bug, document, spike, review, ralph, recurring. Other values are accepted where the deployment defines them." }, "title": { "type": "string" } } },
|
|
96
103
|
invoke: (client, args) => client.tasks.create(str(args, 'serviceId'), args.body),
|
|
97
104
|
},
|
|
98
105
|
{
|
|
@@ -101,6 +108,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
101
108
|
group: 'tasks',
|
|
102
109
|
operationId: 'deletePublicTask',
|
|
103
110
|
readOnly: false,
|
|
111
|
+
hints: { "destructive": true, "idempotent": true },
|
|
104
112
|
description: 'Delete a task\n\nDelete a task and its run history. Destructive, so it sits at the top of the scope ladder: requires an `admin`-scoped key.\n\nCalls `DELETE /api/v1/tasks/{taskId}` (operation `deletePublicTask`).',
|
|
105
113
|
inputSchema: { "type": "object", "properties": { "taskId": { "type": "string", "description": "Path parameter `taskId`." } }, "additionalProperties": false, "required": ["taskId"] },
|
|
106
114
|
invoke: (client, args) => client.tasks.delete(str(args, 'taskId')),
|
|
@@ -113,6 +121,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
113
121
|
readOnly: true,
|
|
114
122
|
description: 'Get a task\'s status\n\nRead a task’s current lifecycle status, run progress, run id, and PR URL (once one exists).\n\nCalls `GET /api/v1/tasks/{taskId}` (operation `getPublicTask`).',
|
|
115
123
|
inputSchema: { "type": "object", "properties": { "taskId": { "type": "string", "description": "Path parameter `taskId`." } }, "additionalProperties": false, "required": ["taskId"] },
|
|
124
|
+
outputSchema: { "type": "object", "properties": { "description": { "type": "string" }, "progress": { "type": "number" }, "pullRequestUrl": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "runId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "serviceId": { "type": "string" }, "status": { "type": "string", "description": "One of: planned, ready, in_progress, blocked, pr_ready, done. A newer deployment may report a member not in this list." }, "taskId": { "type": "string" }, "taskType": { "type": "string", "description": "Usually one of: feature, bug, document, spike, review, ralph, recurring. Other values are accepted where the deployment defines them." }, "title": { "type": "string" } } },
|
|
116
125
|
invoke: (client, args) => client.tasks.get(str(args, 'taskId')),
|
|
117
126
|
},
|
|
118
127
|
{
|
|
@@ -123,6 +132,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
123
132
|
readOnly: true,
|
|
124
133
|
description: 'Get a task\'s run (rich projection)\n\nRead a task’s run in detail: per-step status/progress/subtasks, the failure kind and message, and the PR (url + branch).\n\nCalls `GET /api/v1/tasks/{taskId}/run` (operation `getPublicRun`).',
|
|
125
134
|
inputSchema: { "type": "object", "properties": { "taskId": { "type": "string", "description": "Path parameter `taskId`." } }, "additionalProperties": false, "required": ["taskId"] },
|
|
135
|
+
outputSchema: { "type": "object", "properties": { "createdAt": { "type": "number" }, "currentStep": { "type": "number" }, "error": { "anyOf": [{ "type": "object", "properties": { "code": { "type": "string" }, "message": { "type": "string" } } }, { "type": "null" }] }, "pullRequest": { "anyOf": [{ "type": "object", "properties": { "branch": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "url": { "type": "string" } } }, { "type": "null" }] }, "runId": { "type": "string" }, "status": { "type": "string", "description": "One of: running, blocked, paused, done, failed. A newer deployment may report a member not in this list." }, "steps": { "type": "array", "items": { "type": "object", "properties": { "agentKind": { "type": "string" }, "progress": { "type": "number" }, "state": { "type": "string", "description": "One of: pending, working, waiting_decision, done. A newer deployment may report a member not in this list." }, "subtasks": { "anyOf": [{ "type": "object", "properties": { "completed": { "type": "number" }, "inProgress": { "type": "number" }, "total": { "type": "number" } } }, { "type": "null" }] } } } }, "taskId": { "type": "string" } } },
|
|
126
136
|
invoke: (client, args) => client.tasks.getRun(str(args, 'taskId')),
|
|
127
137
|
},
|
|
128
138
|
{
|
|
@@ -133,6 +143,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
133
143
|
readOnly: true,
|
|
134
144
|
description: 'List a service\'s tasks\n\nList every task under a service (the whole subtree — tasks directly under the frame and under its modules).\n\nCalls `GET /api/v1/services/{serviceId}/tasks` (operation `listPublicServiceTasks`).',
|
|
135
145
|
inputSchema: { "type": "object", "properties": { "serviceId": { "type": "string", "description": "Path parameter `serviceId`." }, "limit": { "type": "integer" }, "cursor": { "type": "string" }, "status": { "type": "string", "enum": ["planned", "ready", "in_progress", "blocked", "pr_ready", "done"] } }, "additionalProperties": false, "required": ["serviceId"] },
|
|
146
|
+
outputSchema: { "type": "object", "properties": { "nextCursor": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "tasks": { "type": "array", "items": { "type": "object", "properties": { "description": { "type": "string" }, "progress": { "type": "number" }, "pullRequestUrl": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "runId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "serviceId": { "type": "string" }, "status": { "type": "string", "description": "One of: planned, ready, in_progress, blocked, pr_ready, done. A newer deployment may report a member not in this list." }, "taskId": { "type": "string" }, "taskType": { "type": "string", "description": "Usually one of: feature, bug, document, spike, review, ralph, recurring. Other values are accepted where the deployment defines them." }, "title": { "type": "string" } } } } } },
|
|
136
147
|
invoke: (client, args) => client.tasks.listByService(str(args, 'serviceId'), pick(args, QUERY_TASKS_LIST_BY_SERVICE)),
|
|
137
148
|
},
|
|
138
149
|
{
|
|
@@ -141,8 +152,10 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
141
152
|
group: 'tasks',
|
|
142
153
|
operationId: 'retryPublicTask',
|
|
143
154
|
readOnly: false,
|
|
155
|
+
hints: { "destructive": true, "idempotent": false },
|
|
144
156
|
description: 'Retry a task\'s failed run\n\nRetry a task’s failed run. A task on an individual-usage model cannot be retried through the API (no headless personal-credential unlock).\n\nCalls `POST /api/v1/tasks/{taskId}/retry` (operation `retryPublicTask`).',
|
|
145
157
|
inputSchema: { "type": "object", "properties": { "taskId": { "type": "string", "description": "Path parameter `taskId`." } }, "additionalProperties": false, "required": ["taskId"] },
|
|
158
|
+
outputSchema: { "type": "object", "properties": { "description": { "type": "string" }, "progress": { "type": "number" }, "pullRequestUrl": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "runId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "serviceId": { "type": "string" }, "status": { "type": "string", "description": "One of: planned, ready, in_progress, blocked, pr_ready, done. A newer deployment may report a member not in this list." }, "taskId": { "type": "string" }, "taskType": { "type": "string", "description": "Usually one of: feature, bug, document, spike, review, ralph, recurring. Other values are accepted where the deployment defines them." }, "title": { "type": "string" } } },
|
|
146
159
|
invoke: (client, args) => client.tasks.retry(str(args, 'taskId')),
|
|
147
160
|
},
|
|
148
161
|
{
|
|
@@ -151,8 +164,10 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
151
164
|
group: 'tasks',
|
|
152
165
|
operationId: 'startPublicTask',
|
|
153
166
|
readOnly: false,
|
|
167
|
+
hints: { "destructive": true, "idempotent": false },
|
|
154
168
|
description: 'Start (run) a task\n\nStart a task’s pipeline. Uses the request’s pipelineId, else the task’s pinned pipeline. A pipeline that can park on a human decision requires a `decide`-scope key. A task on an individual-usage model cannot be started through the API (no headless personal-credential unlock).\n\nCalls `POST /api/v1/tasks/{taskId}/start` (operation `startPublicTask`).',
|
|
155
169
|
inputSchema: { "type": "object", "properties": { "taskId": { "type": "string", "description": "Path parameter `taskId`." }, "body": { "type": "object", "properties": { "pipelineId": { "type": "string", "minLength": 1, "maxLength": 120 } }, "description": "The request body." } }, "additionalProperties": false, "required": ["taskId", "body"] },
|
|
170
|
+
outputSchema: { "type": "object", "properties": { "description": { "type": "string" }, "progress": { "type": "number" }, "pullRequestUrl": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "runId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "serviceId": { "type": "string" }, "status": { "type": "string", "description": "One of: planned, ready, in_progress, blocked, pr_ready, done. A newer deployment may report a member not in this list." }, "taskId": { "type": "string" }, "taskType": { "type": "string", "description": "Usually one of: feature, bug, document, spike, review, ralph, recurring. Other values are accepted where the deployment defines them." }, "title": { "type": "string" } } },
|
|
156
171
|
invoke: (client, args) => client.tasks.start(str(args, 'taskId'), args.body),
|
|
157
172
|
},
|
|
158
173
|
{
|
|
@@ -163,6 +178,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
163
178
|
readOnly: false,
|
|
164
179
|
description: 'Stop a task\'s run\n\nStop a task’s in-flight run. Records a `cancelled` terminal state, leaving the run retryable.\n\nCalls `POST /api/v1/tasks/{taskId}/stop` (operation `stopPublicTask`).',
|
|
165
180
|
inputSchema: { "type": "object", "properties": { "taskId": { "type": "string", "description": "Path parameter `taskId`." } }, "additionalProperties": false, "required": ["taskId"] },
|
|
181
|
+
outputSchema: { "type": "object", "properties": { "description": { "type": "string" }, "progress": { "type": "number" }, "pullRequestUrl": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "runId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "serviceId": { "type": "string" }, "status": { "type": "string", "description": "One of: planned, ready, in_progress, blocked, pr_ready, done. A newer deployment may report a member not in this list." }, "taskId": { "type": "string" }, "taskType": { "type": "string", "description": "Usually one of: feature, bug, document, spike, review, ralph, recurring. Other values are accepted where the deployment defines them." }, "title": { "type": "string" } } },
|
|
166
182
|
invoke: (client, args) => client.tasks.stop(str(args, 'taskId')),
|
|
167
183
|
},
|
|
168
184
|
{
|
|
@@ -173,6 +189,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
173
189
|
readOnly: false,
|
|
174
190
|
description: 'Edit a task\'s title/description\n\nEdit a task’s human-authored fields (title/description) before it runs. Both fields are optional.\n\nCalls `PATCH /api/v1/tasks/{taskId}` (operation `updatePublicTask`).',
|
|
175
191
|
inputSchema: { "type": "object", "properties": { "taskId": { "type": "string", "description": "Path parameter `taskId`." }, "body": { "type": "object", "properties": { "description": { "type": "string", "maxLength": 2000 }, "title": { "type": "string", "minLength": 1, "maxLength": 200 } }, "description": "The request body." } }, "additionalProperties": false, "required": ["taskId", "body"] },
|
|
192
|
+
outputSchema: { "type": "object", "properties": { "description": { "type": "string" }, "progress": { "type": "number" }, "pullRequestUrl": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "runId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "serviceId": { "type": "string" }, "status": { "type": "string", "description": "One of: planned, ready, in_progress, blocked, pr_ready, done. A newer deployment may report a member not in this list." }, "taskId": { "type": "string" }, "taskType": { "type": "string", "description": "Usually one of: feature, bug, document, spike, review, ralph, recurring. Other values are accepted where the deployment defines them." }, "title": { "type": "string" } } },
|
|
176
193
|
invoke: (client, args) => client.tasks.update(str(args, 'taskId'), args.body),
|
|
177
194
|
},
|
|
178
195
|
{
|
|
@@ -183,6 +200,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
183
200
|
readOnly: true,
|
|
184
201
|
description: 'List the workspace\'s pipelines\n\nList the pipelines in the key’s workspace — id/name/steps plus whether each is public and safe to run headlessly — so a caller can pick a pipelineId to start a task with.\n\nCalls `GET /api/v1/pipelines` (operation `listPublicPipelines`).',
|
|
185
202
|
inputSchema: { "type": "object", "properties": {}, "additionalProperties": false },
|
|
203
|
+
outputSchema: { "type": "object", "properties": { "pipelines": { "type": "array", "items": { "type": "object", "properties": { "headlessStartable": { "type": "boolean" }, "name": { "type": "string" }, "pipelineId": { "type": "string" }, "public": { "type": "boolean" }, "steps": { "type": "array", "items": { "type": "string" } } } } } } },
|
|
186
204
|
invoke: (client, args) => client.pipelines.list(),
|
|
187
205
|
},
|
|
188
206
|
{
|
|
@@ -191,8 +209,10 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
191
209
|
group: 'notifications',
|
|
192
210
|
operationId: 'actPublicNotification',
|
|
193
211
|
readOnly: false,
|
|
212
|
+
hints: { "destructive": true, "idempotent": false },
|
|
194
213
|
description: 'Act on a notification\n\nRun a notification’s typed side-effect and resolve it: merge the PR (merge_review / pipeline_complete) or retry the run (ci_failed / test_failed). Performs a real GitHub merge, so it requires an admin-scoped key. Only these automated-action types are actionable through the API — a notification that parks a run on an interactive human decision cannot be acted on headlessly (dismiss it instead). A card that would retry a run on an individual-usage model likewise cannot be acted on through the API.\n\nCalls `POST /api/v1/notifications/{id}/act` (operation `actPublicNotification`).',
|
|
195
214
|
inputSchema: { "type": "object", "properties": { "id": { "type": "string", "description": "Path parameter `id`." } }, "additionalProperties": false, "required": ["id"] },
|
|
215
|
+
outputSchema: { "type": "object", "properties": { "blockId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "body": { "type": "string" }, "createdAt": { "type": "number" }, "executionId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "id": { "type": "string" }, "payload": { "anyOf": [{ "type": "object", "properties": { "assessment": { "type": "object", "properties": { "complexity": { "type": "number" }, "impact": { "type": "number" }, "rationale": { "type": "string" }, "risk": { "type": "number" } } }, "changeClass": { "type": "string", "description": "One of: docs, test, dependency, config, source, schema, unknown. A newer deployment may report a member not in this list." }, "driftAffected": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "label": { "type": "string" }, "reason": { "type": "string", "description": "One of: key-mismatch, corrupt. A newer deployment may report a member not in this list." }, "sealedAt": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "source": { "type": "string" } } } }, "findingCount": { "type": "number" }, "forkCount": { "type": "number" }, "initiativeReason": { "type": "string", "description": "One of: item_blocked, complete, checkpoint. A newer deployment may report a member not in this list." }, "mergeTrackRecordId": { "type": "string" }, "mergedRepos": { "type": "array", "items": { "type": "string" } }, "onCallAssessment": { "type": "object", "properties": { "culpritConfidence": { "type": "number" }, "evidence": { "type": "array", "items": { "type": "string" } }, "rationale": { "type": "string" }, "recommendation": { "type": "string", "description": "One of: revert, hold, monitor. A newer deployment may report a member not in this list." } } }, "pipelineName": { "type": "string" }, "platformAlertTransition": { "type": "number" }, "platformAlerts": { "type": "array", "items": { "type": "string", "description": "One of: failure_rate_high, duration_p99_high, backlog_high, throughput_stalled, failure_kind_dominant, sweep_degraded. A newer deployment may report a member not in this list." } }, "platformFailedTotal": { "type": "number" }, "platformFailingRuns": { "type": "array", "items": { "type": "object", "properties": { "blockId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "createdAt": { "type": "number" }, "executionId": { "type": "string" }, "failureKind": { "type": "string" } } } }, "platformWindow": { "type": "string", "description": "One of: 1h, 24h, 7d. A newer deployment may report a member not in this list." }, "prUrl": { "type": "string" }, "releaseSignals": { "type": "array", "items": { "type": "object", "properties": { "detail": { "type": "string" }, "id": { "type": "string" }, "kind": { "type": "string", "description": "One of: monitor, slo. A newer deployment may report a member not in this list." }, "name": { "type": "string" }, "state": { "type": "string", "description": "One of: ok, warn, alert, no_data. A newer deployment may report a member not in this list." } } } }, "revertUrl": { "type": "string" }, "sliceCount": { "type": "number" }, "targetUserId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "unmergedRepos": { "type": "array", "items": { "type": "string" } }, "unreachableAreas": { "type": "array", "items": { "type": "string", "description": "One of: ephemeralEnvironments, agentExecutor, binaryStorage. A newer deployment may report a member not in this list." } } } }, { "type": "null" }] }, "resolvedAt": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "severity": { "type": "string", "description": "One of: normal, urgent. A newer deployment may report a member not in this list." }, "status": { "type": "string", "description": "One of: open, acted, dismissed. A newer deployment may report a member not in this list." }, "title": { "type": "string" }, "type": { "type": "string", "description": "One of: merge_review, pipeline_complete, ci_failed, test_failed, requirement_review, clarity_review, release_regression, decision_required, human_test_ready, visual_confirmation_ready, human_review, followup_pending, fork_decision_pending, judge_review, pr_review_ready, initiative, platform_health, infra_unreachable, budget_paused, key_drift, merge_tag_request. A newer deployment may report a member not in this list." } } },
|
|
196
216
|
invoke: (client, args) => client.notifications.act(str(args, 'id')),
|
|
197
217
|
},
|
|
198
218
|
{
|
|
@@ -203,6 +223,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
203
223
|
readOnly: false,
|
|
204
224
|
description: 'Dismiss a notification\n\nDismiss a notification without acting on it.\n\nCalls `POST /api/v1/notifications/{id}/dismiss` (operation `dismissPublicNotification`).',
|
|
205
225
|
inputSchema: { "type": "object", "properties": { "id": { "type": "string", "description": "Path parameter `id`." } }, "additionalProperties": false, "required": ["id"] },
|
|
226
|
+
outputSchema: { "type": "object", "properties": { "blockId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "body": { "type": "string" }, "createdAt": { "type": "number" }, "executionId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "id": { "type": "string" }, "payload": { "anyOf": [{ "type": "object", "properties": { "assessment": { "type": "object", "properties": { "complexity": { "type": "number" }, "impact": { "type": "number" }, "rationale": { "type": "string" }, "risk": { "type": "number" } } }, "changeClass": { "type": "string", "description": "One of: docs, test, dependency, config, source, schema, unknown. A newer deployment may report a member not in this list." }, "driftAffected": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "label": { "type": "string" }, "reason": { "type": "string", "description": "One of: key-mismatch, corrupt. A newer deployment may report a member not in this list." }, "sealedAt": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "source": { "type": "string" } } } }, "findingCount": { "type": "number" }, "forkCount": { "type": "number" }, "initiativeReason": { "type": "string", "description": "One of: item_blocked, complete, checkpoint. A newer deployment may report a member not in this list." }, "mergeTrackRecordId": { "type": "string" }, "mergedRepos": { "type": "array", "items": { "type": "string" } }, "onCallAssessment": { "type": "object", "properties": { "culpritConfidence": { "type": "number" }, "evidence": { "type": "array", "items": { "type": "string" } }, "rationale": { "type": "string" }, "recommendation": { "type": "string", "description": "One of: revert, hold, monitor. A newer deployment may report a member not in this list." } } }, "pipelineName": { "type": "string" }, "platformAlertTransition": { "type": "number" }, "platformAlerts": { "type": "array", "items": { "type": "string", "description": "One of: failure_rate_high, duration_p99_high, backlog_high, throughput_stalled, failure_kind_dominant, sweep_degraded. A newer deployment may report a member not in this list." } }, "platformFailedTotal": { "type": "number" }, "platformFailingRuns": { "type": "array", "items": { "type": "object", "properties": { "blockId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "createdAt": { "type": "number" }, "executionId": { "type": "string" }, "failureKind": { "type": "string" } } } }, "platformWindow": { "type": "string", "description": "One of: 1h, 24h, 7d. A newer deployment may report a member not in this list." }, "prUrl": { "type": "string" }, "releaseSignals": { "type": "array", "items": { "type": "object", "properties": { "detail": { "type": "string" }, "id": { "type": "string" }, "kind": { "type": "string", "description": "One of: monitor, slo. A newer deployment may report a member not in this list." }, "name": { "type": "string" }, "state": { "type": "string", "description": "One of: ok, warn, alert, no_data. A newer deployment may report a member not in this list." } } } }, "revertUrl": { "type": "string" }, "sliceCount": { "type": "number" }, "targetUserId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "unmergedRepos": { "type": "array", "items": { "type": "string" } }, "unreachableAreas": { "type": "array", "items": { "type": "string", "description": "One of: ephemeralEnvironments, agentExecutor, binaryStorage. A newer deployment may report a member not in this list." } } } }, { "type": "null" }] }, "resolvedAt": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "severity": { "type": "string", "description": "One of: normal, urgent. A newer deployment may report a member not in this list." }, "status": { "type": "string", "description": "One of: open, acted, dismissed. A newer deployment may report a member not in this list." }, "title": { "type": "string" }, "type": { "type": "string", "description": "One of: merge_review, pipeline_complete, ci_failed, test_failed, requirement_review, clarity_review, release_regression, decision_required, human_test_ready, visual_confirmation_ready, human_review, followup_pending, fork_decision_pending, judge_review, pr_review_ready, initiative, platform_health, infra_unreachable, budget_paused, key_drift, merge_tag_request. A newer deployment may report a member not in this list." } } },
|
|
206
227
|
invoke: (client, args) => client.notifications.dismiss(str(args, 'id')),
|
|
207
228
|
},
|
|
208
229
|
{
|
|
@@ -213,6 +234,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
213
234
|
readOnly: true,
|
|
214
235
|
description: 'List the workspace\'s open notifications\n\nList the open, human-actionable notifications in the key’s workspace (merge reviews, pipeline-complete confirmations, CI/test failures, and informational cards).\n\nCalls `GET /api/v1/notifications` (operation `listPublicNotifications`).',
|
|
215
236
|
inputSchema: { "type": "object", "properties": {}, "additionalProperties": false },
|
|
237
|
+
outputSchema: { "type": "object", "properties": { "notifications": { "type": "array", "items": { "type": "object", "properties": { "blockId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "body": { "type": "string" }, "createdAt": { "type": "number" }, "executionId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "id": { "type": "string" }, "payload": { "anyOf": [{ "type": "object", "properties": { "assessment": { "type": "object", "properties": { "complexity": { "type": "number" }, "impact": { "type": "number" }, "rationale": { "type": "string" }, "risk": { "type": "number" } } }, "changeClass": { "type": "string", "description": "One of: docs, test, dependency, config, source, schema, unknown. A newer deployment may report a member not in this list." }, "driftAffected": { "type": "array", "items": { "type": "object", "properties": { "id": { "type": "string" }, "label": { "type": "string" }, "reason": { "type": "string", "description": "One of: key-mismatch, corrupt. A newer deployment may report a member not in this list." }, "sealedAt": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "source": { "type": "string" } } } }, "findingCount": { "type": "number" }, "forkCount": { "type": "number" }, "initiativeReason": { "type": "string", "description": "One of: item_blocked, complete, checkpoint. A newer deployment may report a member not in this list." }, "mergeTrackRecordId": { "type": "string" }, "mergedRepos": { "type": "array", "items": { "type": "string" } }, "onCallAssessment": { "type": "object", "properties": { "culpritConfidence": { "type": "number" }, "evidence": { "type": "array", "items": { "type": "string" } }, "rationale": { "type": "string" }, "recommendation": { "type": "string", "description": "One of: revert, hold, monitor. A newer deployment may report a member not in this list." } } }, "pipelineName": { "type": "string" }, "platformAlertTransition": { "type": "number" }, "platformAlerts": { "type": "array", "items": { "type": "string", "description": "One of: failure_rate_high, duration_p99_high, backlog_high, throughput_stalled, failure_kind_dominant, sweep_degraded. A newer deployment may report a member not in this list." } }, "platformFailedTotal": { "type": "number" }, "platformFailingRuns": { "type": "array", "items": { "type": "object", "properties": { "blockId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "createdAt": { "type": "number" }, "executionId": { "type": "string" }, "failureKind": { "type": "string" } } } }, "platformWindow": { "type": "string", "description": "One of: 1h, 24h, 7d. A newer deployment may report a member not in this list." }, "prUrl": { "type": "string" }, "releaseSignals": { "type": "array", "items": { "type": "object", "properties": { "detail": { "type": "string" }, "id": { "type": "string" }, "kind": { "type": "string", "description": "One of: monitor, slo. A newer deployment may report a member not in this list." }, "name": { "type": "string" }, "state": { "type": "string", "description": "One of: ok, warn, alert, no_data. A newer deployment may report a member not in this list." } } } }, "revertUrl": { "type": "string" }, "sliceCount": { "type": "number" }, "targetUserId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "unmergedRepos": { "type": "array", "items": { "type": "string" } }, "unreachableAreas": { "type": "array", "items": { "type": "string", "description": "One of: ephemeralEnvironments, agentExecutor, binaryStorage. A newer deployment may report a member not in this list." } } } }, { "type": "null" }] }, "resolvedAt": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "severity": { "type": "string", "description": "One of: normal, urgent. A newer deployment may report a member not in this list." }, "status": { "type": "string", "description": "One of: open, acted, dismissed. A newer deployment may report a member not in this list." }, "title": { "type": "string" }, "type": { "type": "string", "description": "One of: merge_review, pipeline_complete, ci_failed, test_failed, requirement_review, clarity_review, release_regression, decision_required, human_test_ready, visual_confirmation_ready, human_review, followup_pending, fork_decision_pending, judge_review, pr_review_ready, initiative, platform_health, infra_unreachable, budget_paused, key_drift, merge_tag_request. A newer deployment may report a member not in this list." } } } } } },
|
|
216
238
|
invoke: (client, args) => client.notifications.list(),
|
|
217
239
|
},
|
|
218
240
|
{
|
|
@@ -223,6 +245,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
223
245
|
readOnly: true,
|
|
224
246
|
description: 'Read the workspace\'s usage for the current period\n\nRead this billing period’s METERED spend against the workspace budget (including whether it is exceeded, which pauses runs) plus the per-(billing, vendor, provider, model) token breakdown behind it. Costs on `subscription` rows are illustrative — a flat-rate plan bills nothing per token — so branch on `billing` before summing. Workspace-scoped: the account- and user-tier budgets are not reachable through this surface.\n\nCalls `GET /api/v1/usage` (operation `getPublicUsage`).',
|
|
225
247
|
inputSchema: { "type": "object", "properties": {}, "additionalProperties": false },
|
|
248
|
+
outputSchema: { "type": "object", "properties": { "budget": { "type": "object", "properties": { "costLimit": { "type": "number" }, "costSpent": { "type": "number" }, "exceeded": { "type": "boolean" }, "inputTokens": { "type": "number" }, "outputTokens": { "type": "number" } } }, "currency": { "type": "string" }, "periodStart": { "type": "number" }, "rows": { "type": "array", "items": { "type": "object", "properties": { "billing": { "type": "string", "description": "One of: metered, subscription. A newer deployment may report a member not in this list." }, "calls": { "type": "number" }, "costEstimate": { "type": "number" }, "inputTokens": { "type": "number" }, "model": { "type": "string" }, "outputTokens": { "type": "number" }, "provider": { "type": "string" }, "vendor": { "anyOf": [{ "type": "string" }, { "type": "null" }] } } } } } },
|
|
226
249
|
invoke: (client, args) => client.usage.get(),
|
|
227
250
|
},
|
|
228
251
|
{
|
|
@@ -233,6 +256,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
233
256
|
readOnly: false,
|
|
234
257
|
description: 'Choose an implementation approach\n\nPick one of the proposed implementation forks (by id) or submit your own approach. The Coder then runs with the choice folded in as a binding directive. Requires a `decide`-scope key.\n\nCalls `POST /api/v1/runs/{runId}/decisions/fork/choose` (operation `choosePublicRunFork`).',
|
|
235
258
|
inputSchema: { "type": "object", "properties": { "runId": { "type": "string", "description": "Path parameter `runId`." }, "body": { "type": "object", "properties": { "custom": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "forkId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "note": { "anyOf": [{ "type": "string" }, { "type": "null" }] } }, "description": "The request body." } }, "additionalProperties": false, "required": ["runId", "body"] },
|
|
259
|
+
outputSchema: { "type": "object", "properties": { "decisions": { "type": "array", "items": { "description": "Discriminated by `kind` (requirements-review | fork | judge | input-gate). A newer deployment may report a variant not in this list." } }, "parked": { "type": "boolean" }, "runId": { "type": "string" }, "status": { "type": "string", "description": "One of: running, blocked, paused, done, failed. A newer deployment may report a member not in this list." }, "taskId": { "type": "string" } } },
|
|
236
260
|
invoke: (client, args) => client.decisions.chooseFork(str(args, 'runId'), args.body),
|
|
237
261
|
},
|
|
238
262
|
{
|
|
@@ -243,6 +267,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
243
267
|
readOnly: false,
|
|
244
268
|
description: 'Incorporate the answers\n\nFold the recorded answers into one standardized requirements document. Asynchronous — the run re-reviews in the background, so the response shows the review `incorporating`. Requires a `decide`-scope key.\n\nCalls `POST /api/v1/runs/{runId}/decisions/requirements/incorporate` (operation `incorporatePublicRunRequirements`).',
|
|
245
269
|
inputSchema: { "type": "object", "properties": { "runId": { "type": "string", "description": "Path parameter `runId`." }, "body": { "type": "object", "properties": { "feedback": { "type": "string", "maxLength": 4000 } }, "description": "The request body." } }, "additionalProperties": false, "required": ["runId", "body"] },
|
|
270
|
+
outputSchema: { "type": "object", "properties": { "decisions": { "type": "array", "items": { "description": "Discriminated by `kind` (requirements-review | fork | judge | input-gate). A newer deployment may report a variant not in this list." } }, "parked": { "type": "boolean" }, "runId": { "type": "string" }, "status": { "type": "string", "description": "One of: running, blocked, paused, done, failed. A newer deployment may report a member not in this list." }, "taskId": { "type": "string" } } },
|
|
246
271
|
invoke: (client, args) => client.decisions.incorporate(str(args, 'runId'), args.body),
|
|
247
272
|
},
|
|
248
273
|
{
|
|
@@ -253,6 +278,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
253
278
|
readOnly: true,
|
|
254
279
|
description: 'List a run\'s parked decisions\n\nRead what a run is currently asking a human: requirement-review findings (with the stable item ids a reply addresses) and any implementation-fork choice. `parked` is true while the run is blocked awaiting one of them.\n\nCalls `GET /api/v1/runs/{runId}/decisions` (operation `listPublicRunDecisions`).',
|
|
255
280
|
inputSchema: { "type": "object", "properties": { "runId": { "type": "string", "description": "Path parameter `runId`." } }, "additionalProperties": false, "required": ["runId"] },
|
|
281
|
+
outputSchema: { "type": "object", "properties": { "decisions": { "type": "array", "items": { "description": "Discriminated by `kind` (requirements-review | fork | judge | input-gate). A newer deployment may report a variant not in this list." } }, "parked": { "type": "boolean" }, "runId": { "type": "string" }, "status": { "type": "string", "description": "One of: running, blocked, paused, done, failed. A newer deployment may report a member not in this list." }, "taskId": { "type": "string" } } },
|
|
256
282
|
invoke: (client, args) => client.decisions.list(str(args, 'runId')),
|
|
257
283
|
},
|
|
258
284
|
{
|
|
@@ -263,6 +289,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
263
289
|
readOnly: false,
|
|
264
290
|
description: 'Proceed with the current requirements\n\nSettle the requirements phase and advance the parked run (used when nothing is outstanding). Requires a `decide`-scope key.\n\nCalls `POST /api/v1/runs/{runId}/decisions/requirements/proceed` (operation `proceedPublicRunRequirements`).',
|
|
265
291
|
inputSchema: { "type": "object", "properties": { "runId": { "type": "string", "description": "Path parameter `runId`." } }, "additionalProperties": false, "required": ["runId"] },
|
|
292
|
+
outputSchema: { "type": "object", "properties": { "decisions": { "type": "array", "items": { "description": "Discriminated by `kind` (requirements-review | fork | judge | input-gate). A newer deployment may report a variant not in this list." } }, "parked": { "type": "boolean" }, "runId": { "type": "string" }, "status": { "type": "string", "description": "One of: running, blocked, paused, done, failed. A newer deployment may report a member not in this list." }, "taskId": { "type": "string" } } },
|
|
266
293
|
invoke: (client, args) => client.decisions.proceed(str(args, 'runId')),
|
|
267
294
|
},
|
|
268
295
|
{
|
|
@@ -273,6 +300,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
273
300
|
readOnly: false,
|
|
274
301
|
description: 'Answer a review finding\n\nRecord an answer to one reviewer finding. Returns the run\'s updated decision list. Requires a `decide`-scope key.\n\nCalls `POST /api/v1/runs/{runId}/decisions/requirements/findings/{itemId}/reply` (operation `replyPublicRunFinding`).',
|
|
275
302
|
inputSchema: { "type": "object", "properties": { "runId": { "type": "string", "description": "Path parameter `runId`." }, "itemId": { "type": "string", "description": "Path parameter `itemId`." }, "body": { "type": "object", "properties": { "reply": { "type": "string", "minLength": 1, "maxLength": 4000 } }, "required": ["reply"], "description": "The request body." } }, "additionalProperties": false, "required": ["runId", "itemId", "body"] },
|
|
303
|
+
outputSchema: { "type": "object", "properties": { "decisions": { "type": "array", "items": { "description": "Discriminated by `kind` (requirements-review | fork | judge | input-gate). A newer deployment may report a variant not in this list." } }, "parked": { "type": "boolean" }, "runId": { "type": "string" }, "status": { "type": "string", "description": "One of: running, blocked, paused, done, failed. A newer deployment may report a member not in this list." }, "taskId": { "type": "string" } } },
|
|
276
304
|
invoke: (client, args) => client.decisions.replyToFinding(str(args, 'runId'), str(args, 'itemId'), args.body),
|
|
277
305
|
},
|
|
278
306
|
{
|
|
@@ -283,6 +311,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
283
311
|
readOnly: false,
|
|
284
312
|
description: 'Re-review the incorporated document\n\nRun one more reviewer pass over the incorporated document. On convergence the parked run advances. Requires a `decide`-scope key.\n\nCalls `POST /api/v1/runs/{runId}/decisions/requirements/re-review` (operation `reReviewPublicRunRequirements`).',
|
|
285
313
|
inputSchema: { "type": "object", "properties": { "runId": { "type": "string", "description": "Path parameter `runId`." } }, "additionalProperties": false, "required": ["runId"] },
|
|
314
|
+
outputSchema: { "type": "object", "properties": { "decisions": { "type": "array", "items": { "description": "Discriminated by `kind` (requirements-review | fork | judge | input-gate). A newer deployment may report a variant not in this list." } }, "parked": { "type": "boolean" }, "runId": { "type": "string" }, "status": { "type": "string", "description": "One of: running, blocked, paused, done, failed. A newer deployment may report a member not in this list." }, "taskId": { "type": "string" } } },
|
|
286
315
|
invoke: (client, args) => client.decisions.reReview(str(args, 'runId')),
|
|
287
316
|
},
|
|
288
317
|
{
|
|
@@ -293,6 +322,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
293
322
|
readOnly: false,
|
|
294
323
|
description: 'Resolve a review at its iteration cap\n\nPick how a review that exhausted its reviewer-pass budget proceeds: one more round, proceed with the last incorporated document, or stop and reset the task. Requires a `decide`-scope key.\n\nCalls `POST /api/v1/runs/{runId}/decisions/requirements/resolve-exceeded` (operation `resolvePublicRunRequirementsExceeded`).',
|
|
295
324
|
inputSchema: { "type": "object", "properties": { "runId": { "type": "string", "description": "Path parameter `runId`." }, "body": { "type": "object", "properties": { "choice": { "type": "string", "enum": ["extra-round", "proceed", "stop-reset"] } }, "required": ["choice"], "description": "The request body." } }, "additionalProperties": false, "required": ["runId", "body"] },
|
|
325
|
+
outputSchema: { "type": "object", "properties": { "decisions": { "type": "array", "items": { "description": "Discriminated by `kind` (requirements-review | fork | judge | input-gate). A newer deployment may report a variant not in this list." } }, "parked": { "type": "boolean" }, "runId": { "type": "string" }, "status": { "type": "string", "description": "One of: running, blocked, paused, done, failed. A newer deployment may report a member not in this list." }, "taskId": { "type": "string" } } },
|
|
296
326
|
invoke: (client, args) => client.decisions.resolveExceeded(str(args, 'runId'), args.body),
|
|
297
327
|
},
|
|
298
328
|
{
|
|
@@ -303,6 +333,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
303
333
|
readOnly: false,
|
|
304
334
|
description: 'Resolve a run parked on the task\'s input check\n\nSettle a run the pre-token input gate parked before its first agent step because the task states nothing an agent could act on. `recheck` re-evaluates the task as it now stands (edit it over `PATCH /api/v1/tasks/{taskId}` first: the fix is verified, not taken on trust) and releases the run only if the blocking findings are gone; a still-blocked verdict comes back as an ordinary 200 with refreshed findings. `proceed` waives the findings, which stay on the run as an `overridden` record. Requires a `decide`-scope key.\n\nCalls `POST /api/v1/runs/{runId}/decisions/input-gate/resolve` (operation `resolvePublicRunInputGate`).',
|
|
305
335
|
inputSchema: { "type": "object", "properties": { "runId": { "type": "string", "description": "Path parameter `runId`." }, "body": { "type": "object", "properties": { "choice": { "type": "string", "enum": ["recheck", "proceed"] } }, "required": ["choice"], "description": "The request body." } }, "additionalProperties": false, "required": ["runId", "body"] },
|
|
336
|
+
outputSchema: { "type": "object", "properties": { "decisions": { "type": "array", "items": { "description": "Discriminated by `kind` (requirements-review | fork | judge | input-gate). A newer deployment may report a variant not in this list." } }, "parked": { "type": "boolean" }, "runId": { "type": "string" }, "status": { "type": "string", "description": "One of: running, blocked, paused, done, failed. A newer deployment may report a member not in this list." }, "taskId": { "type": "string" } } },
|
|
306
337
|
invoke: (client, args) => client.decisions.resolveInputGate(str(args, 'runId'), args.body),
|
|
307
338
|
},
|
|
308
339
|
{
|
|
@@ -313,6 +344,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
313
344
|
readOnly: false,
|
|
314
345
|
description: 'Resolve a parked judge verdict\n\nSettle a run parked on a judge verdict: proceed anyway, bounce the producing step for rework, or stop the run. Requires a `decide`-scope key.\n\nCalls `POST /api/v1/runs/{runId}/decisions/judge/resolve` (operation `resolvePublicRunJudge`).',
|
|
315
346
|
inputSchema: { "type": "object", "properties": { "runId": { "type": "string", "description": "Path parameter `runId`." }, "body": { "type": "object", "properties": { "choice": { "type": "string", "enum": ["proceed", "bounce", "stop"] }, "feedback": { "anyOf": [{ "type": "string" }, { "type": "null" }] } }, "required": ["choice"], "description": "The request body." } }, "additionalProperties": false, "required": ["runId", "body"] },
|
|
347
|
+
outputSchema: { "type": "object", "properties": { "decisions": { "type": "array", "items": { "description": "Discriminated by `kind` (requirements-review | fork | judge | input-gate). A newer deployment may report a variant not in this list." } }, "parked": { "type": "boolean" }, "runId": { "type": "string" }, "status": { "type": "string", "description": "One of: running, blocked, paused, done, failed. A newer deployment may report a member not in this list." }, "taskId": { "type": "string" } } },
|
|
316
348
|
invoke: (client, args) => client.decisions.resolveJudge(str(args, 'runId'), args.body),
|
|
317
349
|
},
|
|
318
350
|
{
|
|
@@ -323,6 +355,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
323
355
|
readOnly: false,
|
|
324
356
|
description: 'Dismiss or reopen a finding\n\nDismiss a finding as not applicable, or reopen one dismissed by mistake. Requires a `decide`-scope key.\n\nCalls `PATCH /api/v1/runs/{runId}/decisions/requirements/findings/{itemId}` (operation `setPublicRunFindingStatus`).',
|
|
325
357
|
inputSchema: { "type": "object", "properties": { "runId": { "type": "string", "description": "Path parameter `runId`." }, "itemId": { "type": "string", "description": "Path parameter `itemId`." }, "body": { "type": "object", "properties": { "status": { "type": "string", "enum": ["dismissed", "open"] } }, "required": ["status"], "description": "The request body." } }, "additionalProperties": false, "required": ["runId", "itemId", "body"] },
|
|
358
|
+
outputSchema: { "type": "object", "properties": { "decisions": { "type": "array", "items": { "description": "Discriminated by `kind` (requirements-review | fork | judge | input-gate). A newer deployment may report a variant not in this list." } }, "parked": { "type": "boolean" }, "runId": { "type": "string" }, "status": { "type": "string", "description": "One of: running, blocked, paused, done, failed. A newer deployment may report a member not in this list." }, "taskId": { "type": "string" } } },
|
|
326
359
|
invoke: (client, args) => client.decisions.setFindingStatus(str(args, 'runId'), str(args, 'itemId'), args.body),
|
|
327
360
|
},
|
|
328
361
|
{
|
|
@@ -333,6 +366,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
333
366
|
readOnly: true,
|
|
334
367
|
description: 'Get one agent-context snapshot\n\nThe complete context one dispatch was PROVIDED: system and user prompts, the folded standards fragments, and the injected `.cat-context/*` files an agent reads through tools (which therefore appear in no proxy telemetry). Windowed by `bodyOffset`/`bodyChars`.\n\nCalls `GET /api/v1/debug/agent-context/{snapshotId}` (operation `getDebugAgentContext`).',
|
|
335
368
|
inputSchema: { "type": "object", "properties": { "snapshotId": { "type": "string", "description": "Path parameter `snapshotId`." }, "bodyChars": { "type": "integer" }, "bodyOffset": { "type": "integer" } }, "additionalProperties": false, "required": ["snapshotId"] },
|
|
369
|
+
outputSchema: { "type": "object", "properties": { "agentKind": { "type": "string" }, "contextFiles": { "type": "array", "items": { "type": "object", "properties": { "content": { "type": "object", "properties": { "chars": { "type": "number" }, "matchOffset": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "offset": { "type": "number" }, "text": { "type": "string" }, "totalChars": { "type": "number" }, "truncated": { "type": "boolean" } } }, "path": { "type": "string" }, "title": { "type": "string" }, "url": { "type": "string" } } } }, "createdAt": { "type": "number" }, "extras": { "type": "object", "additionalProperties": {} }, "fragments": { "type": "array", "items": { "type": "object", "properties": { "body": { "type": "object", "properties": { "chars": { "type": "number" }, "matchOffset": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "offset": { "type": "number" }, "text": { "type": "string" }, "totalChars": { "type": "number" }, "truncated": { "type": "boolean" } } }, "id": { "type": "string" } } } }, "harness": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "model": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "runId": { "type": "string" }, "snapshotId": { "type": "string" }, "stepIndex": { "type": "number" }, "systemPrompt": { "type": "object", "properties": { "chars": { "type": "number" }, "matchOffset": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "offset": { "type": "number" }, "text": { "type": "string" }, "totalChars": { "type": "number" }, "truncated": { "type": "boolean" } } }, "userPrompt": { "type": "object", "properties": { "chars": { "type": "number" }, "matchOffset": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "offset": { "type": "number" }, "text": { "type": "string" }, "totalChars": { "type": "number" }, "truncated": { "type": "boolean" } } } } },
|
|
336
370
|
invoke: (client, args) => client.debug.getAgentContext(str(args, 'snapshotId'), pick(args, QUERY_DEBUG_GET_AGENT_CONTEXT)),
|
|
337
371
|
},
|
|
338
372
|
{
|
|
@@ -343,6 +377,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
343
377
|
readOnly: true,
|
|
344
378
|
description: 'Get one LLM call\n\nOne recorded model call with its budgeted prompt delta, response and reasoning. `bodyOffset`/`bodyChars` window the bodies, so an arbitrarily long transcript is readable in bounded pages.\n\nCalls `GET /api/v1/debug/llm-calls/{callId}` (operation `getDebugLlmCall`).',
|
|
345
379
|
inputSchema: { "type": "object", "properties": { "callId": { "type": "string", "description": "Path parameter `callId`." }, "bodyChars": { "type": "integer" }, "bodyOffset": { "type": "integer" }, "view": { "type": "string", "enum": ["raw", "messages"] } }, "additionalProperties": false, "required": ["callId"] },
|
|
380
|
+
outputSchema: { "type": "object", "properties": { "agentKind": { "type": "string" }, "cacheReadTokens": { "type": "number" }, "cacheWriteTokens": { "type": "number" }, "callId": { "type": "string" }, "completionTokens": { "type": "number" }, "createdAt": { "type": "number" }, "elidedLeadingMessages": { "type": "number" }, "errorMessage": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "finishReason": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "httpStatus": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "messageCount": { "type": "number" }, "model": { "type": "string" }, "ok": { "type": "boolean" }, "outcome": { "type": "string", "description": "One of: ok, warning, error. A newer deployment may report a member not in this list." }, "overheadMs": { "type": "number" }, "phase": { "type": "string" }, "prompt": { "type": "object", "properties": { "chars": { "type": "number" }, "matchOffset": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "offset": { "type": "number" }, "text": { "type": "string" }, "totalChars": { "type": "number" }, "truncated": { "type": "boolean" } } }, "promptMessages": { "anyOf": [{ "type": "array", "items": { "type": "object", "properties": { "content": { "type": "object", "properties": { "chars": { "type": "number" }, "matchOffset": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "offset": { "type": "number" }, "text": { "type": "string" }, "totalChars": { "type": "number" }, "truncated": { "type": "boolean" } } }, "index": { "type": "number" }, "name": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "role": { "type": "string" }, "toolCallId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "toolCalls": { "type": "array", "items": { "type": "object", "properties": { "args": { "type": "object", "properties": { "chars": { "type": "number" }, "matchOffset": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "offset": { "type": "number" }, "text": { "type": "string" }, "totalChars": { "type": "number" }, "truncated": { "type": "boolean" } } }, "name": { "type": "string" } } } } } } }, { "type": "null" }] }, "promptTokens": { "type": "number" }, "provider": { "type": "string" }, "reasoning": { "type": "object", "properties": { "chars": { "type": "number" }, "matchOffset": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "offset": { "type": "number" }, "text": { "type": "string" }, "totalChars": { "type": "number" }, "truncated": { "type": "boolean" } } }, "requestMaxTokens": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "response": { "type": "object", "properties": { "chars": { "type": "number" }, "matchOffset": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "offset": { "type": "number" }, "text": { "type": "string" }, "totalChars": { "type": "number" }, "truncated": { "type": "boolean" } } }, "runId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "streaming": { "type": "boolean" }, "toolCount": { "type": "number" }, "totalMs": { "type": "number" }, "totalTokens": { "type": "number" }, "turnIndex": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "upstreamMs": { "type": "number" } } },
|
|
346
381
|
invoke: (client, args) => client.debug.getLlmCall(str(args, 'callId'), pick(args, QUERY_DEBUG_GET_LLM_CALL)),
|
|
347
382
|
},
|
|
348
383
|
{
|
|
@@ -353,6 +388,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
353
388
|
readOnly: true,
|
|
354
389
|
description: 'Get a run\'s diagnostic map\n\nOne run’s diagnostic overview: its steps, which telemetry sinks this deployment retains (and how much each holds), the LLM cost/latency rollups, and the derived signals worth looking at first.\n\nCalls `GET /api/v1/debug/runs/{runId}` (operation `getDebugRun`).',
|
|
355
390
|
inputSchema: { "type": "object", "properties": { "runId": { "type": "string", "description": "Path parameter `runId`." } }, "additionalProperties": false, "required": ["runId"] },
|
|
391
|
+
outputSchema: { "type": "object", "properties": { "diagnostics": { "anyOf": [{ "type": "object", "properties": { "host": { "type": "object", "properties": { "platform": { "type": "string" } } }, "lastDispatch": { "type": "object", "properties": { "agentKind": { "type": "string" }, "at": { "type": "number" }, "executionBackend": { "type": "string" }, "model": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "repo": { "type": "object", "properties": { "baseBranch": { "type": "string" }, "name": { "type": "string" }, "owner": { "type": "string" }, "provider": { "type": "string" } } }, "stepIndex": { "type": "number" } } } } }, { "type": "null" }] }, "generatedAt": { "type": "number" }, "kind": { "type": "string" }, "llm": { "type": "object", "properties": { "byAgentKind": { "type": "array", "items": { "type": "object", "properties": { "agentKind": { "type": "string" }, "cacheHitRate": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "cacheReadTokens": { "type": "number" }, "cacheWriteTokens": { "type": "number" }, "calls": { "type": "number" }, "completionTokens": { "type": "number" }, "costEstimate": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "errors": { "type": "number" }, "maxOutputTokens": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "outputHeadroomRatio": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "overheadMs": { "type": "number" }, "peakCompletionTokens": { "type": "number" }, "promptTokens": { "type": "number" }, "transportOverheadRatio": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "truncatedCalls": { "type": "number" }, "upstreamMs": { "type": "number" }, "warnings": { "type": "number" } } } }, "byPhase": { "type": "array", "items": { "type": "object", "properties": { "cacheHitRate": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "cacheReadTokens": { "type": "number" }, "cacheWriteTokens": { "type": "number" }, "calls": { "type": "number" }, "carryCostShare": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "carryCostTokens": { "type": "number" }, "completionTokens": { "type": "number" }, "costEstimate": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "errors": { "type": "number" }, "overheadMs": { "type": "number" }, "phase": { "type": "string" }, "promptTokens": { "type": "number" }, "truncatedCalls": { "type": "number" }, "upstreamMs": { "type": "number" }, "warnings": { "type": "number" } } } }, "costCurrency": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "totals": { "type": "object", "properties": { "cacheHitRate": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "cacheReadTokens": { "type": "number" }, "cacheWriteTokens": { "type": "number" }, "calls": { "type": "number" }, "completionTokens": { "type": "number" }, "costEstimate": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "errors": { "type": "number" }, "overheadMs": { "type": "number" }, "promptTokens": { "type": "number" }, "transportOverheadRatio": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "truncatedCalls": { "type": "number" }, "upstreamMs": { "type": "number" }, "warnings": { "type": "number" } } } } }, "run": { "type": "object", "properties": { "blockId": { "type": "string" }, "createdAt": { "type": "number" }, "currentStep": { "type": "number" }, "failure": { "anyOf": [{ "type": "object", "properties": { "detail": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "hint": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "kind": { "type": "string", "description": "One of: preflight, dispatch, environment, evicted, timeout, agent, job_failed, rejected, companion_rejected, stalled, cancelled, unknown. A newer deployment may report a member not in this list." }, "lastSubtasks": { "anyOf": [{ "type": "object", "properties": { "completed": { "type": "number" }, "inProgress": { "type": "number" }, "items": { "type": "array", "items": { "type": "object", "properties": { "label": { "type": "string" }, "status": { "type": "string", "description": "One of: pending, in_progress, completed. A newer deployment may report a member not in this list." } } } }, "total": { "type": "number" } } }, { "type": "null" }] }, "message": { "type": "string" }, "occurredAt": { "type": "number" }, "reason": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "stepIndex": { "type": "number" } } }, { "type": "null" }] }, "pipelineId": { "type": "string" }, "pipelineName": { "type": "string" }, "runId": { "type": "string" }, "status": { "type": "string", "description": "One of: running, blocked, paused, done, failed. A newer deployment may report a member not in this list." }, "stepCount": { "type": "number" } } }, "signals": { "type": "array", "items": { "type": "object", "properties": { "agentKind": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "code": { "type": "string" }, "count": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "message": { "type": "string" }, "severity": { "type": "string", "description": "One of: info, warning, error. A newer deployment may report a member not in this list." }, "stepIndex": { "anyOf": [{ "type": "number" }, { "type": "null" }] } } } }, "sinks": { "type": "object", "properties": { "agentContext": { "type": "object", "properties": { "available": { "type": "boolean" }, "count": { "type": "number" } } }, "llmCalls": { "type": "object", "properties": { "available": { "type": "boolean" }, "count": { "type": "number" } } }, "provisioningLog": { "type": "object", "properties": { "available": { "type": "boolean" }, "count": { "type": "number" } } }, "searchQueries": { "type": "object", "properties": { "available": { "type": "boolean" }, "count": { "type": "number" } } } } }, "steps": { "type": "array", "items": { "type": "object", "properties": { "agentKind": { "type": "string" }, "evictionRecoveries": { "type": "number" }, "finishedAt": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "firstEvictionDetail": { "anyOf": [{ "type": "object", "properties": { "chars": { "type": "number" }, "matchOffset": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "offset": { "type": "number" }, "text": { "type": "string" }, "totalChars": { "type": "number" }, "truncated": { "type": "boolean" } } }, { "type": "null" }] }, "hasStructuredResult": { "type": "boolean" }, "index": { "type": "number" }, "lastActivityAt": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "model": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "outputChars": { "type": "number" }, "progress": { "type": "number" }, "skipped": { "type": "boolean" }, "startedAt": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "state": { "type": "string" }, "subtasks": { "anyOf": [{ "type": "object", "properties": { "completed": { "type": "number" }, "inProgress": { "type": "number" }, "total": { "type": "number" } } }, { "type": "null" }] } } } }, "version": { "type": "number" } } },
|
|
356
392
|
invoke: (client, args) => client.debug.getRun(str(args, 'runId')),
|
|
357
393
|
},
|
|
358
394
|
{
|
|
@@ -363,6 +399,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
363
399
|
readOnly: true,
|
|
364
400
|
description: 'List a run\'s agent-context dispatches\n\nEvery dispatch whose provided context was captured, with SIZES only (no bodies) so the list stays bounded. Read one in full through the snapshot endpoint.\n\nCalls `GET /api/v1/debug/runs/{runId}/agent-context` (operation `listDebugAgentContext`).',
|
|
365
401
|
inputSchema: { "type": "object", "properties": { "runId": { "type": "string", "description": "Path parameter `runId`." }, "stepIndex": { "type": "integer" }, "limit": { "type": "integer" }, "cursor": { "type": "string" } }, "additionalProperties": false, "required": ["runId"] },
|
|
402
|
+
outputSchema: { "type": "object", "properties": { "nextCursor": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "snapshots": { "type": "array", "items": { "type": "object", "properties": { "agentKind": { "type": "string" }, "contextFilesChars": { "type": "number" }, "createdAt": { "type": "number" }, "fragmentsChars": { "type": "number" }, "harness": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "model": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "snapshotId": { "type": "string" }, "stepIndex": { "type": "number" }, "systemPromptChars": { "type": "number" }, "userPromptChars": { "type": "number" } } } } } },
|
|
366
403
|
invoke: (client, args) => client.debug.listAgentContext(str(args, 'runId'), pick(args, QUERY_DEBUG_LIST_AGENT_CONTEXT)),
|
|
367
404
|
},
|
|
368
405
|
{
|
|
@@ -373,6 +410,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
373
410
|
readOnly: true,
|
|
374
411
|
description: 'List a run\'s LLM calls\n\nThe model calls a run made, keyset-paginated and filterable by agent kind, phase, outcome or a substring of the bodies. Bodies are returned only when `bodyChars` asks for them.\n\nCalls `GET /api/v1/debug/runs/{runId}/llm-calls` (operation `listDebugLlmCalls`).',
|
|
375
412
|
inputSchema: { "type": "object", "properties": { "runId": { "type": "string", "description": "Path parameter `runId`." }, "agentKind": { "type": "string" }, "phase": { "type": "string" }, "outcome": { "type": "string", "enum": ["ok", "warning", "error"] }, "contains": { "type": "string" }, "order": { "type": "string", "enum": ["newest", "oldest"] }, "limit": { "type": "integer" }, "cursor": { "type": "string" }, "bodyChars": { "type": "integer" } }, "additionalProperties": false, "required": ["runId"] },
|
|
413
|
+
outputSchema: { "type": "object", "properties": { "calls": { "type": "array", "items": { "type": "object", "properties": { "agentKind": { "type": "string" }, "cacheReadTokens": { "type": "number" }, "cacheWriteTokens": { "type": "number" }, "callId": { "type": "string" }, "completionTokens": { "type": "number" }, "createdAt": { "type": "number" }, "elidedLeadingMessages": { "type": "number" }, "errorMessage": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "finishReason": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "httpStatus": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "messageCount": { "type": "number" }, "model": { "type": "string" }, "ok": { "type": "boolean" }, "outcome": { "type": "string", "description": "One of: ok, warning, error. A newer deployment may report a member not in this list." }, "overheadMs": { "type": "number" }, "phase": { "type": "string" }, "prompt": { "type": "object", "properties": { "chars": { "type": "number" }, "matchOffset": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "offset": { "type": "number" }, "text": { "type": "string" }, "totalChars": { "type": "number" }, "truncated": { "type": "boolean" } } }, "promptMessages": { "anyOf": [{ "type": "array", "items": { "type": "object", "properties": { "content": { "type": "object", "properties": { "chars": { "type": "number" }, "matchOffset": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "offset": { "type": "number" }, "text": { "type": "string" }, "totalChars": { "type": "number" }, "truncated": { "type": "boolean" } } }, "index": { "type": "number" }, "name": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "role": { "type": "string" }, "toolCallId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "toolCalls": { "type": "array", "items": { "type": "object", "properties": { "args": { "type": "object", "properties": { "chars": { "type": "number" }, "matchOffset": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "offset": { "type": "number" }, "text": { "type": "string" }, "totalChars": { "type": "number" }, "truncated": { "type": "boolean" } } }, "name": { "type": "string" } } } } } } }, { "type": "null" }] }, "promptTokens": { "type": "number" }, "provider": { "type": "string" }, "reasoning": { "type": "object", "properties": { "chars": { "type": "number" }, "matchOffset": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "offset": { "type": "number" }, "text": { "type": "string" }, "totalChars": { "type": "number" }, "truncated": { "type": "boolean" } } }, "requestMaxTokens": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "response": { "type": "object", "properties": { "chars": { "type": "number" }, "matchOffset": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "offset": { "type": "number" }, "text": { "type": "string" }, "totalChars": { "type": "number" }, "truncated": { "type": "boolean" } } }, "runId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "streaming": { "type": "boolean" }, "toolCount": { "type": "number" }, "totalMs": { "type": "number" }, "totalTokens": { "type": "number" }, "turnIndex": { "anyOf": [{ "type": "number" }, { "type": "null" }] }, "upstreamMs": { "type": "number" } } } }, "nextCursor": { "anyOf": [{ "type": "string" }, { "type": "null" }] } } },
|
|
376
414
|
invoke: (client, args) => client.debug.listLlmCalls(str(args, 'runId'), pick(args, QUERY_DEBUG_LIST_LLM_CALLS)),
|
|
377
415
|
},
|
|
378
416
|
{
|
|
@@ -383,6 +421,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
383
421
|
readOnly: true,
|
|
384
422
|
description: 'List a run\'s infrastructure log\n\nThe run’s provisioning event log — how its environment, runner pool and containers came up, or why they did not.\n\nCalls `GET /api/v1/debug/runs/{runId}/logs` (operation `listDebugLogs`).',
|
|
385
423
|
inputSchema: { "type": "object", "properties": { "runId": { "type": "string", "description": "Path parameter `runId`." }, "limit": { "type": "integer" }, "cursor": { "type": "string" } }, "additionalProperties": false, "required": ["runId"] },
|
|
424
|
+
outputSchema: { "type": "object", "properties": { "entries": { "type": "array", "items": { "type": "object", "properties": { "blockId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "createdAt": { "type": "number" }, "detail": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "error": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "executionId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "id": { "type": "string" }, "operation": { "type": "string", "description": "One of: provision, teardown, status, dispatch, release, poll-failure. A newer deployment may report a member not in this list." }, "outcome": { "type": "string", "description": "One of: success, failure. A newer deployment may report a member not in this list." }, "providerId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "subsystem": { "type": "string", "description": "One of: environment, runner-pool, container. A newer deployment may report a member not in this list." }, "targetId": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "workspaceId": { "type": "string" } } } }, "nextCursor": { "anyOf": [{ "type": "string" }, { "type": "null" }] } } },
|
|
386
425
|
invoke: (client, args) => client.debug.listLogs(str(args, 'runId'), pick(args, QUERY_DEBUG_LIST_LOGS)),
|
|
387
426
|
},
|
|
388
427
|
{
|
|
@@ -393,6 +432,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
393
432
|
readOnly: true,
|
|
394
433
|
description: 'List the workspace\'s runs\n\nThe triage entry point: the workspace’s runs, newest first and keyset-paginated, with an optional status and `since` filter.\n\nCalls `GET /api/v1/debug/runs` (operation `listDebugRuns`).',
|
|
395
434
|
inputSchema: { "type": "object", "properties": { "status": { "type": "string", "enum": ["running", "blocked", "paused", "done", "failed"] }, "since": { "type": "integer" }, "limit": { "type": "integer" }, "cursor": { "type": "string" } }, "additionalProperties": false },
|
|
435
|
+
outputSchema: { "type": "object", "properties": { "nextCursor": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "runs": { "type": "array", "items": { "type": "object", "properties": { "blockId": { "type": "string" }, "createdAt": { "type": "number" }, "currentStep": { "type": "number" }, "failure": { "anyOf": [{ "type": "object", "properties": { "detail": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "hint": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "kind": { "type": "string", "description": "One of: preflight, dispatch, environment, evicted, timeout, agent, job_failed, rejected, companion_rejected, stalled, cancelled, unknown. A newer deployment may report a member not in this list." }, "lastSubtasks": { "anyOf": [{ "type": "object", "properties": { "completed": { "type": "number" }, "inProgress": { "type": "number" }, "items": { "type": "array", "items": { "type": "object", "properties": { "label": { "type": "string" }, "status": { "type": "string", "description": "One of: pending, in_progress, completed. A newer deployment may report a member not in this list." } } } }, "total": { "type": "number" } } }, { "type": "null" }] }, "message": { "type": "string" }, "occurredAt": { "type": "number" }, "reason": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "stepIndex": { "type": "number" } } }, { "type": "null" }] }, "pipelineId": { "type": "string" }, "pipelineName": { "type": "string" }, "runId": { "type": "string" }, "status": { "type": "string", "description": "One of: running, blocked, paused, done, failed. A newer deployment may report a member not in this list." }, "stepCount": { "type": "number" } } } } } },
|
|
396
436
|
invoke: (client, args) => client.debug.listRuns(pick(args, QUERY_DEBUG_LIST_RUNS)),
|
|
397
437
|
},
|
|
398
438
|
{
|
|
@@ -403,6 +443,7 @@ export const CAT_FACTORY_TOOLS = [
|
|
|
403
443
|
readOnly: true,
|
|
404
444
|
description: 'List a run\'s web searches\n\nThe web searches the run’s agents actually performed, keyset-paginated. Retained only when the deployment records agent context.\n\nCalls `GET /api/v1/debug/runs/{runId}/search-queries` (operation `listDebugSearchQueries`).',
|
|
405
445
|
inputSchema: { "type": "object", "properties": { "runId": { "type": "string", "description": "Path parameter `runId`." }, "limit": { "type": "integer" }, "cursor": { "type": "string" } }, "additionalProperties": false, "required": ["runId"] },
|
|
446
|
+
outputSchema: { "type": "object", "properties": { "nextCursor": { "anyOf": [{ "type": "string" }, { "type": "null" }] }, "queries": { "type": "array", "items": { "type": "object", "properties": { "agentKind": { "type": "string" }, "createdAt": { "type": "number" }, "executionId": { "type": "string" }, "id": { "type": "string" }, "provider": { "anyOf": [{ "type": "string", "description": "One of: brave, searxng. A newer deployment may report a member not in this list." }, { "type": "null" }] }, "query": { "type": "string" }, "resultCount": { "type": "number" }, "workspaceId": { "type": "string" } } } } } },
|
|
406
447
|
invoke: (client, args) => client.debug.listSearchQueries(str(args, 'runId'), pick(args, QUERY_DEBUG_LIST_SEARCH_QUERIES)),
|
|
407
448
|
},
|
|
408
449
|
];
|