@odatano/nightgate-mcp 0.20.1 → 0.20.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/CHANGELOG.md CHANGED
@@ -1,466 +1,483 @@
1
- # Changelog
2
-
3
- All notable changes to `@odatano/nightgate-mcp` are documented in this file.
4
- The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
5
- and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
- The README says which NIGHTGATE the current version needs.
7
-
8
- ## [Unreleased]
9
-
10
- ## [0.20.1] - 2026-10-29
11
-
12
- Needs NIGHTGATE 0.36.0; `send_token`, directed offers and receipts need 0.39.0.
13
-
14
- ### Fixed
15
-
16
- - **`send_token` accepts every shielded address.** `@odatano/nightgate-tx`
17
- 0.17.1 decodes a 132-character shielded address with any `@scure/base` 2.x;
18
- 0.17.0 refused the address `get_swap_wallet` shows under `@scure/base`
19
- 2.4.0 with `invalid string length 132, expected (8..90)`.
20
-
21
- ## [0.20.0] - 2026-10-28
22
-
23
- Needs NIGHTGATE 0.36.0; `send_token`, directed offers and receipts need 0.39.0.
24
-
25
- ### Added
26
-
27
- - **`send_token`.** A sponsored transfer of a shielded token from this wallet
28
- to another shielded address: built and proven here from the wallet's coins,
29
- handed to `sponsorTransfer`, the sponsor pays. The recipient needs nothing
30
- but its address. Needs `sponsorTransfer` in the grant and `@odatano/nightgate-tx`
31
- 0.17.0, which comes with the package.
32
- - **`burn_token`.** Burns an amount of a factory token this wallet holds;
33
- `issuerKey` names a token another issuer minted.
34
- - **`call_contract`.** A circuit call on any contract whose lineage package is
35
- installed next to the server, with tagged arguments (`$bytes`, `$uint`,
36
- `$coin` for a shielded coin funded from this wallet), built here and
37
- sponsored.
38
- - **Directed offers.** `post_swap_offer` with `directed: true` returns a
39
- `takerSecret`, shown once; `take_swap_offer` and `sponsor_swap` take
40
- `takerSecret`, and the sponsor refuses the swap without it. Board rows carry
41
- `directed`.
42
- - **Receipts.** A landed swap or transfer carries `receipt` in its result:
43
- the instance's Ed25519 statement of the chain facts and the terms, checkable
44
- against the key the indexer service publishes under `getReceiptKey()`.
45
-
46
- ## [0.19.0] - 2026-10-28
47
-
48
- Needs NIGHTGATE 0.36.0; `waitMs` needs 0.38.0.
49
-
50
- ### Added
51
-
52
- - **The board waits.** `list_swap_offers` and `my_swap_offers` take `waitMs`
53
- (up to 25000): the server holds an empty answer until an offer matches or
54
- the time is up, so a watcher with `status: 'all'` and `since` makes one
55
- call per change instead of one per interval. Sent only when set, so an
56
- older server answers as before.
57
- - **The wallet reports what is pending.** Each token row of `get_swap_wallet`
58
- carries `pending`, what the halves built here bring back once their swaps
59
- land (the change and the wanted coins). `balance` stays the free coins: a
60
- half can give only from `balance`, and while it can still land the wallet
61
- is worth `balance` plus `pending`. Needs `@odatano/nightgate-tx` 0.16.0,
62
- which comes with the package.
63
-
64
- ### Changed
65
-
66
- - `zod` 4 and `@modelcontextprotocol/sdk` 1.32: the tool schemas are
67
- unchanged for callers; the install carries no known vulnerable package.
68
-
69
- ## [0.18.3] - 2026-10-27
70
-
71
- Needs NIGHTGATE 0.36.0.
72
-
73
- ### Added
74
-
75
- - **Stage timings for writes.** `anchor_document` and `submit_vault_call`
76
- return `timings`: `setupMs` and `proveMs` for the local build, `queueMs`,
77
- `sponsorMs` and `settleMs` from the job's timestamps.
78
- - **Progress names the stage.** The progress messages say what runs, for
79
- example `proving` or `submitted, waiting for the block`, instead of
80
- `working`.
81
-
82
- ## [0.18.2] - 2026-10-27
83
-
84
- Needs NIGHTGATE 0.36.0.
85
-
86
- ### Fixed
87
-
88
- - **`get_swap_wallet` reads the posted offers in one call.** It settled each
89
- offer posted from this server with its own `getSwapOffer`, on every call.
90
- It now reads the caller's offers changed since the last read with one
91
- `listSwapOffers` (`mine`, `status: all`, `since`). A failed read or a full
92
- page falls back to the single reads.
93
- - The MCP server reports the package version instead of a fixed one.
94
-
95
- ## [0.18.1] - 2026-10-26
96
-
97
- Needs NIGHTGATE 0.36.0.
98
-
99
- ### Fixed
100
-
101
- - **Writes from a fresh install.** `@odatano/nightgate-tx` ^0.15.1 installs one
102
- copy of `@midnight-ntwrk/onchain-runtime-v3`. Two copies failed every write
103
- after proving with `expected instance of StateValue`.
104
-
105
- ### Documentation
106
-
107
- - `docs/tools.md`: how a client keeps a write open, and that the MCP Inspector
108
- CLI stops it after 60 seconds.
109
- - README and `docs/tools.md`: servers on one machine share one seed file and
110
- so one identity unless each sets its own seed.
111
-
112
- ## [0.18.0] - 2026-10-26
113
-
114
- Needs NIGHTGATE 0.36.0; from 0.37.0 the server holds each status read until the job settles.
115
-
116
- ### Changed
117
-
118
- - **No tool takes a server wallet session.** Every write is built, proven and
119
- signed here with the caller seed, and a sponsor pays the fee.
120
- - **Writes wait for their job.** `anchor_document`, `submit_vault_call`,
121
- `sponsor_unbound_transaction`, `sponsor_finalized_transaction`,
122
- `sponsor_swap`, `take_swap_offer` (`submit: true`) and `mint_token` return
123
- `status`, `txHash`, `transactionHash`, `result`, on failure `next`, and
124
- `check`, the free call that shows the effect on-chain. They send MCP progress
125
- every 5 seconds. A job still open after 5 minutes, or one whose status cannot
126
- be read, comes back as `pending` with its `jobId` and `txHash`.
127
- - **A repeated call picks up its job.** The same write with the same arguments,
128
- after a client timeout or a `pending`, waits for the job it started instead
129
- of submitting again. A failed job is built anew.
130
- - **`anchor_document(sha256, metadata?, contentRoot?, schemaId?)`** builds the
131
- attest call here; with a content root it anchors that too.
132
- - **`contractAddress` is optional** on the vault tools: default the shared
133
- sandbox vault of the network (preprod `ca0b1e3c…`, preview `31df87bc…`); a
134
- 16-slot `attestation-vault` needs its address.
135
- - **Seed file.** Without `NIGHTGATE_SEED_HEX` the seed is read from
136
- `NIGHTGATE_SEED_FILE` (default `~/.nightgate-mcp/seed`) and created there on
137
- first use; that answer carries `seed: { created, file, meaning }`.
138
- - **Free state reads.** `verify_attestation` and `verify_predicate` read the
139
- public verify service (`/odata/v4/midnight-verify`) without credentials,
140
- unless basic auth or an `ngat_` grant of a direct instance is set.
141
- `NIGHTGATE_VERIFY_SERVICE_PATH` overrides it.
142
- - **`get_usage`** replaces `get_grant_usage`. With a gateway key it reads
143
- `GET /me`: units left, validity, usage and the cost of the last calls.
144
- - `@odatano/nightgate-tx` is a dependency, no longer an optional peer.
145
- - `verify_attestation` describes `bindingRegistered`.
146
-
147
- ### Added
148
-
149
- - `submit_vault_call(call, params, merkleProof?, docPair?)`: any vault call in
150
- one go, with the calls and params of `build_sponsorable_transaction`.
151
-
152
- ### Removed
153
-
154
- - `get_job_status`.
155
- - The tools that needed a server wallet session: `attest_agent_output`,
156
- `prove_field_predicate`, `prove_field_equality`, `prove_field_membership`,
157
- `prove_field_predicates_batch`, `prove_document_integrity`,
158
- `prove_document_diff`, `grant_disclosure`, `revoke_disclosure`,
159
- `verify_document`, `verify_predicate_attestation`. The claims and the
160
- disclosure calls run through `submit_vault_call`.
161
- - `sessionId` on `mint_token`.
162
- - `grant_disclosure_to_holders`, `revoke_holder_disclosure`,
163
- `claim_disclosure`, `holder_claim_key`.
164
-
165
- ## [0.17.1] - 2026-10-25
166
-
167
- Needs NIGHTGATE 0.36.0; `get_job_status` waits on the server from 0.37.0.
168
-
169
- ### Changed
170
-
171
- - The errors for a missing `NIGHTGATE_SEED_HEX` name its format: 128 hex
172
- characters, a 64-byte BIP39 seed. Same wording in
173
- [docs/configuration.md](docs/configuration.md).
174
-
175
- ## [0.17.0] - 2026-10-25
176
-
177
- Needs NIGHTGATE 0.36.0; `get_job_status` waits on the server from 0.37.0.
178
-
179
- ### Changed
180
-
181
- - **`get_job_status` waits instead of polling.** It passes `waitMs` (default
182
- 20000, at most 25000) and the server holds the call until the job settles;
183
- a server without `waitMs` is asked again without it. Tool descriptions say
184
- call instead of poll.
185
- - **Explorer hash.** The descriptions name `transactionHash`, the hash
186
- explorers show, next to the ledger identifier `txHash` / `transactionId`.
187
- - **Default vault lineage `attestation-vault-32`**, the lineage of the hosted
188
- sandbox vaults: the local builder, its prover keys and every tool that
189
- sends `compiledArtifactRef` use it when none is given. A 16-slot vault needs
190
- `compiledArtifactRef: 'attestation-vault'`.
191
-
192
- ## [0.16.0] - 2026-10-24
193
-
194
- Needs NIGHTGATE 0.36.0 and `@odatano/nightgate-tx` 0.14.0.
195
-
196
- ### Changed
197
-
198
- - **The proof tools send typed parameters.** `siblings`, `dirs`, `setSiblings`,
199
- `setDirs`, `allowedValues`, `claims`, `schema`, `openingA`, `openingB`,
200
- `document` and `proofFields` go to NIGHTGATE as arrays and objects; the
201
- `*Json` string parameters of NIGHTGATE 0.35 and below are not sent anymore.
202
- `post_swap_offer` sends `tags` as an array. Tool inputs are unchanged.
203
-
204
- ## [0.15.0] - 2026-10-19
205
-
206
- Needs NIGHTGATE 0.35.0 and `@odatano/nightgate-tx` 0.14.0; analytics under `/odata/v4/analytics` (the gateway serves both names).
207
-
208
- ### Changed
209
-
210
- - **The analytics URL defaults to `<ODATANO_ACCESS_URL>/odata/v4/analytics`**
211
- instead of `…/odata/v4/astra`. An ASTRA instance that still serves
212
- `/odata/v4/astra` needs `ODATANO_ANALYTICS_URL` set to that path.
213
-
214
- ## [0.14.0] - 2026-10-18
215
-
216
- Needs NIGHTGATE 0.35.0 and `@odatano/nightgate-tx` 0.14.0 (the gateway serves both spellings).
217
-
218
- ### Changed
219
-
220
- - The tools call NIGHTGATE under `/odata/v4/midnight` and
221
- `/odata/v4/midnight-indexer`. Against a server below 0.35.0 set
222
- `NIGHTGATE_SERVICE_PATH=/api/v1/nightgate` and
223
- `NIGHTGATE_INDEXER_SERVICE_PATH=/api/v1/indexer`.
224
-
225
- ## [0.13.0] - 2026-10-15
226
-
227
- Needs NIGHTGATE 0.34.0 and `@odatano/nightgate-tx` 0.12.2.
228
-
229
- ### Added
230
-
231
- - `get_grant_usage`: the key's jobs and its limits, the hour and day budgets
232
- and the rate classes with what is left.
233
-
234
- ### Changed
235
-
236
- - A 429 from NIGHTGATE carries `retryAfterSeconds` from `Retry-After`, as a
237
- gateway 429 did already.
238
-
239
- ## [0.12.0] - 2026-10-13
240
-
241
- Needs NIGHTGATE 0.33.0 and `@odatano/nightgate-tx` 0.12.2.
242
-
243
- ### Changed
244
-
245
- - `build_sponsorable_transaction` and the local `mint_token` read contract
246
- state through the NIGHTGATE API (`createTxBuilder({ api })`); they dial no
247
- indexer and no node. `NIGHTGATE_INDEXER_HTTP_URL` and `NIGHTGATE_INDEXER_WS_URL`
248
- switch them back to a Midnight indexer.
249
- - The swap wallet syncs from `NIGHTGATE_INDEXER_HTTP_URL` and
250
- `NIGHTGATE_INDEXER_WS_URL` only; without them the swap tools refuse with
251
- the two names instead of dialing the public indexer.
252
- - `build_sponsorable_transaction` returns `txId` (sha256 of the bytes),
253
- `characters` and `bytes` instead of the base64; the bytes stay in the server
254
- process for one hour, `outFile` writes them to a path.
255
- - `sponsor_unbound_transaction` and `sponsor_finalized_transaction` take `txId`
256
- or `file` (base64 text or raw bytes); the base64 argument remains for callers
257
- without either. The result carries `sent` with characters, bytes and `txId`.
258
-
259
- ## [0.11.0] - 2026-10-12
260
-
261
- Needs NIGHTGATE 0.32.0.
262
-
263
- ### Changed
264
-
265
- - `sponsor_finalized_transaction`, `sponsor_unbound_transaction`, `sponsor_swap`
266
- and `mint_token` take no `sponsorSessionId`: the server's sponsor pool pays,
267
- or the wallet session the agent grant is pinned to.
268
- - `take_swap_offer`: `submit: true` hands both halves to the sponsor at once;
269
- it replaces the sponsor session id as the trigger.
270
- - The platform pool id is gone from every tool description.
271
-
272
- ## [0.10.1] - 2026-10-03
273
-
274
- ### Fixed
275
-
276
- - A maker half posted with `post_swap_offer` is tied to its `offerId`; `get_swap_wallet`
277
- lists it with `offerId` and `boardStatus` and drops it once the offer is `filled`
278
- (read through `get_swap_wallet`, `get_swap_offer`, `list_swap_offers`, `my_swap_offers`).
279
- An expired or retired offer keeps its half for `revert_swap_offer`.
280
- - Board rows carry `tags` as the server sends them: an array from NIGHTGATE 0.30.3 on.
281
-
282
- ## [0.10.0] - 2026-10-02
283
-
284
- ### Added
285
-
286
- - **Offer board** (NIGHTGATE 0.30.0): `post_swap_offer(offer, expiresAt?, tags?)`,
287
- `list_swap_offers(givesType?, wantsType?, tag?, limit?)`, `retire_swap_offer(offerId)`.
288
- `sponsor_swap` and `take_swap_offer` take an `offerId` from the board in place of the
289
- maker half: `take_swap_offer` reads the entry first and refuses before proving when it
290
- is closed or carries another offer; `sponsor_swap` pairs `offerId` with `takerHalf` or
291
- the `halfId` of a taken offer.
292
- - **Board reads** (NIGHTGATE 0.30.1): `list_swap_offers(status?, since?)` reads closed
293
- offers and the change feed, `my_swap_offers(status?, since?, limit?)` the caller's own
294
- posts, `get_swap_offer(offerId)` one offer open or closed, `get_board_status()` the
295
- board's counts and sponsor readiness without credentials (indexer service,
296
- `NIGHTGATE_INDEXER_SERVICE_PATH`, default `/api/v1/indexer`).
297
- - **`mint_token(contractAddress, name, amount, recipientCoinPublicKey?, recipientEncryptionPublicKey?, sponsorSessionId?, sessionId?, idempotencyKey?)`**:
298
- a token of your own name on a token factory. Without `sessionId` the seed is the issuer,
299
- the mint is built, proven and signed here (`@odatano/nightgate-tx` 0.10.2 on
300
- `@odatano/contract-token-factory`) and `sponsorUnboundTransaction` pays; with `sessionId`
301
- the server session mints (`mintFactoryToken`, NIGHTGATE 0.30.1). The recipient defaults
302
- to this wallet; another wallet takes both of its keys. The type is in the response.
303
- - **Disclosure to token holders**: `grant_disclosure_to_holders(payloadHash, tokenType,
304
- registryAddress, content?, contentType?, expiresAt?)`, `revoke_holder_disclosure(holderGrantId)`,
305
- `claim_disclosure(payloadHash, tokenType, claimSecret)`, `holder_claim_key(claimSecret?)`.
306
-
307
- ### Changed
308
-
309
- - Peer dependency `@odatano/nightgate-tx` `>=0.10.2` (`holderClaimKey`, `tokenFactoryIssuerSecret`); local building and swaps still run on 0.8.0. A missing or older install is reported per tool with the version it needs. Optional peer `@odatano/contract-token-factory` for local minting.
310
- - `mint_token` derives the default recipient from the seed without starting the local builder.
311
- - Amounts given as JS numbers must be safe integers; pass a decimal string for anything larger.
312
- - Function calls pass an unused declared parameter as `null`.
313
-
314
- ## [0.9.0] - 2026-09-30
315
-
316
- ### Added
317
-
318
- - **Shielded swap tools** (NIGHTGATE 0.29.0, `@odatano/nightgate-tx` 0.8.0):
319
- - `get_swap_wallet`: address, public keys, per token type balance, free coins and
320
- `spendable`; halves built here that have not landed.
321
- - `read_swap_offer`: `gives`, `wants`, `inputs`, `outputs`, `bound` of an offer file or
322
- base64 half, read from the transaction.
323
- - `build_swap_offer(give, want, bind?)`: one proven half, as offer file (`swapoffer1...`).
324
- - `take_swap_offer(offer, expect?, sponsorSessionId?, idempotencyKey?)`: the mirror half;
325
- with a sponsor session it submits both halves. A refusal carries `halfId`.
326
- - `sponsor_swap(makerHalf, takerHalf | halfId, sponsorSessionId, idempotencyKey?)`.
327
- - `revert_swap_offer(id)`: releases the coins of a half built here.
328
- - `NIGHTGATE_SWAP_STATE_FILE`, `NIGHTGATE_SWAP_MAX_INPUTS`.
329
- - `get_attester_identity` returns `shieldedAddress`, `coinPublicKey`, `encryptionPublicKey`.
330
- - `npm run integration` covers the swap tools (`scripts/integration-swap.mjs`).
331
-
332
- ### Changed
333
-
334
- - Peer dependency `@odatano/nightgate-tx` `>=0.8.0` (was `>=0.6.0`).
335
- - Lockfile: one `@midnight-ntwrk/ledger-v8` (8.1.0) in the tree. Two copies made the local
336
- builder fail with `expected instance of DustParameters`.
337
- - `live:sponsor-unbound` verifies with the attester id.
338
- - `NIGHTGATE_SEED_HEX` is 128 hex (a 64-byte BIP39 seed); 64 hex is refused at startup.
339
- - `get_job_status` describes the `swap` result of a swap job.
340
-
341
- ## [0.8.1] - 2026-09-27
342
-
343
- ### Changed
344
-
345
- - `get_job_status` describes `chainSegments` (NIGHTGATE 0.28.0): for a confirmed batch,
346
- which calls applied. Tool errors carry the server's string `code` (`INVALID_ARGUMENT`, ...).
347
- - README reorganized; compatibility names the current version only.
348
-
349
- ## [0.8.0] - 2026-09-23
350
-
351
- ### Added
352
-
353
- - **Analytics tools over ODATANO ASTRA** (`analytics_overview`, `analytics_key_figures`,
354
- `analytics_daily`, `analytics_top_block_producers`, `analytics_metrics`, `analytics_metric`,
355
- `analytics_series`, `analytics_compare`, `analytics_anomalies`), registered when the host
356
- serves ASTRA at `ODATANO_ANALYTICS_URL` (default: the gateway's `/odata/v4/astra`). Same key,
357
- one unit per read, chain pinned to Midnight; `analytics_compare` puts Cardano next to it.
358
-
359
- ### Changed
360
-
361
- - **Default gateway host is `https://api.preprod.odatano.dev`** (one host per
362
- network; `api.odatano.dev` now only redirects there with a 307). Node drops
363
- the `Authorization` header on a cross-host redirect, so the old default
364
- would answer 401 for every call: set `ODATANO_ACCESS_URL` explicitly on
365
- older versions, or upgrade. The missing-key warning fires for any
366
- `api.<network>.odatano.dev` host.
367
-
368
- ## [0.7.0] - 2026-09-20
369
-
370
- ### Changed (breaking)
371
-
372
- - **One connection env for both ODATANO MCP servers.** `ODATANO_ACCESS_URL`
373
- (default `https://api.odatano.dev`, the gateway), `ODATANO_ACCESS_KEY`
374
- (the `oda_…` key, or an `ngat_…` grant / other bearer against a direct
375
- instance) and `ODATANO_ACCESS_USER` / `ODATANO_ACCESS_PASSWORD` (basic
376
- auth for a direct instance) replace `NIGHTGATE_BASE_URL`,
377
- `NIGHTGATE_TOKEN`, `NIGHTGATE_USERNAME` and `NIGHTGATE_PASSWORD`; the old
378
- names are not read any more. `@odatano/core-mcp` 0.3.0 reads the same
379
- four, so an `.mcp.json` needs one key for both chains and no URL. The
380
- other `NIGHTGATE_*` variables (network, seed, indexer, zk-config, proof
381
- server, timeout, service path) are unchanged.
382
- - **Gateway error bodies reach the agent.** The ODATANO ACCESS gateway
383
- answers with `{ error: "<text>", ...detail }`; the client now keeps the
384
- text as the message and hands the detail (`unitsLeft`, `price`, the
385
- `topup` hint, `products`, `validUntil`, `retryAfterSeconds` from
386
- `Retry-After`) through to the tool error, so a 402 says how to top up
387
- instead of "request failed with HTTP 402".
388
- - **The hosted API is the documented default.** README: quick start with a
389
- key from api.odatano.dev first, sponsoring through the gateway's platform
390
- pool, own instance second; the server warns at startup when the gateway
391
- is the target and no key is set. Server version constant follows the
392
- package.
393
-
394
- ## [0.6.1] - 2026-09-19
395
-
396
- ### Changed
397
-
398
- - **The ODATANO ACCESS key (`oda_…`) is the documented credential.**
399
- `api.nightgate.dev` is the ODATANO ACCESS gateway since 2026-09-18: it
400
- meters the key in units, swaps in the NIGHTGATE agent grant underneath and
401
- fronts ODATANO with the same key. Set `NIGHTGATE_BASE_URL=https://api.nightgate.dev`
402
- and `NIGHTGATE_TOKEN=oda_…`; the key goes as a plain `Authorization: Bearer`.
403
- Get one at `POST https://api.odatano.dev/keys` (x402), from a giveaway
404
- code, or by signing in at the console. A raw `ngat_…` agent grant
405
- (`x-agent-token`) still works against a direct NIGHTGATE instance. No code
406
- change: the client already sent a prefix-less token as a bearer.
407
- - `.env.example` and README updated accordingly; this changelog added and
408
- shipped with the package.
409
-
410
- ## [0.6.0] - 2026-09
411
-
412
- ### Changed (breaking)
413
-
414
- - **Vault lineage 4: every record is keyed by attester AND payload**
415
- (NIGHTGATE >= 0.24.0). `verify_attestation` takes `attesterId` +
416
- `payloadHash` (or a bound `documentId`), `verify_predicate` takes
417
- `attesterId`, the `prove_*` tools accept an optional `attesterId` (the
418
- record the claim is proven against), `anchor_document` is one plain attest
419
- and returns `attesterId`.
420
- - `prepare_anchor_commitment` and `commit_document_anchor` are gone: nothing
421
- is left to guard, no identity can take over another attester's record.
422
- - Local building needs `@odatano/nightgate-tx` >= 0.6.0; the proof calls
423
- take `recordKey` or `payloadHash` (+ `attesterId`). Against a 0.23.x server
424
- the verify calls fail with 400 (unknown parameter).
425
-
426
- ## [0.5.1] - 2026-08-23
427
-
428
- ### Added
429
-
430
- - **32-slot vault.** Schema and opening take 16 or 32 entries, `allowedMask`
431
- up to 32 bits, `k` up to 32; the vacuity guard is checked against the
432
- schema instead of a fixed all-ones constant. Target it with
433
- `compiledArtifactRef: 'attestation-vault-32'` (NIGHTGATE >= 0.19.0 for
434
- width 32). A 16-slot setup keeps working against any 0.18.x server.
435
- - Local ZK claims: field and document proofs can be built in-process.
436
-
437
- ## [0.5.0] - 2026-08-19
438
-
439
- ### Added
440
-
441
- - **Parallel sponsoring channel:** `sponsor_unbound_transaction` with the
442
- platform pool id (NIGHTGATE >= 0.18.0; 404 against older servers).
443
- - **Local transaction building** for agents: `build_sponsorable_transaction`
444
- and `get_attester_identity` via the optional `@odatano/nightgate-tx`
445
- >= 0.2.0 txbuilder, driven by `NIGHTGATE_SEED_HEX` (never a tool argument).
446
-
447
- ## [0.3.0] - 2026-08-16
448
-
449
- ### Added
450
-
451
- - Cross-root document proofs and guarded anchoring (`prepare_anchor_commitment`
452
- / `commit_document_anchor`, removed again in 0.6.0).
453
-
454
- ## [0.2.0] - 2026-08-10
455
-
456
- ### Added
457
-
458
- - Membership and equality proof tools; README documents the tool set and the
459
- server compatibility table.
460
-
461
- ## [0.1.0] - 2026-08-07
462
-
463
- ### Added
464
-
465
- - Initial MCP server: attestation, verification and job tools over the
466
- NIGHTGATE OData API, agent-grant (`ngat_…`) or basic auth.
1
+ # Changelog
2
+
3
+ All notable changes to `@odatano/nightgate-mcp` are documented in this file.
4
+ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
5
+ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
+ The README says which NIGHTGATE the current version needs.
7
+
8
+ ## [Unreleased]
9
+
10
+ ## [0.20.2] - 2026-10-29
11
+
12
+ Needs NIGHTGATE 0.36.0; `send_token`, directed offers and receipts need 0.39.0.
13
+
14
+ ### Fixed
15
+
16
+ - **A landed swap or transfer answers with its receipt.** `send_token`,
17
+ `sponsor_swap` and `take_swap_offer` returned at job status `succeeded`,
18
+ before the block confirmed the transaction, so `receipt` was null in every
19
+ answer. The tool now keeps reading until `chainStatus` is `success`,
20
+ `failure` or `dropped`, within the same 5-minute wait; `next` says what to do
21
+ when the wait ran out or the chain refused the transaction. The progress
22
+ message names the stage (`landed, waiting for the block and the receipt`).
23
+ - **Depends on `@odatano/nightgate-tx` 0.18.0.** `createTxBuilder` gained `walletSync: 'coins'`
24
+ (shielded and NIGHT coins, no dust wallet) and sync progress events; nothing in the
25
+ tools changes, `call_contract` keeps the shielded sync.
26
+
27
+ ## [0.20.1] - 2026-10-29
28
+
29
+ Needs NIGHTGATE 0.36.0; `send_token`, directed offers and receipts need 0.39.0.
30
+
31
+ ### Fixed
32
+
33
+ - **`send_token` accepts every shielded address.** `@odatano/nightgate-tx`
34
+ 0.17.1 decodes a 132-character shielded address with any `@scure/base` 2.x;
35
+ 0.17.0 refused the address `get_swap_wallet` shows under `@scure/base`
36
+ 2.4.0 with `invalid string length 132, expected (8..90)`.
37
+
38
+ ## [0.20.0] - 2026-10-28
39
+
40
+ Needs NIGHTGATE 0.36.0; `send_token`, directed offers and receipts need 0.39.0.
41
+
42
+ ### Added
43
+
44
+ - **`send_token`.** A sponsored transfer of a shielded token from this wallet
45
+ to another shielded address: built and proven here from the wallet's coins,
46
+ handed to `sponsorTransfer`, the sponsor pays. The recipient needs nothing
47
+ but its address. Needs `sponsorTransfer` in the grant and `@odatano/nightgate-tx`
48
+ 0.17.0, which comes with the package.
49
+ - **`burn_token`.** Burns an amount of a factory token this wallet holds;
50
+ `issuerKey` names a token another issuer minted.
51
+ - **`call_contract`.** A circuit call on any contract whose lineage package is
52
+ installed next to the server, with tagged arguments (`$bytes`, `$uint`,
53
+ `$coin` for a shielded coin funded from this wallet), built here and
54
+ sponsored.
55
+ - **Directed offers.** `post_swap_offer` with `directed: true` returns a
56
+ `takerSecret`, shown once; `take_swap_offer` and `sponsor_swap` take
57
+ `takerSecret`, and the sponsor refuses the swap without it. Board rows carry
58
+ `directed`.
59
+ - **Receipts.** A landed swap or transfer carries `receipt` in its result:
60
+ the instance's Ed25519 statement of the chain facts and the terms, checkable
61
+ against the key the indexer service publishes under `getReceiptKey()`.
62
+
63
+ ## [0.19.0] - 2026-10-28
64
+
65
+ Needs NIGHTGATE 0.36.0; `waitMs` needs 0.38.0.
66
+
67
+ ### Added
68
+
69
+ - **The board waits.** `list_swap_offers` and `my_swap_offers` take `waitMs`
70
+ (up to 25000): the server holds an empty answer until an offer matches or
71
+ the time is up, so a watcher with `status: 'all'` and `since` makes one
72
+ call per change instead of one per interval. Sent only when set, so an
73
+ older server answers as before.
74
+ - **The wallet reports what is pending.** Each token row of `get_swap_wallet`
75
+ carries `pending`, what the halves built here bring back once their swaps
76
+ land (the change and the wanted coins). `balance` stays the free coins: a
77
+ half can give only from `balance`, and while it can still land the wallet
78
+ is worth `balance` plus `pending`. Needs `@odatano/nightgate-tx` 0.16.0,
79
+ which comes with the package.
80
+
81
+ ### Changed
82
+
83
+ - `zod` 4 and `@modelcontextprotocol/sdk` 1.32: the tool schemas are
84
+ unchanged for callers; the install carries no known vulnerable package.
85
+
86
+ ## [0.18.3] - 2026-10-27
87
+
88
+ Needs NIGHTGATE 0.36.0.
89
+
90
+ ### Added
91
+
92
+ - **Stage timings for writes.** `anchor_document` and `submit_vault_call`
93
+ return `timings`: `setupMs` and `proveMs` for the local build, `queueMs`,
94
+ `sponsorMs` and `settleMs` from the job's timestamps.
95
+ - **Progress names the stage.** The progress messages say what runs, for
96
+ example `proving` or `submitted, waiting for the block`, instead of
97
+ `working`.
98
+
99
+ ## [0.18.2] - 2026-10-27
100
+
101
+ Needs NIGHTGATE 0.36.0.
102
+
103
+ ### Fixed
104
+
105
+ - **`get_swap_wallet` reads the posted offers in one call.** It settled each
106
+ offer posted from this server with its own `getSwapOffer`, on every call.
107
+ It now reads the caller's offers changed since the last read with one
108
+ `listSwapOffers` (`mine`, `status: all`, `since`). A failed read or a full
109
+ page falls back to the single reads.
110
+ - The MCP server reports the package version instead of a fixed one.
111
+
112
+ ## [0.18.1] - 2026-10-26
113
+
114
+ Needs NIGHTGATE 0.36.0.
115
+
116
+ ### Fixed
117
+
118
+ - **Writes from a fresh install.** `@odatano/nightgate-tx` ^0.15.1 installs one
119
+ copy of `@midnight-ntwrk/onchain-runtime-v3`. Two copies failed every write
120
+ after proving with `expected instance of StateValue`.
121
+
122
+ ### Documentation
123
+
124
+ - `docs/tools.md`: how a client keeps a write open, and that the MCP Inspector
125
+ CLI stops it after 60 seconds.
126
+ - README and `docs/tools.md`: servers on one machine share one seed file and
127
+ so one identity unless each sets its own seed.
128
+
129
+ ## [0.18.0] - 2026-10-26
130
+
131
+ Needs NIGHTGATE 0.36.0; from 0.37.0 the server holds each status read until the job settles.
132
+
133
+ ### Changed
134
+
135
+ - **No tool takes a server wallet session.** Every write is built, proven and
136
+ signed here with the caller seed, and a sponsor pays the fee.
137
+ - **Writes wait for their job.** `anchor_document`, `submit_vault_call`,
138
+ `sponsor_unbound_transaction`, `sponsor_finalized_transaction`,
139
+ `sponsor_swap`, `take_swap_offer` (`submit: true`) and `mint_token` return
140
+ `status`, `txHash`, `transactionHash`, `result`, on failure `next`, and
141
+ `check`, the free call that shows the effect on-chain. They send MCP progress
142
+ every 5 seconds. A job still open after 5 minutes, or one whose status cannot
143
+ be read, comes back as `pending` with its `jobId` and `txHash`.
144
+ - **A repeated call picks up its job.** The same write with the same arguments,
145
+ after a client timeout or a `pending`, waits for the job it started instead
146
+ of submitting again. A failed job is built anew.
147
+ - **`anchor_document(sha256, metadata?, contentRoot?, schemaId?)`** builds the
148
+ attest call here; with a content root it anchors that too.
149
+ - **`contractAddress` is optional** on the vault tools: default the shared
150
+ sandbox vault of the network (preprod `ca0b1e3c…`, preview `31df87bc…`); a
151
+ 16-slot `attestation-vault` needs its address.
152
+ - **Seed file.** Without `NIGHTGATE_SEED_HEX` the seed is read from
153
+ `NIGHTGATE_SEED_FILE` (default `~/.nightgate-mcp/seed`) and created there on
154
+ first use; that answer carries `seed: { created, file, meaning }`.
155
+ - **Free state reads.** `verify_attestation` and `verify_predicate` read the
156
+ public verify service (`/odata/v4/midnight-verify`) without credentials,
157
+ unless basic auth or an `ngat_` grant of a direct instance is set.
158
+ `NIGHTGATE_VERIFY_SERVICE_PATH` overrides it.
159
+ - **`get_usage`** replaces `get_grant_usage`. With a gateway key it reads
160
+ `GET /me`: units left, validity, usage and the cost of the last calls.
161
+ - `@odatano/nightgate-tx` is a dependency, no longer an optional peer.
162
+ - `verify_attestation` describes `bindingRegistered`.
163
+
164
+ ### Added
165
+
166
+ - `submit_vault_call(call, params, merkleProof?, docPair?)`: any vault call in
167
+ one go, with the calls and params of `build_sponsorable_transaction`.
168
+
169
+ ### Removed
170
+
171
+ - `get_job_status`.
172
+ - The tools that needed a server wallet session: `attest_agent_output`,
173
+ `prove_field_predicate`, `prove_field_equality`, `prove_field_membership`,
174
+ `prove_field_predicates_batch`, `prove_document_integrity`,
175
+ `prove_document_diff`, `grant_disclosure`, `revoke_disclosure`,
176
+ `verify_document`, `verify_predicate_attestation`. The claims and the
177
+ disclosure calls run through `submit_vault_call`.
178
+ - `sessionId` on `mint_token`.
179
+ - `grant_disclosure_to_holders`, `revoke_holder_disclosure`,
180
+ `claim_disclosure`, `holder_claim_key`.
181
+
182
+ ## [0.17.1] - 2026-10-25
183
+
184
+ Needs NIGHTGATE 0.36.0; `get_job_status` waits on the server from 0.37.0.
185
+
186
+ ### Changed
187
+
188
+ - The errors for a missing `NIGHTGATE_SEED_HEX` name its format: 128 hex
189
+ characters, a 64-byte BIP39 seed. Same wording in
190
+ [docs/configuration.md](docs/configuration.md).
191
+
192
+ ## [0.17.0] - 2026-10-25
193
+
194
+ Needs NIGHTGATE 0.36.0; `get_job_status` waits on the server from 0.37.0.
195
+
196
+ ### Changed
197
+
198
+ - **`get_job_status` waits instead of polling.** It passes `waitMs` (default
199
+ 20000, at most 25000) and the server holds the call until the job settles;
200
+ a server without `waitMs` is asked again without it. Tool descriptions say
201
+ call instead of poll.
202
+ - **Explorer hash.** The descriptions name `transactionHash`, the hash
203
+ explorers show, next to the ledger identifier `txHash` / `transactionId`.
204
+ - **Default vault lineage `attestation-vault-32`**, the lineage of the hosted
205
+ sandbox vaults: the local builder, its prover keys and every tool that
206
+ sends `compiledArtifactRef` use it when none is given. A 16-slot vault needs
207
+ `compiledArtifactRef: 'attestation-vault'`.
208
+
209
+ ## [0.16.0] - 2026-10-24
210
+
211
+ Needs NIGHTGATE 0.36.0 and `@odatano/nightgate-tx` 0.14.0.
212
+
213
+ ### Changed
214
+
215
+ - **The proof tools send typed parameters.** `siblings`, `dirs`, `setSiblings`,
216
+ `setDirs`, `allowedValues`, `claims`, `schema`, `openingA`, `openingB`,
217
+ `document` and `proofFields` go to NIGHTGATE as arrays and objects; the
218
+ `*Json` string parameters of NIGHTGATE 0.35 and below are not sent anymore.
219
+ `post_swap_offer` sends `tags` as an array. Tool inputs are unchanged.
220
+
221
+ ## [0.15.0] - 2026-10-19
222
+
223
+ Needs NIGHTGATE 0.35.0 and `@odatano/nightgate-tx` 0.14.0; analytics under `/odata/v4/analytics` (the gateway serves both names).
224
+
225
+ ### Changed
226
+
227
+ - **The analytics URL defaults to `<ODATANO_ACCESS_URL>/odata/v4/analytics`**
228
+ instead of `…/odata/v4/astra`. An ASTRA instance that still serves
229
+ `/odata/v4/astra` needs `ODATANO_ANALYTICS_URL` set to that path.
230
+
231
+ ## [0.14.0] - 2026-10-18
232
+
233
+ Needs NIGHTGATE 0.35.0 and `@odatano/nightgate-tx` 0.14.0 (the gateway serves both spellings).
234
+
235
+ ### Changed
236
+
237
+ - The tools call NIGHTGATE under `/odata/v4/midnight` and
238
+ `/odata/v4/midnight-indexer`. Against a server below 0.35.0 set
239
+ `NIGHTGATE_SERVICE_PATH=/api/v1/nightgate` and
240
+ `NIGHTGATE_INDEXER_SERVICE_PATH=/api/v1/indexer`.
241
+
242
+ ## [0.13.0] - 2026-10-15
243
+
244
+ Needs NIGHTGATE 0.34.0 and `@odatano/nightgate-tx` 0.12.2.
245
+
246
+ ### Added
247
+
248
+ - `get_grant_usage`: the key's jobs and its limits, the hour and day budgets
249
+ and the rate classes with what is left.
250
+
251
+ ### Changed
252
+
253
+ - A 429 from NIGHTGATE carries `retryAfterSeconds` from `Retry-After`, as a
254
+ gateway 429 did already.
255
+
256
+ ## [0.12.0] - 2026-10-13
257
+
258
+ Needs NIGHTGATE 0.33.0 and `@odatano/nightgate-tx` 0.12.2.
259
+
260
+ ### Changed
261
+
262
+ - `build_sponsorable_transaction` and the local `mint_token` read contract
263
+ state through the NIGHTGATE API (`createTxBuilder({ api })`); they dial no
264
+ indexer and no node. `NIGHTGATE_INDEXER_HTTP_URL` and `NIGHTGATE_INDEXER_WS_URL`
265
+ switch them back to a Midnight indexer.
266
+ - The swap wallet syncs from `NIGHTGATE_INDEXER_HTTP_URL` and
267
+ `NIGHTGATE_INDEXER_WS_URL` only; without them the swap tools refuse with
268
+ the two names instead of dialing the public indexer.
269
+ - `build_sponsorable_transaction` returns `txId` (sha256 of the bytes),
270
+ `characters` and `bytes` instead of the base64; the bytes stay in the server
271
+ process for one hour, `outFile` writes them to a path.
272
+ - `sponsor_unbound_transaction` and `sponsor_finalized_transaction` take `txId`
273
+ or `file` (base64 text or raw bytes); the base64 argument remains for callers
274
+ without either. The result carries `sent` with characters, bytes and `txId`.
275
+
276
+ ## [0.11.0] - 2026-10-12
277
+
278
+ Needs NIGHTGATE 0.32.0.
279
+
280
+ ### Changed
281
+
282
+ - `sponsor_finalized_transaction`, `sponsor_unbound_transaction`, `sponsor_swap`
283
+ and `mint_token` take no `sponsorSessionId`: the server's sponsor pool pays,
284
+ or the wallet session the agent grant is pinned to.
285
+ - `take_swap_offer`: `submit: true` hands both halves to the sponsor at once;
286
+ it replaces the sponsor session id as the trigger.
287
+ - The platform pool id is gone from every tool description.
288
+
289
+ ## [0.10.1] - 2026-10-03
290
+
291
+ ### Fixed
292
+
293
+ - A maker half posted with `post_swap_offer` is tied to its `offerId`; `get_swap_wallet`
294
+ lists it with `offerId` and `boardStatus` and drops it once the offer is `filled`
295
+ (read through `get_swap_wallet`, `get_swap_offer`, `list_swap_offers`, `my_swap_offers`).
296
+ An expired or retired offer keeps its half for `revert_swap_offer`.
297
+ - Board rows carry `tags` as the server sends them: an array from NIGHTGATE 0.30.3 on.
298
+
299
+ ## [0.10.0] - 2026-10-02
300
+
301
+ ### Added
302
+
303
+ - **Offer board** (NIGHTGATE 0.30.0): `post_swap_offer(offer, expiresAt?, tags?)`,
304
+ `list_swap_offers(givesType?, wantsType?, tag?, limit?)`, `retire_swap_offer(offerId)`.
305
+ `sponsor_swap` and `take_swap_offer` take an `offerId` from the board in place of the
306
+ maker half: `take_swap_offer` reads the entry first and refuses before proving when it
307
+ is closed or carries another offer; `sponsor_swap` pairs `offerId` with `takerHalf` or
308
+ the `halfId` of a taken offer.
309
+ - **Board reads** (NIGHTGATE 0.30.1): `list_swap_offers(status?, since?)` reads closed
310
+ offers and the change feed, `my_swap_offers(status?, since?, limit?)` the caller's own
311
+ posts, `get_swap_offer(offerId)` one offer open or closed, `get_board_status()` the
312
+ board's counts and sponsor readiness without credentials (indexer service,
313
+ `NIGHTGATE_INDEXER_SERVICE_PATH`, default `/api/v1/indexer`).
314
+ - **`mint_token(contractAddress, name, amount, recipientCoinPublicKey?, recipientEncryptionPublicKey?, sponsorSessionId?, sessionId?, idempotencyKey?)`**:
315
+ a token of your own name on a token factory. Without `sessionId` the seed is the issuer,
316
+ the mint is built, proven and signed here (`@odatano/nightgate-tx` 0.10.2 on
317
+ `@odatano/contract-token-factory`) and `sponsorUnboundTransaction` pays; with `sessionId`
318
+ the server session mints (`mintFactoryToken`, NIGHTGATE 0.30.1). The recipient defaults
319
+ to this wallet; another wallet takes both of its keys. The type is in the response.
320
+ - **Disclosure to token holders**: `grant_disclosure_to_holders(payloadHash, tokenType,
321
+ registryAddress, content?, contentType?, expiresAt?)`, `revoke_holder_disclosure(holderGrantId)`,
322
+ `claim_disclosure(payloadHash, tokenType, claimSecret)`, `holder_claim_key(claimSecret?)`.
323
+
324
+ ### Changed
325
+
326
+ - Peer dependency `@odatano/nightgate-tx` `>=0.10.2` (`holderClaimKey`, `tokenFactoryIssuerSecret`); local building and swaps still run on 0.8.0. A missing or older install is reported per tool with the version it needs. Optional peer `@odatano/contract-token-factory` for local minting.
327
+ - `mint_token` derives the default recipient from the seed without starting the local builder.
328
+ - Amounts given as JS numbers must be safe integers; pass a decimal string for anything larger.
329
+ - Function calls pass an unused declared parameter as `null`.
330
+
331
+ ## [0.9.0] - 2026-09-30
332
+
333
+ ### Added
334
+
335
+ - **Shielded swap tools** (NIGHTGATE 0.29.0, `@odatano/nightgate-tx` 0.8.0):
336
+ - `get_swap_wallet`: address, public keys, per token type balance, free coins and
337
+ `spendable`; halves built here that have not landed.
338
+ - `read_swap_offer`: `gives`, `wants`, `inputs`, `outputs`, `bound` of an offer file or
339
+ base64 half, read from the transaction.
340
+ - `build_swap_offer(give, want, bind?)`: one proven half, as offer file (`swapoffer1...`).
341
+ - `take_swap_offer(offer, expect?, sponsorSessionId?, idempotencyKey?)`: the mirror half;
342
+ with a sponsor session it submits both halves. A refusal carries `halfId`.
343
+ - `sponsor_swap(makerHalf, takerHalf | halfId, sponsorSessionId, idempotencyKey?)`.
344
+ - `revert_swap_offer(id)`: releases the coins of a half built here.
345
+ - `NIGHTGATE_SWAP_STATE_FILE`, `NIGHTGATE_SWAP_MAX_INPUTS`.
346
+ - `get_attester_identity` returns `shieldedAddress`, `coinPublicKey`, `encryptionPublicKey`.
347
+ - `npm run integration` covers the swap tools (`scripts/integration-swap.mjs`).
348
+
349
+ ### Changed
350
+
351
+ - Peer dependency `@odatano/nightgate-tx` `>=0.8.0` (was `>=0.6.0`).
352
+ - Lockfile: one `@midnight-ntwrk/ledger-v8` (8.1.0) in the tree. Two copies made the local
353
+ builder fail with `expected instance of DustParameters`.
354
+ - `live:sponsor-unbound` verifies with the attester id.
355
+ - `NIGHTGATE_SEED_HEX` is 128 hex (a 64-byte BIP39 seed); 64 hex is refused at startup.
356
+ - `get_job_status` describes the `swap` result of a swap job.
357
+
358
+ ## [0.8.1] - 2026-09-27
359
+
360
+ ### Changed
361
+
362
+ - `get_job_status` describes `chainSegments` (NIGHTGATE 0.28.0): for a confirmed batch,
363
+ which calls applied. Tool errors carry the server's string `code` (`INVALID_ARGUMENT`, ...).
364
+ - README reorganized; compatibility names the current version only.
365
+
366
+ ## [0.8.0] - 2026-09-23
367
+
368
+ ### Added
369
+
370
+ - **Analytics tools over ODATANO ASTRA** (`analytics_overview`, `analytics_key_figures`,
371
+ `analytics_daily`, `analytics_top_block_producers`, `analytics_metrics`, `analytics_metric`,
372
+ `analytics_series`, `analytics_compare`, `analytics_anomalies`), registered when the host
373
+ serves ASTRA at `ODATANO_ANALYTICS_URL` (default: the gateway's `/odata/v4/astra`). Same key,
374
+ one unit per read, chain pinned to Midnight; `analytics_compare` puts Cardano next to it.
375
+
376
+ ### Changed
377
+
378
+ - **Default gateway host is `https://api.preprod.odatano.dev`** (one host per
379
+ network; `api.odatano.dev` now only redirects there with a 307). Node drops
380
+ the `Authorization` header on a cross-host redirect, so the old default
381
+ would answer 401 for every call: set `ODATANO_ACCESS_URL` explicitly on
382
+ older versions, or upgrade. The missing-key warning fires for any
383
+ `api.<network>.odatano.dev` host.
384
+
385
+ ## [0.7.0] - 2026-09-20
386
+
387
+ ### Changed (breaking)
388
+
389
+ - **One connection env for both ODATANO MCP servers.** `ODATANO_ACCESS_URL`
390
+ (default `https://api.odatano.dev`, the gateway), `ODATANO_ACCESS_KEY`
391
+ (the `oda_…` key, or an `ngat_…` grant / other bearer against a direct
392
+ instance) and `ODATANO_ACCESS_USER` / `ODATANO_ACCESS_PASSWORD` (basic
393
+ auth for a direct instance) replace `NIGHTGATE_BASE_URL`,
394
+ `NIGHTGATE_TOKEN`, `NIGHTGATE_USERNAME` and `NIGHTGATE_PASSWORD`; the old
395
+ names are not read any more. `@odatano/core-mcp` 0.3.0 reads the same
396
+ four, so an `.mcp.json` needs one key for both chains and no URL. The
397
+ other `NIGHTGATE_*` variables (network, seed, indexer, zk-config, proof
398
+ server, timeout, service path) are unchanged.
399
+ - **Gateway error bodies reach the agent.** The ODATANO ACCESS gateway
400
+ answers with `{ error: "<text>", ...detail }`; the client now keeps the
401
+ text as the message and hands the detail (`unitsLeft`, `price`, the
402
+ `topup` hint, `products`, `validUntil`, `retryAfterSeconds` from
403
+ `Retry-After`) through to the tool error, so a 402 says how to top up
404
+ instead of "request failed with HTTP 402".
405
+ - **The hosted API is the documented default.** README: quick start with a
406
+ key from api.odatano.dev first, sponsoring through the gateway's platform
407
+ pool, own instance second; the server warns at startup when the gateway
408
+ is the target and no key is set. Server version constant follows the
409
+ package.
410
+
411
+ ## [0.6.1] - 2026-09-19
412
+
413
+ ### Changed
414
+
415
+ - **The ODATANO ACCESS key (`oda_…`) is the documented credential.**
416
+ `api.nightgate.dev` is the ODATANO ACCESS gateway since 2026-09-18: it
417
+ meters the key in units, swaps in the NIGHTGATE agent grant underneath and
418
+ fronts ODATANO with the same key. Set `NIGHTGATE_BASE_URL=https://api.nightgate.dev`
419
+ and `NIGHTGATE_TOKEN=oda_…`; the key goes as a plain `Authorization: Bearer`.
420
+ Get one at `POST https://api.odatano.dev/keys` (x402), from a giveaway
421
+ code, or by signing in at the console. A raw `ngat_…` agent grant
422
+ (`x-agent-token`) still works against a direct NIGHTGATE instance. No code
423
+ change: the client already sent a prefix-less token as a bearer.
424
+ - `.env.example` and README updated accordingly; this changelog added and
425
+ shipped with the package.
426
+
427
+ ## [0.6.0] - 2026-09
428
+
429
+ ### Changed (breaking)
430
+
431
+ - **Vault lineage 4: every record is keyed by attester AND payload**
432
+ (NIGHTGATE >= 0.24.0). `verify_attestation` takes `attesterId` +
433
+ `payloadHash` (or a bound `documentId`), `verify_predicate` takes
434
+ `attesterId`, the `prove_*` tools accept an optional `attesterId` (the
435
+ record the claim is proven against), `anchor_document` is one plain attest
436
+ and returns `attesterId`.
437
+ - `prepare_anchor_commitment` and `commit_document_anchor` are gone: nothing
438
+ is left to guard, no identity can take over another attester's record.
439
+ - Local building needs `@odatano/nightgate-tx` >= 0.6.0; the proof calls
440
+ take `recordKey` or `payloadHash` (+ `attesterId`). Against a 0.23.x server
441
+ the verify calls fail with 400 (unknown parameter).
442
+
443
+ ## [0.5.1] - 2026-08-23
444
+
445
+ ### Added
446
+
447
+ - **32-slot vault.** Schema and opening take 16 or 32 entries, `allowedMask`
448
+ up to 32 bits, `k` up to 32; the vacuity guard is checked against the
449
+ schema instead of a fixed all-ones constant. Target it with
450
+ `compiledArtifactRef: 'attestation-vault-32'` (NIGHTGATE >= 0.19.0 for
451
+ width 32). A 16-slot setup keeps working against any 0.18.x server.
452
+ - Local ZK claims: field and document proofs can be built in-process.
453
+
454
+ ## [0.5.0] - 2026-08-19
455
+
456
+ ### Added
457
+
458
+ - **Parallel sponsoring channel:** `sponsor_unbound_transaction` with the
459
+ platform pool id (NIGHTGATE >= 0.18.0; 404 against older servers).
460
+ - **Local transaction building** for agents: `build_sponsorable_transaction`
461
+ and `get_attester_identity` via the optional `@odatano/nightgate-tx`
462
+ >= 0.2.0 txbuilder, driven by `NIGHTGATE_SEED_HEX` (never a tool argument).
463
+
464
+ ## [0.3.0] - 2026-08-16
465
+
466
+ ### Added
467
+
468
+ - Cross-root document proofs and guarded anchoring (`prepare_anchor_commitment`
469
+ / `commit_document_anchor`, removed again in 0.6.0).
470
+
471
+ ## [0.2.0] - 2026-08-10
472
+
473
+ ### Added
474
+
475
+ - Membership and equality proof tools; README documents the tool set and the
476
+ server compatibility table.
477
+
478
+ ## [0.1.0] - 2026-08-07
479
+
480
+ ### Added
481
+
482
+ - Initial MCP server: attestation, verification and job tools over the
483
+ NIGHTGATE OData API, agent-grant (`ngat_…`) or basic auth.