@agent-tasks/mcp-server 0.12.0 → 0.14.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 CHANGED
@@ -21,12 +21,13 @@ node mcp-server/dist/index.js
21
21
 
22
22
  ## Configuration
23
23
 
24
- Two environment variables:
24
+ Three environment variables:
25
25
 
26
- | Variable | Required | Default |
27
- | ---------------------- | -------- | ---------------------------------------- |
28
- | `AGENT_TASKS_TOKEN` | yes | — |
29
- | `AGENT_TASKS_BASE_URL` | no | `https://agent-tasks.opentriologue.ai` |
26
+ | Variable | Required | Default |
27
+ | -------------------------- | -------- | ---------------------------------------- |
28
+ | `AGENT_TASKS_TOKEN` | yes | — |
29
+ | `AGENT_TASKS_BASE_URL` | no | `https://agent-tasks.opentriologue.ai` |
30
+ | `AGENT_TASKS_MCP_LEGACY` | no | unset (default tool set only) |
30
31
 
31
32
  Obtain a token from the agent-tasks UI under **Settings → API Tokens**.
32
33
  The token scope determines which tools succeed at runtime; tools that require
@@ -48,7 +49,73 @@ Drop `--scope user` if you want it project-local instead. See
48
49
 
49
50
  ## Tools
50
51
 
51
- 36 tools total. All return the raw JSON response from the backend as a text block.
52
+ **24 tools registered by default.** rc-v1-C007 pruned 14 still-deprecated v1
53
+ verbs out of the default registration (`projects_list`, `projects_get`,
54
+ `tasks_list`, `tasks_instructions`, `tasks_create`, `tasks_claim`,
55
+ `tasks_release`, `tasks_transition`, `tasks_update`, `review_approve`,
56
+ `review_request_changes`, `review_claim`, `review_release`,
57
+ `pull_requests_comment`); handler code for all 14 is untouched, only their
58
+ registration is gated. Set `AGENT_TASKS_MCP_LEGACY=1` in the server
59
+ process's environment to register all 38 tools (the full pre-rc-v1-C007 set
60
+ plus every verb added since) for a client still depending on one of the
61
+ pruned names. Two of the pruned verbs, `tasks_list` and `projects_list`, are
62
+ known to have had active workflow users as of this pruning:
63
+ `docs/response-contract-v1.md`'s Motivation section measured `tasks_list` as
64
+ the third-highest MCP token consumer in the audited window, and
65
+ `projects_list` was the only way to resolve a project slug before
66
+ `task_create`'s `projectSlug` field and `project_tasks` shipped. Migrate
67
+ those callers to the v2 replacements in the table below, or set the flag
68
+ while migrating.
69
+
70
+ The 9 converted v2 write verbs (`task_create`, `task_respec`, `task_finish`,
71
+ `task_submit_pr`, `task_note`, `task_merge`, `task_abandon`,
72
+ `task_creator_abandon`, and the
73
+ `tasks_comment` alias) return a small receipt by default
74
+ (`{ ok, task: { id, status? }, ... }`, per `docs/response-contract-v1.md`)
75
+ instead of the raw backend body; pass `include: ["task"]` on any of them to
76
+ get the full, pre-contract object back for that call. `tasks_get` returns a
77
+ summary projection with its own `include` vocabulary, and `signals_poll`
78
+ caps and cursors the backend response locally even though it takes no
79
+ `include` parameter of its own (see `docs/response-contract-v1.md`'s
80
+ read-verb section). Every other default-registered tool still returns the
81
+ raw JSON response from the backend as a text block. The 14 pruned, legacy-flag
82
+ verbs are exempt from these shape rules entirely (see
83
+ `docs/response-contract-v1.md`'s "Legacy-flag exemption"): they exist for
84
+ compatibility only, and most still return the raw backend body they always
85
+ did (`tasks_create`, for one, still echoes the caller's own `description`).
86
+
87
+ ### Replacement table: pruned v1 verbs → v2 equivalent
88
+
89
+ Set `AGENT_TASKS_MCP_LEGACY=1` to keep using a verb in this table while you
90
+ migrate the caller to its replacement.
91
+
92
+ | Pruned verb (legacy-only) | v2 replacement |
93
+ | --- | --- |
94
+ | `projects_list` | no v2 verb enumerates projects: ask the operator for the project's slug or id (the recipe `errors.ts`'s own `unknown_project_slug` teaching error gives), or set `AGENT_TASKS_MCP_LEGACY=1` to keep using this verb. Once you know the project, `project_tasks` browses its tasks and `task_pickup` finds the next piece of work without browsing |
95
+ | `projects_get` | `projects_get_effective_gates` for the gate/task-creation fields this verb's "non-deprecated use" needed; `project_tasks` for browsing |
96
+ | `tasks_list` | `task_pickup` for the single prioritized item, or `project_tasks` to browse a project |
97
+ | `tasks_instructions` | `task_start` with `include: ["instructions"]`, or the on-demand `workflow_primer` verb for the general lifecycle prose |
98
+ | `tasks_create` | `task_create` (same behavior, v2 naming, receipt by default) |
99
+ | `tasks_claim` | `task_start` (atomic claim + `in_progress` + instructions) |
100
+ | `tasks_release` | `task_abandon` (explicit bail-out with an audit trail) |
101
+ | `tasks_transition` | `task_start` / `task_finish` (the system owns transitions under v2) |
102
+ | `tasks_update` | `task_submit_pr` for branch/PR metadata, or `task_finish { prUrl }` |
103
+ | `review_approve` | `task_finish { outcome: "approve" }` after `task_start` on a review task |
104
+ | `review_request_changes` | `task_finish { outcome: "request_changes" }` after `task_start` on a review task |
105
+ | `review_claim` | `task_start` on a task in `review` status (review-claims polymorphically) |
106
+ | `review_release` | `task_abandon` |
107
+ | `pull_requests_comment` | `gh pr comment` directly, or `task_note` to leave the note on the task instead |
108
+
109
+ ### Onboarding
110
+
111
+ | Tool | Wraps |
112
+ | ------------------ | --------------------------------------------- |
113
+ | `workflow_primer` | served locally, no backend call |
114
+
115
+ `workflow_primer` is the one local-only tool in this package: it returns a
116
+ fixed onboarding string (`src/primer.ts`) and never calls the backend. See
117
+ `docs/response-contract-v1.md`'s "Onboarding channels by rate of change"
118
+ table.
52
119
 
53
120
  ### v2 verbs (task_*)
54
121
 
@@ -81,33 +148,46 @@ The canonical agent surface. Prefer these for all new integrations.
81
148
  | `task_attachment_list` | `GET /api/tasks/:id/attachments` |
82
149
  | `task_attachment_get` | `GET /api/tasks/:id/attachments/:attachmentId/content` |
83
150
 
84
- ### v1 aliases (tasks_* / review_* / pull_requests_* / projects_* / signals_*)
151
+ ### v1-named aliases still registered by default
85
152
 
86
- Still functional; most are deprecated in favour of the v2 verbs above.
153
+ Naming-convention siblings of the pruned surface below, but each stays
154
+ registered by default: `projects_get_effective_gates` and `project_tasks`
155
+ were never deprecated, `tasks_get` was upgraded into the read-verb surface
156
+ (rc-v1-C006), `tasks_comment` is the receipt-converted `task_note` alias,
157
+ `signals_poll` / `signals_ack` are still the only signal-inbox surface, and
158
+ `pull_requests_create` / `pull_requests_merge` were never deprecated either.
87
159
 
88
160
  | Tool | Wraps |
89
161
  | ------------------------ | ------------------------------------------------------------- |
90
- | `projects_list` | `GET /api/projects/available` |
91
- | `projects_get` | `GET /api/projects/:slugOrId` (or `/by-slug/:slug`) |
92
162
  | `projects_get_effective_gates` | `GET /api/projects/:id/effective-gates` |
93
163
  | `project_tasks` | `GET /api/projects/:id/tasks` |
94
- | `tasks_list` | `GET /api/tasks/claimable` |
95
164
  | `tasks_get` | `GET /api/tasks/:id` |
165
+ | `tasks_comment` | `POST /api/tasks/:id/comments` |
166
+ | `signals_poll` | `GET /api/agent/signals` |
167
+ | `signals_ack` | `POST /api/agent/signals/:id/ack` |
168
+ | `pull_requests_create` | `POST /api/github/pull-requests` |
169
+ | `pull_requests_merge` | `POST /api/github/pull-requests/:prNumber/merge` |
170
+
171
+ ### v1 aliases pruned from the default registration (legacy-only)
172
+
173
+ Set `AGENT_TASKS_MCP_LEGACY=1` to register these 14. See the replacement
174
+ table above for their v2 equivalents.
175
+
176
+ | Tool | Wraps |
177
+ | ------------------------ | ------------------------------------------------------------- |
178
+ | `projects_list` | `GET /api/projects/available` |
179
+ | `projects_get` | `GET /api/projects/:slugOrId` (or `/by-slug/:slug`) |
180
+ | `tasks_list` | `GET /api/tasks/claimable` |
96
181
  | `tasks_instructions` | `GET /api/tasks/:id/instructions` |
97
182
  | `tasks_create` | `POST /api/projects/:projectId/tasks` |
98
183
  | `tasks_claim` | `POST /api/tasks/:id/claim` |
99
184
  | `tasks_release` | `POST /api/tasks/:id/release` |
100
185
  | `tasks_transition` | `POST /api/tasks/:id/transition` |
101
186
  | `tasks_update` | `PATCH /api/tasks/:id` |
102
- | `tasks_comment` | `POST /api/tasks/:id/comments` |
103
187
  | `review_approve` | `POST /api/tasks/:id/review` (`action: approve`) |
104
188
  | `review_request_changes` | `POST /api/tasks/:id/review` (`action: request_changes`) |
105
189
  | `review_claim` | `POST /api/tasks/:id/review/claim` |
106
190
  | `review_release` | `POST /api/tasks/:id/review/release` |
107
- | `signals_poll` | `GET /api/agent/signals` |
108
- | `signals_ack` | `POST /api/agent/signals/:id/ack` |
109
- | `pull_requests_create` | `POST /api/github/pull-requests` |
110
- | `pull_requests_merge` | `POST /api/github/pull-requests/:prNumber/merge` |
111
191
  | `pull_requests_comment` | `POST /api/github/pull-requests/:prNumber/comments` |
112
192
 
113
193
  ### GitHub PR tools — delegation required
@@ -138,7 +218,9 @@ the endpoint returns 403. If the project has `requireDistinctReviewer`
138
218
  enabled, the merge caller must not be the task's claimant — same rule
139
219
  the `/transition` and `/review` endpoints apply. To bypass the gate,
140
220
  admins force-transition to `done` via `tasks_transition` with `force=true`
141
- first, then call this tool (which accepts `done` as a valid entry state).
221
+ first (set `AGENT_TASKS_MCP_LEGACY=1`, `tasks_transition` is pruned from
222
+ the default registration), then call this tool (which accepts `done` as a
223
+ valid entry state).
142
224
 
143
225
  ## Transport
144
226
 
@@ -164,12 +246,15 @@ curl -X POST https://agent-tasks.opentriologue.ai/api/mcp \
164
246
  - Stateless Streamable HTTP (no session ID, one round-trip per
165
247
  request)
166
248
  - Same Bearer auth as the rest of the agent-tasks REST API
167
- - The HTTP endpoint is a **hand-maintained subset** of the 36 tools
168
- this stdio package exposes. It covers the full v1 alias surface
169
- (projects_*, tasks_*, review_*, signals_*, pull_requests_*) but
170
- does **not** yet include the v2 verbs (task_pickup / task_start /
171
- task_finish / task_respec / etc.), artifact tools (task_artifact_*),
172
- attachment tools (task_attachment_*), or project_tasks. The code comment in
249
+ - The HTTP endpoint is a **hand-maintained subset** of the 38 tools this
250
+ stdio package can expose (24 registered by default, the remaining 14
251
+ legacy-only under `AGENT_TASKS_MCP_LEGACY=1`, see "Tools" above). It
252
+ covers the full v1 alias surface (projects_*, tasks_*, review_*,
253
+ signals_*, pull_requests_*) but does **not** yet include the v2 verbs
254
+ (task_pickup / task_start /
255
+ task_finish / task_respec / etc.), the local-only `workflow_primer`
256
+ tool, artifact tools (task_artifact_*), attachment tools
257
+ (task_attachment_*), or project_tasks. The code comment in
173
258
  `backend/src/routes/mcp.ts` documents this gap explicitly.
174
259
  - GET / DELETE on `/api/mcp` return 405 with `Allow: POST`
175
260
 
package/dist/client.d.ts CHANGED
@@ -7,10 +7,86 @@ export declare class AgentTasksApiError extends Error {
7
7
  body: unknown;
8
8
  constructor(status: number, body: unknown, message: string);
9
9
  }
10
+ export declare class ProjectSlugNotFoundError extends Error {
11
+ readonly slug: string;
12
+ constructor(slug: string);
13
+ }
14
+ interface CreateTaskInput {
15
+ title: string;
16
+ description?: string;
17
+ priority?: "LOW" | "MEDIUM" | "HIGH" | "CRITICAL";
18
+ workflowId?: string;
19
+ dueAt?: string;
20
+ externalRef?: string;
21
+ labels?: string[];
22
+ dependsOn?: string[];
23
+ debugFlavor?: boolean;
24
+ templateData?: Record<string, unknown>;
25
+ deliverableRepo?: string;
26
+ }
27
+ interface ListProjectTasksParams {
28
+ status?: string | string[];
29
+ priority?: string | string[];
30
+ labels?: string[];
31
+ unclaimed?: boolean;
32
+ limit?: number;
33
+ sort?: string;
34
+ cursor?: string;
35
+ }
10
36
  export declare class AgentTasksClient {
11
37
  private readonly config;
38
+ private readonly projectSlugCache;
12
39
  constructor(config: ClientConfig);
13
40
  private request;
41
+ /** Cache-first resolution. Also reports whether `id` was cache-served (vs
42
+ * a fresh network lookup THIS call), so withResolvedProjectSlug can tell
43
+ * a stale-cache-artifact failure apart from a genuine downstream error --
44
+ * see that function's own doc comment. Throws ProjectSlugNotFoundError on
45
+ * a fresh (non-cached) 404 -- see that class's own doc comment. */
46
+ private resolveProjectSlug;
47
+ /** Always hits the network (bypasses the cache), then (re)writes the
48
+ * cache entry on success. Used both for a cache miss/expiry and for the
49
+ * forced fresh retry in withResolvedProjectSlug below. */
50
+ private fetchAndCacheProjectSlug;
51
+ /**
52
+ * Resolves `slug` to a project id (cache-first) and calls `perform(id)`.
53
+ *
54
+ * `perform` failing downstream with a 404 OR a 403 is only worth a retry
55
+ * when `id` was CACHE-SERVED (rc-v1-C006 round-2 review, HIGH): the
56
+ * resolved id no longer working downstream can mean the project behind
57
+ * this slug was renamed/reassigned since the cache entry was written
58
+ * (404 -- the id no longer exists), or that the caller's access to that
59
+ * now-different project was revoked (403 -- both consumer routes,
60
+ * POST /projects/:id/tasks and GET /projects/:id/tasks, reject an
61
+ * inaccessible id via hasProjectAccess with 403 forbidden, NOT 404; see
62
+ * backend/src/routes/tasks.ts). A freshly-resolved id (cacheServed:
63
+ * false) failing the same way is never a stale-cache artifact -- nothing
64
+ * to invalidate -- so it propagates immediately, with no wasted retry
65
+ * round trip.
66
+ *
67
+ * When a cache-served id does fail this way, the cache entry is
68
+ * invalidated and the slug is re-resolved FRESH before deciding whether
69
+ * to retry `perform`:
70
+ * - the fresh id is IDENTICAL to the one that just failed: this was
71
+ * never a stale-cache issue, it is a genuine downstream error (most
72
+ * often a real permission denial) -- the ORIGINAL error propagates
73
+ * unchanged, `perform` is not called again, so a real 403 is never
74
+ * masked as a retry-fixed cache problem.
75
+ * - the fresh id DIFFERS: the cache genuinely was stale -- `perform` is
76
+ * retried exactly once against the fresh id. A second failure
77
+ * (including a second 404/403) propagates unchanged: this is a
78
+ * single retry, not a loop. `perform` is therefore called at most
79
+ * twice in total for one withResolvedProjectSlug call.
80
+ * - the fresh lookup itself 404s (the slug no longer resolves to ANY
81
+ * project): fetchAndCacheProjectSlug's own ProjectSlugNotFoundError
82
+ * propagates unchanged, mapped by tools.ts's callers to the
83
+ * unknown_project_slug teaching error, never a raw error leak.
84
+ * - the fresh lookup fails with anything ELSE (a 500, a network
85
+ * error): the ORIGINAL downstream error propagates, not the
86
+ * lookup's own failure -- the retry machinery must never replace a
87
+ * real denial with one of its own artifacts.
88
+ */
89
+ private withResolvedProjectSlug;
14
90
  listProjects(): Promise<unknown>;
15
91
  getProject(slugOrId: string): Promise<unknown>;
16
92
  getProjectEffectiveGates(projectId: string): Promise<unknown>;
@@ -22,29 +98,16 @@ export declare class AgentTasksClient {
22
98
  labels?: string[];
23
99
  claimedByAgentId?: string;
24
100
  verbose?: boolean;
101
+ sort?: string;
102
+ cursor?: string;
25
103
  }): Promise<unknown>;
26
- listProjectTasks(project: string, params?: {
27
- status?: string | string[];
28
- priority?: string | string[];
29
- labels?: string[];
30
- unclaimed?: boolean;
31
- limit?: number;
32
- }): Promise<unknown>;
104
+ listProjectTasks(project: string, params?: ListProjectTasksParams): Promise<unknown>;
105
+ private fetchProjectTasksPage;
33
106
  getTask(taskId: string): Promise<unknown>;
34
107
  getTaskInstructions(taskId: string): Promise<unknown>;
35
- createTask(projectId: string, input: {
36
- title: string;
37
- description?: string;
38
- priority?: "LOW" | "MEDIUM" | "HIGH" | "CRITICAL";
39
- workflowId?: string;
40
- dueAt?: string;
41
- externalRef?: string;
42
- labels?: string[];
43
- dependsOn?: string[];
44
- debugFlavor?: boolean;
45
- templateData?: Record<string, unknown>;
46
- deliverableRepo?: string;
47
- }): Promise<unknown>;
108
+ createTask(projectId: string, input: CreateTaskInput): Promise<unknown>;
109
+ createTaskByProjectSlug(slug: string, input: CreateTaskInput): Promise<unknown>;
110
+ createTaskByProject(project: string, input: CreateTaskInput): Promise<unknown>;
48
111
  claimTask(taskId: string): Promise<unknown>;
49
112
  releaseTask(taskId: string): Promise<unknown>;
50
113
  transitionTask(taskId: string, input: {
@@ -80,6 +143,9 @@ export declare class AgentTasksClient {
80
143
  mergeMethod?: "squash" | "merge" | "rebase";
81
144
  }): Promise<unknown>;
82
145
  abandonTask(taskId: string): Promise<unknown>;
146
+ creatorAbandonTask(taskId: string, input?: {
147
+ reason?: string;
148
+ }): Promise<unknown>;
83
149
  mergeTask(taskId: string, mergeMethod?: "squash" | "merge" | "rebase"): Promise<unknown>;
84
150
  submitPr(taskId: string, input: {
85
151
  branchName: string;
@@ -90,7 +156,7 @@ export declare class AgentTasksClient {
90
156
  description?: string;
91
157
  templateData?: Record<string, unknown>;
92
158
  }): Promise<unknown>;
93
- pollSignals(): Promise<unknown>;
159
+ pollSignals(limit?: number): Promise<unknown>;
94
160
  listTaskArtifacts(taskId: string, type?: string): Promise<unknown>;
95
161
  getTaskArtifact(taskId: string, artifactId: string): Promise<unknown>;
96
162
  createTaskArtifact(taskId: string, input: {
@@ -135,3 +201,4 @@ export declare class AgentTasksClient {
135
201
  idempotencyKey?: string;
136
202
  }): Promise<unknown>;
137
203
  }
204
+ export {};
package/dist/client.js CHANGED
@@ -8,8 +8,40 @@ export class AgentTasksApiError extends Error {
8
8
  this.name = "AgentTasksApiError";
9
9
  }
10
10
  }
11
+ // rc-v1-C006: raised by the internal project-slug resolver (see
12
+ // resolveProjectSlug/withResolvedProjectSlug below) specifically when a
13
+ // FRESH (not cache-served) GET /projects/by-slug/:slug lookup 404s — i.e.
14
+ // the slug genuinely does not resolve to any project, as opposed to a
15
+ // cache-served id whose downstream use fails with 404 or 403 (that case is
16
+ // handled internally by withResolvedProjectSlug's own invalidate-and-retry,
17
+ // and never reaches a caller as this error). Kept distinct from the generic
18
+ // AgentTasksApiError so callers (tools.ts's task_create / project_tasks
19
+ // handlers) can map it to the errors.ts unknownProjectSlugError teaching
20
+ // error (naming projects_list as the recipe) instead of the generic
21
+ // http_404 degrade a raw 404 would otherwise produce.
22
+ export class ProjectSlugNotFoundError extends Error {
23
+ slug;
24
+ constructor(slug) {
25
+ super(`no project found for slug "${slug}"`);
26
+ this.slug = slug;
27
+ this.name = "ProjectSlugNotFoundError";
28
+ }
29
+ }
30
+ // TTL for the internal slug -> project id cache (rc-v1-C006). ~15 minutes,
31
+ // per the task spec: long enough that a session doing several project_tasks
32
+ // / task_create calls against the same project only pays the by-slug
33
+ // round-trip once, short enough that a slug reassignment (rare) is picked
34
+ // up again within one working session even without hitting the
35
+ // invalidate-and-retry path (withResolvedProjectSlug, triggered by a
36
+ // cache-served id's downstream 404 or 403).
37
+ const PROJECT_SLUG_CACHE_TTL_MS = 15 * 60 * 1000;
11
38
  export class AgentTasksClient {
12
39
  config;
40
+ // slug -> resolved project id, TTL-bounded. Instance-scoped (not shared
41
+ // across AgentTasksClient instances, not persisted): the mcp-server
42
+ // process holds exactly one client per running session, so this is
43
+ // effectively a per-session cache.
44
+ projectSlugCache = new Map();
13
45
  constructor(config) {
14
46
  this.config = config;
15
47
  }
@@ -45,6 +77,108 @@ export class AgentTasksClient {
45
77
  }
46
78
  return parsed;
47
79
  }
80
+ // ── Project-slug resolution (rc-v1-C006) ──────────────────────────────
81
+ //
82
+ // Shared by listProjectTasks's existing slug-or-id `project` param,
83
+ // createTaskByProjectSlug's projectSlug field, and createTaskByProject's
84
+ // own unified `project` field, so all three callers pay the by-slug
85
+ // round trip at most once per TTL window instead of on every call. See
86
+ // docs/response-contract-v1.md; the cache and retry behavior itself is a
87
+ // task-spec requirement of rc-v1-C006, not yet written into that doc's
88
+ // own prose.
89
+ /** Cache-first resolution. Also reports whether `id` was cache-served (vs
90
+ * a fresh network lookup THIS call), so withResolvedProjectSlug can tell
91
+ * a stale-cache-artifact failure apart from a genuine downstream error --
92
+ * see that function's own doc comment. Throws ProjectSlugNotFoundError on
93
+ * a fresh (non-cached) 404 -- see that class's own doc comment. */
94
+ async resolveProjectSlug(slug) {
95
+ const cached = this.projectSlugCache.get(slug);
96
+ if (cached && cached.expiresAt > Date.now()) {
97
+ return { id: cached.id, cacheServed: true };
98
+ }
99
+ const id = await this.fetchAndCacheProjectSlug(slug);
100
+ return { id, cacheServed: false };
101
+ }
102
+ /** Always hits the network (bypasses the cache), then (re)writes the
103
+ * cache entry on success. Used both for a cache miss/expiry and for the
104
+ * forced fresh retry in withResolvedProjectSlug below. */
105
+ async fetchAndCacheProjectSlug(slug) {
106
+ let resolved;
107
+ try {
108
+ resolved = await this.request("GET", `/api/projects/by-slug/${encodeURIComponent(slug)}`);
109
+ }
110
+ catch (err) {
111
+ if (err instanceof AgentTasksApiError && err.status === 404) {
112
+ throw new ProjectSlugNotFoundError(slug);
113
+ }
114
+ throw err;
115
+ }
116
+ const id = resolved.project.id;
117
+ this.projectSlugCache.set(slug, { id, expiresAt: Date.now() + PROJECT_SLUG_CACHE_TTL_MS });
118
+ return id;
119
+ }
120
+ /**
121
+ * Resolves `slug` to a project id (cache-first) and calls `perform(id)`.
122
+ *
123
+ * `perform` failing downstream with a 404 OR a 403 is only worth a retry
124
+ * when `id` was CACHE-SERVED (rc-v1-C006 round-2 review, HIGH): the
125
+ * resolved id no longer working downstream can mean the project behind
126
+ * this slug was renamed/reassigned since the cache entry was written
127
+ * (404 -- the id no longer exists), or that the caller's access to that
128
+ * now-different project was revoked (403 -- both consumer routes,
129
+ * POST /projects/:id/tasks and GET /projects/:id/tasks, reject an
130
+ * inaccessible id via hasProjectAccess with 403 forbidden, NOT 404; see
131
+ * backend/src/routes/tasks.ts). A freshly-resolved id (cacheServed:
132
+ * false) failing the same way is never a stale-cache artifact -- nothing
133
+ * to invalidate -- so it propagates immediately, with no wasted retry
134
+ * round trip.
135
+ *
136
+ * When a cache-served id does fail this way, the cache entry is
137
+ * invalidated and the slug is re-resolved FRESH before deciding whether
138
+ * to retry `perform`:
139
+ * - the fresh id is IDENTICAL to the one that just failed: this was
140
+ * never a stale-cache issue, it is a genuine downstream error (most
141
+ * often a real permission denial) -- the ORIGINAL error propagates
142
+ * unchanged, `perform` is not called again, so a real 403 is never
143
+ * masked as a retry-fixed cache problem.
144
+ * - the fresh id DIFFERS: the cache genuinely was stale -- `perform` is
145
+ * retried exactly once against the fresh id. A second failure
146
+ * (including a second 404/403) propagates unchanged: this is a
147
+ * single retry, not a loop. `perform` is therefore called at most
148
+ * twice in total for one withResolvedProjectSlug call.
149
+ * - the fresh lookup itself 404s (the slug no longer resolves to ANY
150
+ * project): fetchAndCacheProjectSlug's own ProjectSlugNotFoundError
151
+ * propagates unchanged, mapped by tools.ts's callers to the
152
+ * unknown_project_slug teaching error, never a raw error leak.
153
+ * - the fresh lookup fails with anything ELSE (a 500, a network
154
+ * error): the ORIGINAL downstream error propagates, not the
155
+ * lookup's own failure -- the retry machinery must never replace a
156
+ * real denial with one of its own artifacts.
157
+ */
158
+ async withResolvedProjectSlug(slug, perform) {
159
+ const { id, cacheServed } = await this.resolveProjectSlug(slug);
160
+ try {
161
+ return await perform(id);
162
+ }
163
+ catch (err) {
164
+ const isRetryTrigger = err instanceof AgentTasksApiError && (err.status === 404 || err.status === 403);
165
+ if (!isRetryTrigger || !cacheServed)
166
+ throw err;
167
+ this.projectSlugCache.delete(slug);
168
+ let freshId;
169
+ try {
170
+ freshId = await this.fetchAndCacheProjectSlug(slug);
171
+ }
172
+ catch (lookupErr) {
173
+ if (lookupErr instanceof ProjectSlugNotFoundError)
174
+ throw lookupErr;
175
+ throw err;
176
+ }
177
+ if (freshId === id)
178
+ throw err;
179
+ return await perform(freshId);
180
+ }
181
+ }
48
182
  listProjects() {
49
183
  return this.request("GET", "/api/projects/available");
50
184
  }
@@ -79,24 +213,29 @@ export class AgentTasksClient {
79
213
  sp.set("claimedByAgentId", params.claimedByAgentId);
80
214
  if (params?.verbose)
81
215
  sp.set("verbose", "true");
216
+ if (params?.sort)
217
+ sp.set("sort", params.sort);
218
+ if (params?.cursor)
219
+ sp.set("cursor", params.cursor);
82
220
  const qs = sp.toString();
83
221
  return this.request("GET", qs.length > 0 ? `/api/tasks/claimable?${qs}` : `/api/tasks/claimable`);
84
222
  }
85
223
  // Browse tasks scoped to a single project. Accepts slug or UUID for
86
- // `project`; if a slug is passed we resolve it to a UUID first via the
87
- // existing by-slug lookup so callers don't have to chain projects_get
88
- // themselves. Mirrors the filter surface of the CLI's `tasks list
89
- // --project` flow and forwards to GET /api/projects/:id/tasks.
224
+ // `project`; if a slug is passed it is resolved to a UUID first via
225
+ // withResolvedProjectSlug's TTL-cached lookup (rc-v1-C006) so repeated
226
+ // calls with the same slug on this client instance pay the by-slug
227
+ // round trip once per TTL window, not on every call, without callers
228
+ // having to chain projects_get themselves. Mirrors the filter surface of
229
+ // the CLI's `tasks list --project` flow and forwards to GET
230
+ // /api/projects/:id/tasks. Throws ProjectSlugNotFoundError (not a bare
231
+ // AgentTasksApiError) when `project` is a slug that does not resolve on
232
+ // a fresh lookup -- see withResolvedProjectSlug.
90
233
  async listProjectTasks(project, params) {
91
234
  const isUuid = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i.test(project);
92
- let projectId;
93
- if (isUuid) {
94
- projectId = project;
95
- }
96
- else {
97
- const resolved = (await this.request("GET", `/api/projects/by-slug/${encodeURIComponent(project)}`)).project;
98
- projectId = resolved.id;
99
- }
235
+ const fetchPage = (projectId) => this.fetchProjectTasksPage(projectId, params);
236
+ return isUuid ? fetchPage(project) : this.withResolvedProjectSlug(project, fetchPage);
237
+ }
238
+ fetchProjectTasksPage(projectId, params) {
100
239
  const sp = new URLSearchParams();
101
240
  if (params?.status !== undefined) {
102
241
  sp.set("status", Array.isArray(params.status) ? params.status.join(",") : params.status);
@@ -113,6 +252,10 @@ export class AgentTasksClient {
113
252
  sp.set("unclaimed", "true");
114
253
  if (params?.limit !== undefined)
115
254
  sp.set("limit", String(params.limit));
255
+ if (params?.sort)
256
+ sp.set("sort", params.sort);
257
+ if (params?.cursor)
258
+ sp.set("cursor", params.cursor);
116
259
  const qs = sp.toString();
117
260
  return this.request("GET", qs.length > 0
118
261
  ? `/api/projects/${projectId}/tasks?${qs}`
@@ -127,6 +270,26 @@ export class AgentTasksClient {
127
270
  createTask(projectId, input) {
128
271
  return this.request("POST", `/api/projects/${projectId}/tasks`, input);
129
272
  }
273
+ // rc-v1-C006: projectSlug alternative to task_create's projectId,
274
+ // resolved through the same TTL-cached slug resolver listProjectTasks
275
+ // uses. Throws ProjectSlugNotFoundError on a fresh (non-cached) 404 --
276
+ // see withResolvedProjectSlug.
277
+ createTaskByProjectSlug(slug, input) {
278
+ return this.withResolvedProjectSlug(slug, (projectId) => this.createTask(projectId, input));
279
+ }
280
+ // task_create's unified `project` field (mirrors project_tasks's own
281
+ // `project`, rc-v1-C006's listProjectTasks polymorphic param): accepts a
282
+ // slug OR a UUID in one field instead of the separate projectId/
283
+ // projectSlug pair. Same UUID-passthrough check as listProjectTasks
284
+ // (isUuid), same TTL-cached resolver as createTaskByProjectSlug for the
285
+ // slug branch -- not a second resolver. Throws ProjectSlugNotFoundError
286
+ // on a fresh (non-cached) 404 -- see withResolvedProjectSlug.
287
+ createTaskByProject(project, input) {
288
+ const isUuid = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i.test(project);
289
+ return isUuid
290
+ ? this.createTask(project, input)
291
+ : this.createTaskByProjectSlug(project, input);
292
+ }
130
293
  claimTask(taskId) {
131
294
  return this.request("POST", `/api/tasks/${taskId}/claim`);
132
295
  }
@@ -169,6 +332,12 @@ export class AgentTasksClient {
169
332
  abandonTask(taskId) {
170
333
  return this.request("POST", `/api/tasks/${taskId}/abandon`);
171
334
  }
335
+ // Task 7a1360da: distinct from abandonTask above, which releases a CLAIM.
336
+ // creatorAbandonTask retires an OPEN, UNCLAIMED task the caller created
337
+ // into status="abandoned", with no claim involved at all.
338
+ creatorAbandonTask(taskId, input) {
339
+ return this.request("POST", `/api/tasks/${taskId}/creator-abandon`, input);
340
+ }
172
341
  mergeTask(taskId, mergeMethod) {
173
342
  return this.request("POST", `/api/tasks/${taskId}/merge`, {
174
343
  mergeMethod: mergeMethod ?? "squash",
@@ -180,8 +349,14 @@ export class AgentTasksClient {
180
349
  respecTask(taskId, input) {
181
350
  return this.request("POST", `/api/tasks/${taskId}/respec`, input);
182
351
  }
183
- pollSignals() {
184
- return this.request("GET", "/api/agent/signals");
352
+ // `limit` (rc-v1-C006): forwarded to the backend's own `?limit=` query
353
+ // param (backend/src/routes/signals.ts, hard-capped there at 200). The
354
+ // mcp-server-side cap+cursor (read.ts's paginateSignals) requests the
355
+ // backend's own max here so it can slice+cursor the full backlog
356
+ // client-side without a backend cursor param.
357
+ pollSignals(limit) {
358
+ const qs = limit !== undefined ? `?limit=${limit}` : "";
359
+ return this.request("GET", `/api/agent/signals${qs}`);
185
360
  }
186
361
  // ── Artifacts ────────────────────────────────────────────────────────────
187
362
  //
@@ -1 +1 @@
1
- {"version":3,"file":"client.js","sourceRoot":"","sources":["../src/client.ts"],"names":[],"mappings":"AAKA,MAAM,OAAO,kBAAmB,SAAQ,KAAK;IAElC;IACA;IAFT,YACS,MAAc,EACd,IAAa,EACpB,OAAe;QAEf,KAAK,CAAC,OAAO,CAAC,CAAC;QAJR,WAAM,GAAN,MAAM,CAAQ;QACd,SAAI,GAAJ,IAAI,CAAS;QAIpB,IAAI,CAAC,IAAI,GAAG,oBAAoB,CAAC;IACnC,CAAC;CACF;AAED,MAAM,OAAO,gBAAgB;IACE;IAA7B,YAA6B,MAAoB;QAApB,WAAM,GAAN,MAAM,CAAc;IAAG,CAAC;IAE7C,KAAK,CAAC,OAAO,CACnB,MAAc,EACd,IAAY,EACZ,IAAc;QAEd,MAAM,GAAG,GAAG,GAAG,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC,GAAG,IAAI,EAAE,CAAC;QAC/D,MAAM,OAAO,GAA2B;YACtC,aAAa,EAAE,UAAU,IAAI,CAAC,MAAM,CAAC,KAAK,EAAE;YAC5C,MAAM,EAAE,kBAAkB;SAC3B,CAAC;QACF,IAAI,IAAI,KAAK,SAAS,EAAE,CAAC;YACvB,OAAO,CAAC,cAAc,CAAC,GAAG,kBAAkB,CAAC;QAC/C,CAAC;QAED,MAAM,GAAG,GAAG,MAAM,KAAK,CAAC,GAAG,EAAE;YAC3B,MAAM;YACN,OAAO;YACP,IAAI,EAAE,IAAI,KAAK,SAAS,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC;SAC5D,CAAC,CAAC;QAEH,MAAM,IAAI,GAAG,MAAM,GAAG,CAAC,IAAI,EAAE,CAAC;QAC9B,IAAI,MAAM,GAAY,SAAS,CAAC;QAChC,IAAI,IAAI,CAAC,MAAM,GAAG,CAAC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