@topline-build/harness-mcp 0.9.4 → 0.9.5
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/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
All notable customer-visible Build MCP changes are recorded here. A source change is not a published package or customer release.
|
|
4
4
|
|
|
5
|
+
## 0.9.5 - 2026-11-01
|
|
6
|
+
|
|
7
|
+
- A Topline refusal wrapped as `platform_mcp_tool_error` keeps its code when the code is camelCase in part (for example `workspace_table_displayName_too_short`), from the message or from a JSON body. It was reported as a bare `platform_mcp_tool_error` before.
|
|
8
|
+
- A Topline refusal whose code has no recovery step of its own now says the same input fails the same way, as a 4xx already did, instead of offering a plain retry.
|
|
9
|
+
|
|
5
10
|
## 0.9.4 - 2026-11-01
|
|
6
11
|
|
|
7
12
|
- `platform_init_artifact_app` takes an optional `starter`, one of the Build cookbook examples that ship a manifest (for example `internal-action-tool`, `private-api-first-app` or `live-operations-dashboard`). It scaffolds that recipe's page and private routes in dependency-free Node, each answering with a placeholder, and returns `recipe` with the example's docs id, its path in the Topline plugin and the steps still to do. Datasets, source bindings, secret bindings and Bedrock env are not declared; you add them from your own tables, sources and approved secrets. A starter works with the single shape only (`artifact_app_scaffold_starter_shape_conflict`); an unknown name returns `artifact_app_scaffold_starter_invalid` with the list.
|
package/dist/index.d.ts
CHANGED
|
@@ -42,7 +42,7 @@ type ToolProgressReporter = (progress: number, message: string) => void | Promis
|
|
|
42
42
|
export type McpSurface = "build" | "topline" | "harness";
|
|
43
43
|
export declare const DEFAULT_MCP_PROTOCOL_VERSION = "2025-11-25";
|
|
44
44
|
export declare const BUILD_MCP_SERVER_NAME = "topline-build-stdio";
|
|
45
|
-
export declare const HARNESS_MCP_VERSION = "0.9.
|
|
45
|
+
export declare const HARNESS_MCP_VERSION = "0.9.5";
|
|
46
46
|
export declare const DEFAULT_OAUTH_SCOPES: readonly string[];
|
|
47
47
|
/** The Topline server's scopes: Build and Workspace. Consent shows what the seat allows. */
|
|
48
48
|
export declare const TOPLINE_OAUTH_SCOPES: readonly string[];
|
package/dist/index.js
CHANGED
|
@@ -19,7 +19,7 @@ const MCP_SURFACES = ["build", "topline", "harness"];
|
|
|
19
19
|
export const DEFAULT_MCP_PROTOCOL_VERSION = "2025-11-25";
|
|
20
20
|
const DEFAULT_TIMEOUT_MS = 120_000;
|
|
21
21
|
export const BUILD_MCP_SERVER_NAME = "topline-build-stdio";
|
|
22
|
-
export const HARNESS_MCP_VERSION = "0.9.
|
|
22
|
+
export const HARNESS_MCP_VERSION = "0.9.5";
|
|
23
23
|
export const DEFAULT_OAUTH_SCOPES = Object.freeze(["harness:artifact:read", "harness:artifact:write", "harness:artifact:deploy", "harness:artifact:delete"]);
|
|
24
24
|
/** The Topline server's scopes: Build and Workspace. Consent shows what the seat allows. */
|
|
25
25
|
export const TOPLINE_OAUTH_SCOPES = Object.freeze([
|
|
@@ -2376,7 +2376,8 @@ export const BUILD_MCP_RECOVERY_ERRORS = Object.freeze(Object.fromEntries(Object
|
|
|
2376
2376
|
export function structuredToolError(message) {
|
|
2377
2377
|
const code = recoveryErrorCode(message);
|
|
2378
2378
|
// A 4xx means the same request will be refused again; only 5xx, timeouts and rate limits are worth retrying unchanged.
|
|
2379
|
-
const
|
|
2379
|
+
const retryable = /^platform_harness_http_error:5|timeout|rate_limited|unavailable|internal_error/.test(message);
|
|
2380
|
+
const selected = BUILD_MCP_RECOVERY_ERRORS[code] ?? { retryable, recoveryAction: !retryable && /^platform_harness_http_error:4|^platform_mcp_tool_error:/.test(message)
|
|
2380
2381
|
? "Topline refused this request as sent. Read the code, correct the input or state it names, then call the tool again; the same input fails the same way."
|
|
2381
2382
|
: "Inspect the code and message, correct the input if needed, then retry the same tool." };
|
|
2382
2383
|
const structuredContent = { ok: false, error: { code, message, ...selected } };
|
|
@@ -2393,7 +2394,7 @@ function hostedToolErrorCode(inner) {
|
|
|
2393
2394
|
if (isRecord(parsed)) {
|
|
2394
2395
|
const error = parsed.error;
|
|
2395
2396
|
const code = isRecord(error) ? error.code : typeof error === "string" ? error : parsed.code;
|
|
2396
|
-
if (typeof code === "string" && /^[a-z][
|
|
2397
|
+
if (typeof code === "string" && /^[a-z][A-Za-z0-9_]{2,}$/.test(code))
|
|
2397
2398
|
return code;
|
|
2398
2399
|
}
|
|
2399
2400
|
}
|
|
@@ -2402,7 +2403,8 @@ function hostedToolErrorCode(inner) {
|
|
|
2402
2403
|
}
|
|
2403
2404
|
// Only a code-shaped token (it has an underscore): plain English such as
|
|
2404
2405
|
// "missing scope ..." or "not found" is a message, not a code.
|
|
2405
|
-
|
|
2406
|
+
// Documentation codes can be camelCase in part (`workspace_table_displayName_too_short`).
|
|
2407
|
+
return inner.match(/^([a-z][A-Za-z0-9]*_[A-Za-z0-9_]+)(?::|$|\s)/)?.[1] ?? null;
|
|
2406
2408
|
}
|
|
2407
2409
|
function recoveryErrorCode(message) {
|
|
2408
2410
|
if (/^platform_harness_http_error:401(?::|$)/.test(message))
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"schemaVersion": 1,
|
|
3
3
|
"package": {
|
|
4
4
|
"name": "@topline-build/harness-mcp",
|
|
5
|
-
"version": "0.9.
|
|
5
|
+
"version": "0.9.5",
|
|
6
6
|
"bin": {
|
|
7
7
|
"topline-mcp": "dist/cli.js"
|
|
8
8
|
}
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
"defaultVersion": "2025-11-25",
|
|
13
13
|
"server": {
|
|
14
14
|
"name": "topline-build-stdio",
|
|
15
|
-
"version": "0.9.
|
|
15
|
+
"version": "0.9.5"
|
|
16
16
|
}
|
|
17
17
|
},
|
|
18
18
|
"generatedFrom": {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
> Generated from `src/index.ts#BUILD_MCP_TOOLS`. Do not edit this file by hand.
|
|
4
4
|
|
|
5
|
-
Package: `@topline-build/harness-mcp@0.9.
|
|
5
|
+
Package: `@topline-build/harness-mcp@0.9.5`
|
|
6
6
|
Transport: `stdio`
|
|
7
7
|
Default protocol: `2025-11-25`
|
|
8
8
|
Canonical guide: https://topline.build/docs/build-mcp-guide
|