@indigoprotocol/indigo-mcp 0.4.2 → 0.5.1

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
@@ -1,6 +1,5 @@
1
1
  # Indigo MCP
2
2
 
3
- [![Smithery](https://smithery.ai/badge/@indigoprotocol/indigo-mcp)](https://smithery.ai/server/@indigoprotocol/indigo-mcp)
4
3
  [![npm downloads](https://img.shields.io/npm/dm/@indigoprotocol/indigo-mcp)](https://www.npmjs.com/package/@indigoprotocol/indigo-mcp)
5
4
  [![Ask DeepWiki](https://deepwiki.com/badge.svg)](https://deepwiki.com/IndigoProtocol/indigo-mcp)
6
5
 
@@ -486,10 +485,16 @@ For any client that supports MCP over stdio, point it to the `npx @indigoprotoco
486
485
 
487
486
  | Tool | Description | Parameters |
488
487
  | ------------------------ | ------------------------------------------------------------ | ------------------------------------------- |
489
- | `get_stableswap_pool` | Get the stableswap pool state for an (iAsset, collateral) | `asset` |
490
- | `create_stableswap_order`| Build a tx to swap collateral↔iAsset via the stableswap pool | `address`, `asset`, `amount`, `minting` |
488
+ | `get_stableswap_pool` | Get the stableswap pool state for an (iAsset, collateral) | `asset`, `collateralAsset?` |
489
+ | `create_stableswap_order`| Build a tx to swap collateral↔iAsset via the stableswap pool | `address`, `asset`, `amount`, `minting`, `collateralAsset?` |
491
490
  | `cancel_stableswap_order`| Build a tx to cancel a stableswap order | `address`, `orderTxHash`, `orderOutputIndex`|
492
491
 
492
+ A stableswap pool is identified by its iAsset and its collateral, which is a stablecoin
493
+ rather than ADA. `collateralAsset` takes the token name (`USDA`, `USDM`, …) or
494
+ `<policyId>.<assetNameHex>`. It can be left out when the iAsset has a single pool; when it
495
+ has several, the error lists the choices. `get_stableswap_pool` also reports whether minting
496
+ and redemption are enabled and the minimum order amounts.
497
+
493
498
  ## Environment Variables
494
499
 
495
500
  | Variable | Required | Default | Description |
@@ -528,32 +533,84 @@ When connected to an LLM agent, you can ask natural language questions like:
528
533
 
529
534
  ## Distribution
530
535
 
531
- The server is published to three places, and they are not the same artifact.
536
+ The server is published to two places, and they are not the same artifact.
532
537
 
533
538
  | Target | Built by | Output | Published by |
534
539
  |---|---|---|---|
535
- | npm — `@indigoprotocol/indigo-mcp` | `scripts/build.sh` | `dist/` | CI, on a `v*` tag |
540
+ | npm — `@indigoprotocol/indigo-mcp` | `scripts/build.sh` | `dist/` | CI, on a `v*` tag (npm trusted publishing, GitHub OIDC — no token) |
536
541
  | [MCP Registry](https://registry.modelcontextprotocol.io) — `io.github.IndigoProtocol/indigo-mcp` | `server.json` | metadata only | CI, on a `v*` tag (GitHub OIDC — no token) |
537
- | [Smithery](https://smithery.ai/server/@indigoprotocol/indigo-mcp) | `scripts/smithery-build.sh` | `.smithery/stdio/server.mcpb` | `pnpm smithery:publish`, manually |
538
542
 
539
- The container image (`Dockerfile`) builds from source and is used by Fly and any
540
- other container host. It does **not** consume `.smithery/` output — that path is
541
- Smithery-specific.
543
+ The npm publish uses no stored secret. The package's trusted publisher is set on
544
+ npmjs.com (package Settings, Trusted publishing, GitHub Actions) to organization
545
+ `IndigoProtocol`, repository `indigo-mcp`, workflow `ci.yml`, no environment, with
546
+ `npm publish` allowed. If a tag's publish job fails with an authentication error,
547
+ check that configuration first.
548
+
549
+ The container image (`Dockerfile`) builds from source with the same
550
+ `scripts/build.sh` and is used by Fly and any other container host.
551
+
552
+ The bundle leaves `undici`, `libsodium-sumo` and `libsodium-wrappers-sumo`
553
+ external, so they must stay in `dependencies`: without them neither the npm
554
+ package nor the container image can start.
542
555
 
543
556
  ### Cutting a release
544
557
 
545
- 1. Merge the version bump (`package.json`; `SERVER_VERSION` is read from it)
546
- 2. `git tag vX.Y.Z && git push origin vX.Y.Z`
547
- 3. CI publishes to npm, then to the MCP Registry (the registry verifies ownership
558
+ **Test from an up-to-date `main` before bumping the version.**
559
+
560
+ 1. Install and run every check:
561
+
562
+ ```bash
563
+ pnpm install --frozen-lockfile --ignore-scripts
564
+ pnpm typecheck && pnpm lint && pnpm format:check && pnpm test && pnpm build
565
+ ```
566
+
567
+ 2. Start the packed tarball from an empty folder. CI builds the bundle but never
568
+ starts it, so this is the only check that catches a missing runtime dependency
569
+ or a WASM file copied from the wrong package. Running `node dist/index.js`
570
+ inside the repo is not enough: the repo's `node_modules` hides both problems.
571
+
572
+ ```bash
573
+ npm pack
574
+ mkdir /tmp/indigo-smoke && cd /tmp/indigo-smoke && npm init -y
575
+ npm install /path/to/indigoprotocol-indigo-mcp-X.Y.Z.tgz
576
+ echo '{"jsonrpc":"2.0","id":1,"method":"initialize","params":{"protocolVersion":"2024-11-05","capabilities":{},"clientInfo":{"name":"smoke","version":"0"}}}' \
577
+ | node node_modules/@indigoprotocol/indigo-mcp/dist/index.js
578
+ ```
579
+
580
+ It must print an `initialize` result, not a stack trace.
581
+
582
+ 3. With `BLOCKFROST_API_KEY` set, build one transaction per write-tool family
583
+ against mainnet (`open_cdp` for each iAsset, then one each of the mint,
584
+ stability pool, staking, ROB, stableswap and leverage tools). The tools return
585
+ unsigned CBOR, so nothing is submitted. Do this whenever the SDK, lucid or the
586
+ system params URL changed.
587
+
588
+ 4. If the `Dockerfile` or the dependencies changed, check the image Fly will build:
589
+
590
+ ```bash
591
+ docker build -t indigo-mcp:rc . && docker run --rm -p 3000:3000 indigo-mcp:rc
592
+ curl -s localhost:3000/health
593
+ ```
594
+
595
+ **Release.**
596
+
597
+ 5. Merge the version bump: `version` in `package.json` (`SERVER_VERSION` is read
598
+ from it) and both `version` fields in `server.json`
599
+ 6. Tag the merge commit on `main`: `git tag vX.Y.Z && git push origin vX.Y.Z`
600
+ 7. CI publishes to npm, then to the MCP Registry (the registry verifies ownership
548
601
  via the package's `mcpName` field, so npm has to go first)
549
- 4. Verify against the registry, not the workflow: `npm view @indigoprotocol/indigo-mcp version`
550
- 5. `fly deploy` for the hosted HTTP endpoint, and `pnpm smithery:publish` for Smithery
602
+ 8. Verify against the registry, not the workflow:
603
+ `npm view @indigoprotocol/indigo-mcp version`, then repeat step 2 installing
604
+ `@indigoprotocol/indigo-mcp@X.Y.Z` from npm instead of the tarball
605
+ 9. `fly deploy` for the hosted HTTP endpoint, then confirm
606
+ `curl -s https://indigo-mcp.fly.dev/health` reports the new version
607
+ 10. `gh release create vX.Y.Z --generate-notes`
551
608
 
552
609
  ## Development
553
610
 
554
611
  ### Prerequisites
555
612
 
556
- - Node.js >= 20 (the bundled `undici` requires the `File` global, added in Node 20)
613
+ - Node.js >= 22.23.4 (the Brotli decoder fix for CVE-2026-111497; the server refuses to start on older runtimes)
557
614
  - npm
558
615
 
559
616
  ### Setup