@t2000/cli 5.24.2 → 5.25.0

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/dist/index.js CHANGED
@@ -33109,7 +33109,7 @@ function registerMcpStart(parent) {
33109
33109
  parent.command("start", { isDefault: true }).description("Start MCP server (stdio transport \u2014 for AI client integration)").option("--key <path>", "Custom wallet path (default ~/.t2000/wallet.key)").action(async (opts) => {
33110
33110
  let mod3;
33111
33111
  try {
33112
- mod3 = await import("./dist-ZX4DO4GG.js");
33112
+ mod3 = await import("./dist-QE7NG5LG.js");
33113
33113
  } catch {
33114
33114
  console.error("MCP server not installed. Run:\n npm install -g @t2000/mcp");
33115
33115
  process.exit(1);
@@ -33959,6 +33959,11 @@ Subcommands:
33959
33959
  force: opts.force
33960
33960
  });
33961
33961
  const body2 = result.body;
33962
+ if (result.status >= 400) {
33963
+ throw new Error(
33964
+ `${body2?.error ?? `Request failed (HTTP ${result.status})`}${result.paid ? "" : " \u2014 nothing was paid."}`
33965
+ );
33966
+ }
33962
33967
  const receipt = body2?.receipt;
33963
33968
  const chargedMicros = receipt?.chargedMicros ?? receipt?.grossMicros;
33964
33969
  const paidUsd = typeof chargedMicros === "number" ? chargedMicros / 1e6 : opts.amount ? Number.parseFloat(opts.amount) : result.cost ?? 0;