@tinycloud/mcp 0.10.0-beta.31 → 0.10.0-beta.32

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.cjs CHANGED
@@ -555,7 +555,7 @@ function outcomeCode(result) {
555
555
  // package.json
556
556
  var package_default = {
557
557
  name: "@tinycloud/mcp",
558
- version: "0.10.0-beta.31",
558
+ version: "0.10.0-beta.32",
559
559
  description: "TinyCloud delegated operations MCP server",
560
560
  keywords: [
561
561
  "tinycloud",
@@ -626,9 +626,10 @@ var package_default = {
626
626
  dependencies: {
627
627
  "@modelcontextprotocol/node": "2.0.0-beta.5",
628
628
  "@modelcontextprotocol/server": "2.0.0-beta.5",
629
- "@tinycloud/node-sdk": "3.12.0-beta.23",
629
+ "@tinycloud/node-sdk": "3.12.0-beta.24",
630
+ "@tinycloud/sdk-core": "3.12.0-beta.24",
630
631
  "@tinycloud/node-sdk-wasm": "1.7.9-beta.0",
631
- "@tinycloud/operations": "0.9.0-beta.27",
632
+ "@tinycloud/operations": "0.9.0-beta.28",
632
633
  jose: "6.2.4"
633
634
  },
634
635
  devDependencies: {
@@ -1006,6 +1007,7 @@ function claims(token) {
1006
1007
  }
1007
1008
 
1008
1009
  // src/remote-store.ts
1010
+ var import_sdk_core = require("@tinycloud/sdk-core");
1009
1011
  var import_node_crypto3 = require("crypto");
1010
1012
  var import_promises = require("fs/promises");
1011
1013
  var import_node_path3 = require("path");
@@ -1085,7 +1087,7 @@ var NATIVE_GRANT_IMPORT_REJECTION_CODES = /* @__PURE__ */ new Set([
1085
1087
  "DELEGATION_HOST_MISMATCH",
1086
1088
  "DELEGATION_REJECTED"
1087
1089
  ]);
1088
- var LEGACY_DEFAULT_NODE_HOST = "https://node.tinycloud.xyz";
1090
+ var PRODUCTION_NODE_HOSTS = /* @__PURE__ */ new Set(["https://node.tinycloud.xyz", "https://tee.node.tinycloud.xyz"]);
1089
1091
  var BOOTSTRAP_PERMISSIONS = [
1090
1092
  {
1091
1093
  service: "tinycloud.kv",
@@ -1815,10 +1817,10 @@ var RemoteTenantStore = class {
1815
1817
  authMethod: "openkey",
1816
1818
  openkeyHost: this.#config.openkeyHost
1817
1819
  });
1818
- } else if (typeof profile.host === "string" && profile.host.replace(/\/+$/, "") === LEGACY_DEFAULT_NODE_HOST && this.#config.nodeHost.replace(/\/+$/, "") !== LEGACY_DEFAULT_NODE_HOST) {
1820
+ } else if (typeof profile.host === "string" && PRODUCTION_NODE_HOSTS.has(profile.host.replace(/\/+$/, "")) && PRODUCTION_NODE_HOSTS.has(this.#config.nodeHost.replace(/\/+$/, "")) && profile.host.replace(/\/+$/, "") !== this.#config.nodeHost.replace(/\/+$/, "")) {
1819
1821
  await secureWrite(profilePath, { ...profile, host: this.#config.nodeHost });
1820
1822
  process.stderr.write(
1821
- `[tinycloud-mcp-http] tenant node host migrated: from=${LEGACY_DEFAULT_NODE_HOST} to=${new URL(this.#config.nodeHost).origin}
1823
+ `[tinycloud-mcp-http] tenant node host migrated: from=${profile.host.replace(/\/+$/, "")} to=${new URL(this.#config.nodeHost).origin}
1822
1824
  `
1823
1825
  );
1824
1826
  }
@@ -2136,6 +2138,7 @@ function normalizeDid(value) {
2136
2138
  return value.split("#", 1)[0];
2137
2139
  }
2138
2140
  function sameNodeHost(left, right) {
2141
+ if (PRODUCTION_NODE_HOSTS.has(left) && (0, import_sdk_core.sameTinyCloudNode)(left, right)) return true;
2139
2142
  try {
2140
2143
  const normalize = (value) => {
2141
2144
  const url = new URL(value);