@battlegrid/mcp-server 31.2.70 → 31.2.72
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 +88 -0
- package/SKILL.md +9 -5
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -24,6 +24,94 @@ Seeing package `31.x` alongside handshake `battlegrid@33.x` — the package **be
|
|
|
24
24
|
|
|
25
25
|
**What this changes for you:** nothing about how you call anything. Upgrading the package no longer waits on a server deploy, and a server deploy no longer strands you on a package that names the wrong contract — reconnect and the announcement follows. **Contract breaking-change notes are no longer keyed to package versions**, since a contract move is no longer a release here; the v11-and-earlier notes below are kept as history, and the live vocabulary is always discovery.
|
|
26
26
|
|
|
27
|
+
## Contract history — v90 (Arena and radar deployments join the draft lifecycle)
|
|
28
|
+
|
|
29
|
+
**Breaking at v90: input is refused and reshaped, output is reshaped, five error codes are removed.** v90 is the
|
|
30
|
+
contract on top of v89. The Arena and radar deployment drafts now run the same five-tool lifecycle as agents and
|
|
31
|
+
strategies, and the preview token is retired: a deployment commits on the draft version and the revision you read.
|
|
32
|
+
|
|
33
|
+
### Rejected input — something you send is no longer accepted
|
|
34
|
+
|
|
35
|
+
- **`previewToken` and `confirm`** leave `commit_deployment_policy_draft`, `commit_radar_deployment_draft`,
|
|
36
|
+
`resume_deployment_policy` and `resume_radar_deployment`.
|
|
37
|
+
- **`confirm`** leaves `delete_deployment_policy`, `delete_radar_deployment`, `discard_deployment_policy_draft` and
|
|
38
|
+
`discard_radar_deployment_draft`.
|
|
39
|
+
- Every input is strict, so a call naming either key is refused as an unrecognised key.
|
|
40
|
+
|
|
41
|
+
### Reshaped input
|
|
42
|
+
|
|
43
|
+
- **The commits** take `{ request: { presetId | coinId, draftVersion, expectedRevision } }`: exactly the
|
|
44
|
+
`draftVersion` and `committedRevision` the kind's `get_*_draft` returned (`expectedRevision: null` for a first
|
|
45
|
+
deployment).
|
|
46
|
+
- **The resumes** take `{ presetId | coinId, expectedPolicyId, expectedRevision }`: the `policyId` and `revision` a
|
|
47
|
+
`COMMITTED` preview returned. Any other deployment or revision is a `CONFLICT`, and nothing is armed.
|
|
48
|
+
- **`delete_radar_deployment`** gains `expectedPolicyId` beside `expectedRevision`, as `delete_deployment_policy`
|
|
49
|
+
already took. A delete naming a policy since removed and redeployed matches nothing.
|
|
50
|
+
- **The discards** take `{ request: { presetId | coinId, draftVersion } }` with no dry run. A draft that moved, or
|
|
51
|
+
none, is `DRAFT_VERSION_MOVED`.
|
|
52
|
+
|
|
53
|
+
### Reshaped output — something you read has a new shape
|
|
54
|
+
|
|
55
|
+
- **`stage_deployment_policy_draft` and `stage_radar_deployment_draft`** gain `diagnostics`.
|
|
56
|
+
- **`get_deployment_policy_draft` and `get_radar_deployment_draft`** answer the lifecycle read
|
|
57
|
+
`{ draft, draftVersion, committedRevision, diff, diagnostics, impact }`, where they answered `{ draft }`. `impact`
|
|
58
|
+
is the resolution the commit would arm and whether it plays (`enabledAfterCommit`), plus a radar first
|
|
59
|
+
deployment's coin-cap reading (`admission`); it is null when a diagnostic refuses.
|
|
60
|
+
- **The commits** answer `{ presetId | coinId, revision, draftVersion }`. The radar commit answered `{ revision }`.
|
|
61
|
+
- **The discards** answer `discarded: true`, never `false`.
|
|
62
|
+
- **`preview_deployment_resolution` and `preview_radar_resolution`** lose `previewToken` and gain `policyId` and
|
|
63
|
+
`revision`: the deployment the preview resolved over, null for `SLOTS` and a first deployment.
|
|
64
|
+
|
|
65
|
+
### Removed error codes
|
|
66
|
+
|
|
67
|
+
`TOKEN_EXPIRED`, `TOKEN_BINDING_MISMATCH`, `INVALID_TOKEN_SIGNATURE`, `INVALID_TOKEN_FORMAT` and `INVALID_TOKEN_CLAIMS`
|
|
68
|
+
leave the error vocabulary and every draft diagnostic's code enum — so the stage and get outputs of the agent and
|
|
69
|
+
strategy drafts move too.
|
|
70
|
+
|
|
71
|
+
### Behaviour behind the new schemas
|
|
72
|
+
|
|
73
|
+
- **A retried commit replays its receipt.** Both commits are destructive and idempotent on
|
|
74
|
+
`<presetId | coinId>:<draftVersion>`, as the agent and strategy commits are.
|
|
75
|
+
- **Refusals name the next act.** A moved draft or revision carries `details.nextAct: "get_draft"`; a refusal the
|
|
76
|
+
draft can repair (`INVALID_DEPLOYMENT_POLICY`, or the radar's `VALIDATION_ERROR`) carries `"stage"`; a retired arena
|
|
77
|
+
carries none and names the remedy.
|
|
78
|
+
- **A revision conflict names the revision that won** in `details.actualRevision`, null when no deployment remains.
|
|
79
|
+
- **A `DRAFT` preview at a version the draft is not at** is `DRAFT_VERSION_MOVED`.
|
|
80
|
+
- **A draft whose arena or coin can no longer be deployed is still served**, with the refusal in its diagnostics and
|
|
81
|
+
a null impact, so you can show it and discard it.
|
|
82
|
+
- **A radar resume of a policy already trading** answers its revision and changes nothing.
|
|
83
|
+
- **The radar per-user coin cap is `FORBIDDEN`**, with no `nextAct`, where it was `VALIDATION_ERROR`.
|
|
84
|
+
|
|
85
|
+
Something accepted at v89 is refused at v90 — hence the MAJOR.
|
|
86
|
+
|
|
87
|
+
## Contract history — v89 (a new strategy is held to today's operator bounds)
|
|
88
|
+
|
|
89
|
+
**Breaking at v89: acceptance narrows behind unchanged schemas.** v89 is the contract on top of v88.1.
|
|
90
|
+
|
|
91
|
+
### Narrowed acceptance — `commit_strategy_draft`, `preview_strategy_report` (`DRAFT` source)
|
|
92
|
+
|
|
93
|
+
- **A create judges every dial of the new strategy at the operator bounds configured now.** That includes a dial
|
|
94
|
+
the author typed, one a fork copied from its source, and one left at the creation default. The operator bounds
|
|
95
|
+
are the platform's ATR %, stop-loss ATR-multiple and risk:reward limits.
|
|
96
|
+
- At v88.1 a create judged only the dials that differed from the fork's source or the creation default. So a copied
|
|
97
|
+
dial outside a bound tightened since the source stored it was committed.
|
|
98
|
+
- At v89 `commit_strategy_draft` (`expectedRevision: null`) refuses that create with `VALIDATION_ERROR`, naming the
|
|
99
|
+
dial and the bound, for example `minAtrPct (0.1) must be >= 0.15`. Nothing is created and the draft is unchanged:
|
|
100
|
+
stage the dial inside the bound and commit again.
|
|
101
|
+
- `preview_strategy_report` with `source: { kind: "DRAFT", … }` composes the draft exactly as the commit does, so it
|
|
102
|
+
refuses the same draft with the same error where v88.1 rendered it.
|
|
103
|
+
- `stage_strategy_draft` and `get_strategy_draft` report the error in their diagnostics before the commit.
|
|
104
|
+
- `fork_strategy`'s description now says this, so its description hash moves.
|
|
105
|
+
|
|
106
|
+
### Behaviour behind unchanged schemas
|
|
107
|
+
|
|
108
|
+
- **An edit still judges only what it moves.** An update or a restore carries a dial it leaves unchanged, so a stored
|
|
109
|
+
value outside a since-tightened bound stays readable and saveable on its own strategy.
|
|
110
|
+
- **The platform keeps its defaults creatable.** An operator cannot set a bound that would put a creation default
|
|
111
|
+
outside it, so a create that leaves a dial untouched is never refused for a value the platform seeded.
|
|
112
|
+
|
|
113
|
+
Something accepted at v88.1 is refused at v89 — hence the MAJOR.
|
|
114
|
+
|
|
27
115
|
## Contract history — v88.1 (an open position keeps the exit rules it opened under)
|
|
28
116
|
|
|
29
117
|
**Additive at v88.1: acceptance widens and one served value narrows; no input or output schema
|
package/SKILL.md
CHANGED
|
@@ -58,15 +58,19 @@ than about authoring:
|
|
|
58
58
|
|
|
59
59
|
- **The envelope is `{ request }`, or `{ account, request }` on a multi-account proxy** (see above).
|
|
60
60
|
It applies to every draft lifecycle tool and to `get_strategy_section_template`.
|
|
61
|
-
- **Every change goes through the entity's draft
|
|
62
|
-
draftVersion, axes } })` writes proposed axes
|
|
63
|
-
|
|
61
|
+
- **Every change goes through the entity's draft** — an agent's, a strategy's, and an Arena or radar
|
|
62
|
+
deployment's. `stage_<kind>_draft({ request: { <id>?, draftVersion, axes } })` writes proposed axes
|
|
63
|
+
into the player's unsaved draft and commits nothing. For an agent or a strategy, omit the id to open a
|
|
64
|
+
new create draft, whose minted id the response carries; a deployment draft is keyed by its `presetId`
|
|
65
|
+
or `coinId`, which every call names.
|
|
64
66
|
`get_<kind>_draft({ request: { <id> } })` returns the draft, its `draftVersion`, the live
|
|
65
67
|
`committedRevision`, a per-axis `diff`, `diagnostics` and `impact`.
|
|
66
68
|
- **A commit names exactly the two numbers that read returned.**
|
|
67
69
|
`commit_<kind>_draft({ request: { <id>, draftVersion, expectedRevision } })` — `expectedRevision`
|
|
68
70
|
is `null` for an entity not created yet. Commit only after the player has seen the diff and impact
|
|
69
|
-
and said yes. `discard_<kind>_draft({ request: { <id>, draftVersion } })` is the same fence.
|
|
71
|
+
and said yes. `discard_<kind>_draft({ request: { <id>, draftVersion } })` is the same fence. The two
|
|
72
|
+
deployment commits arm wagers and require `mcp:wager`; a deployment's resume and delete name the
|
|
73
|
+
`expectedPolicyId` and `expectedRevision` a `COMMITTED` preview returned.
|
|
70
74
|
- **The proxy forwards numbers and `null` unchanged.** It never fills in a version, never retries a
|
|
71
75
|
refused call and never rebuilds a request. A `DRAFT_VERSION_MOVED` or `DRAFT_AXIS_CONTESTED` refusal
|
|
72
76
|
carries `details.nextAct` from every tool, and a revision `CONFLICT` or validation refusal carries it
|
|
@@ -89,7 +93,7 @@ The `play-market-grid` prompt (discover via `prompts/list`) provides a guided en
|
|
|
89
93
|
|
|
90
94
|
## Retired operations
|
|
91
95
|
|
|
92
|
-
`create_strategy`, the plan tools (`compile_strategy_plan`, `stage_strategy_plan`, `apply_strategy_plan`), `update_strategy_signal_rule`, and the direct agent writers (`create_intelligence_agent`, `update_intelligence_agent`, `rebind_intelligence_agent`) are **retired** — they are absent from discovery and cannot be invoked. Stage into the entity's draft, read it back, and commit the version you read; a signal rule is a row of the strategy draft's `SIGNAL_RULES` axis, and a strategy binding is the agent draft's `STRATEGY_BINDING` axis. Do not attempt flat legacy payloads; the server enforces a closed-world request root and the proxy never reconstructs them.
|
|
96
|
+
`create_strategy`, the plan tools (`compile_strategy_plan`, `stage_strategy_plan`, `apply_strategy_plan`), `update_strategy_signal_rule`, and the direct agent writers (`create_intelligence_agent`, `update_intelligence_agent`, `rebind_intelligence_agent`) are **retired** — they are absent from discovery and cannot be invoked. Stage into the entity's draft, read it back, and commit the version you read; a signal rule is a row of the strategy draft's `SIGNAL_RULES` axis, and a strategy binding is the agent draft's `STRATEGY_BINDING` axis. A deployment preview's `previewToken`, and the `confirm` on a deployment commit, resume, delete or draft discard, are retired the same way: a strict input refuses either key. Do not attempt flat legacy payloads; the server enforces a closed-world request root and the proxy never reconstructs them.
|
|
93
97
|
|
|
94
98
|
## Common errors
|
|
95
99
|
|
package/dist/index.d.ts
CHANGED
|
@@ -49,7 +49,7 @@ import { type Implementation, type Prompt, type Resource } from '@modelcontextpr
|
|
|
49
49
|
* being asked. Move it for a change to THIS package — a proxy fix, a dependency bump, a docs
|
|
50
50
|
* correction. Never move it to track the server.
|
|
51
51
|
*/
|
|
52
|
-
export declare const PACKAGE_VERSION = "31.2.
|
|
52
|
+
export declare const PACKAGE_VERSION = "31.2.72";
|
|
53
53
|
export declare const DEFAULT_URL = "https://mcp.battlegrid.trade/mcp";
|
|
54
54
|
export interface EnvConfig {
|
|
55
55
|
apiKeys: string[];
|
package/dist/index.js
CHANGED
|
@@ -52,7 +52,7 @@ import { ListToolsRequestSchema, CallToolRequestSchema, ListPromptsRequestSchema
|
|
|
52
52
|
* being asked. Move it for a change to THIS package — a proxy fix, a dependency bump, a docs
|
|
53
53
|
* correction. Never move it to track the server.
|
|
54
54
|
*/
|
|
55
|
-
export const PACKAGE_VERSION = '31.2.
|
|
55
|
+
export const PACKAGE_VERSION = '31.2.72';
|
|
56
56
|
export const DEFAULT_URL = 'https://mcp.battlegrid.trade/mcp';
|
|
57
57
|
const MAX_RETRIES = 3;
|
|
58
58
|
const RETRY_DELAYS_MS = [2000, 4000, 8000];
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@battlegrid/mcp-server",
|
|
3
|
-
"version": "31.2.
|
|
4
|
-
"description": "BattleGrid MCP server
|
|
3
|
+
"version": "31.2.72",
|
|
4
|
+
"description": "BattleGrid MCP server — play crypto prediction games from AI agents",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
7
|
"bin": {
|