constructor-research-mcp 0.3.2 → 0.4.0-beta.2
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/INSTALL.md +24 -25
- package/README.md +44 -48
- package/dist/api.d.ts +11 -30
- package/dist/api.js +53 -130
- package/dist/config.d.ts +11 -22
- package/dist/config.js +15 -47
- package/dist/deployment.d.ts +2 -0
- package/dist/deployment.js +26 -13
- package/dist/desk.d.ts +23 -0
- package/dist/desk.js +52 -0
- package/dist/files.d.ts +6 -0
- package/dist/files.js +46 -1
- package/dist/key.d.ts +9 -0
- package/dist/key.js +35 -0
- package/dist/location.d.ts +3 -1
- package/dist/location.js +13 -3
- package/dist/logs.js +2 -2
- package/dist/runtime.js +4 -4
- package/dist/schemas.d.ts +0 -5
- package/dist/schemas.js +0 -18
- package/dist/server.js +64 -106
- package/dist/set-key.d.ts +2 -0
- package/dist/set-key.js +107 -0
- package/dist/store.d.ts +1 -1
- package/dist/store.js +1 -1
- package/dist/wait.js +3 -6
- package/examples/claude-hooks.json +1 -1
- package/examples/claude.mcp.json +1 -1
- package/examples/codex-hooks.json +1 -1
- package/examples/codex.toml +1 -1
- package/examples/opencode-plugin.js +1 -1
- package/examples/opencode-v2.json +1 -1
- package/examples/opencode.json +1 -1
- package/package.json +7 -6
package/dist/store.js
CHANGED
|
@@ -13,7 +13,7 @@ export class StateStore {
|
|
|
13
13
|
* harnesses' calls "busy" about half the time while anything was deploying.
|
|
14
14
|
*/
|
|
15
15
|
lockWaitMs = 15000;
|
|
16
|
-
/** The Constructor API saved operations belong to; follows a
|
|
16
|
+
/** The Constructor API saved operations belong to; follows a key saved for another host. */
|
|
17
17
|
get endpoint() {
|
|
18
18
|
return this.config.baseUrl + this.config.apiPath;
|
|
19
19
|
}
|
package/dist/wait.js
CHANGED
|
@@ -10,7 +10,7 @@ import { readFile, unlink, writeFile } from "node:fs/promises";
|
|
|
10
10
|
import { join } from "node:path";
|
|
11
11
|
import { realpathSync } from "node:fs";
|
|
12
12
|
import { fileURLToPath } from "node:url";
|
|
13
|
-
import { configFromEnv
|
|
13
|
+
import { configFromEnv } from "./config.js";
|
|
14
14
|
import { PlatformApi } from "./api.js";
|
|
15
15
|
import { StateStore } from "./store.js";
|
|
16
16
|
import { DeploymentEngine, terminal } from "./deployment.js";
|
|
@@ -132,7 +132,7 @@ async function claim(dir, id) {
|
|
|
132
132
|
const USAGE = `Usage: constructor-research-wait [deployment_id ...] [--max-minutes N] [--hook claude-code|codex|opencode]
|
|
133
133
|
|
|
134
134
|
Waits until the deployments finish (all in-progress ones when no ID is given) and prints one line each.
|
|
135
|
-
Exit codes: 0 finished, 2 needs the user (failed,
|
|
135
|
+
Exit codes: 0 finished, 2 needs the user (failed, key, upload, confirmation), 3 still running at the
|
|
136
136
|
time limit, 4 nothing to wait for, 1 usage error.
|
|
137
137
|
|
|
138
138
|
--hook claude-code PostToolUse hook with asyncRewake: waits for the deployment in the tool result and
|
|
@@ -165,11 +165,8 @@ async function main(argv) {
|
|
|
165
165
|
return EXIT.error;
|
|
166
166
|
}
|
|
167
167
|
const config = configFromEnv();
|
|
168
|
-
// A hook runs for one harness: use that harness's session.
|
|
169
|
-
if (hook && !config.cookieFileFixed)
|
|
170
|
-
config.cookieFile = sessionFile(hook);
|
|
171
168
|
const api = new PlatformApi(config);
|
|
172
|
-
await api.
|
|
169
|
+
await api.refresh();
|
|
173
170
|
const store = new StateStore(config);
|
|
174
171
|
const engine = new DeploymentEngine(api, store);
|
|
175
172
|
engine.files = new FileManager(api, engine);
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
"hooks": [
|
|
7
7
|
{
|
|
8
8
|
"type": "command",
|
|
9
|
-
"command": "npx -y -p constructor-research-mcp constructor-research-wait --hook claude-code",
|
|
9
|
+
"command": "npx -y -p constructor-research-mcp@beta constructor-research-wait --hook claude-code",
|
|
10
10
|
"asyncRewake": true
|
|
11
11
|
}
|
|
12
12
|
]
|
package/examples/claude.mcp.json
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"hooks": [
|
|
6
6
|
{
|
|
7
7
|
"type": "command",
|
|
8
|
-
"command": "npx -y -p constructor-research-mcp constructor-research-wait --hook codex",
|
|
8
|
+
"command": "npx -y -p constructor-research-mcp@beta constructor-research-wait --hook codex",
|
|
9
9
|
"timeout": 600,
|
|
10
10
|
"statusMessage": "Waiting for Constructor deployments"
|
|
11
11
|
}
|
package/examples/codex.toml
CHANGED
package/examples/opencode.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "constructor-research-mcp",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.0-beta.2",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Local deployment MCP for Constructor Research",
|
|
6
6
|
"license": "MIT",
|
|
@@ -24,8 +24,7 @@
|
|
|
24
24
|
"bin": {
|
|
25
25
|
"constructor-research-mcp": "dist/server.js",
|
|
26
26
|
"constructor-research-wait": "dist/wait.js",
|
|
27
|
-
"constructor-research-
|
|
28
|
-
"constructor-research-set-token": "dist/set-token.js"
|
|
27
|
+
"constructor-research-set-key": "dist/set-key.js"
|
|
29
28
|
},
|
|
30
29
|
"files": [
|
|
31
30
|
"dist",
|
|
@@ -44,10 +43,9 @@
|
|
|
44
43
|
"pretest": "npm run build",
|
|
45
44
|
"format": "prettier --write src test examples README.md INSTALL.md",
|
|
46
45
|
"format:check": "prettier --check src test examples README.md INSTALL.md",
|
|
47
|
-
"set-token": "node dist/set-token.js",
|
|
48
46
|
"wait": "node dist/wait.js",
|
|
49
|
-
"
|
|
50
|
-
"
|
|
47
|
+
"prepublishOnly": "npm run check && npm run format:check && npm test",
|
|
48
|
+
"set-key": "node dist/set-key.js"
|
|
51
49
|
},
|
|
52
50
|
"dependencies": {
|
|
53
51
|
"@modelcontextprotocol/sdk": "1.32.2",
|
|
@@ -58,5 +56,8 @@
|
|
|
58
56
|
"prettier": "3.9.10",
|
|
59
57
|
"tsx": "4.23.15",
|
|
60
58
|
"typescript": "7.0.2"
|
|
59
|
+
},
|
|
60
|
+
"publishConfig": {
|
|
61
|
+
"tag": "beta"
|
|
61
62
|
}
|
|
62
63
|
}
|