@settlemint/sdk-mcp 2.4.0-pr74203735 → 2.4.0-pr7c98613c

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/mcp.js CHANGED
@@ -90400,7 +90400,7 @@ var {
90400
90400
  var package_default = {
90401
90401
  name: "@settlemint/sdk-mcp",
90402
90402
  description: "MCP interface for SettleMint SDK, providing development tools and project management capabilities",
90403
- version: "2.4.0-pr74203735",
90403
+ version: "2.4.0-pr7c98613c",
90404
90404
  type: "module",
90405
90405
  private: false,
90406
90406
  license: "FSL-1.1-MIT",
@@ -90444,8 +90444,8 @@ var package_default = {
90444
90444
  "@graphql-tools/load": "8.1.0",
90445
90445
  "@graphql-tools/url-loader": "8.0.31",
90446
90446
  "@modelcontextprotocol/sdk": "1.13.3",
90447
- "@settlemint/sdk-js": "2.4.0-pr74203735",
90448
- "@settlemint/sdk-utils": "2.4.0-pr74203735",
90447
+ "@settlemint/sdk-js": "2.4.0-pr7c98613c",
90448
+ "@settlemint/sdk-utils": "2.4.0-pr7c98613c",
90449
90449
  "@commander-js/extra-typings": "14.0.0",
90450
90450
  commander: "14.0.0",
90451
90451
  zod: "^3.25.0"
@@ -103570,8 +103570,9 @@ var workspaceList = (gqlClient) => {
103570
103570
  const { workspaces } = await gqlClient.request(getWorkspacesAndApplications);
103571
103571
  const allWorkspaces = workspaces.reduce((acc, workspace) => {
103572
103572
  acc.push(workspace);
103573
- if (workspace.childWorkspaces)
103573
+ if (workspace.childWorkspaces) {
103574
103574
  acc.push(...workspace.childWorkspaces);
103575
+ }
103575
103576
  return acc;
103576
103577
  }, []);
103577
103578
  return allWorkspaces.sort((a3, b) => a3.name.localeCompare(b.name));
@@ -103598,8 +103599,9 @@ var workspaceDelete = (gqlClient) => {
103598
103599
  var workspaceAddCredits = (gqlClient) => {
103599
103600
  return async (workspaceId, amount) => {
103600
103601
  const id = validate3(IdSchema2, workspaceId);
103601
- if (amount <= 0)
103602
+ if (amount <= 0) {
103602
103603
  throw new Error("Credit amount must be a positive number");
103604
+ }
103603
103605
  const { addCredits: result } = await gqlClient.request(addCredits, {
103604
103606
  workspaceId: id,
103605
103607
  amount
@@ -103721,8 +103723,9 @@ var applicationAccessTokenCreate = (gqlClient) => {
103721
103723
  ...otherArgs,
103722
103724
  applicationId: application.id
103723
103725
  });
103724
- if (!applicationAccessToken.token)
103726
+ if (!applicationAccessToken.token) {
103725
103727
  throw new Error("Failed to create application access token");
103728
+ }
103726
103729
  return applicationAccessToken.token;
103727
103730
  };
103728
103731
  };
@@ -103735,7 +103738,7 @@ function setClusterServiceDefaults(args) {
103735
103738
  }
103736
103739
  function setNetworkDefaults(args) {
103737
103740
  const clusterServiceArgs = setClusterServiceDefaults(args);
103738
- if (args.consensusAlgorithm === "BESU_QBFT")
103741
+ if (args.consensusAlgorithm === "BESU_QBFT") {
103739
103742
  return {
103740
103743
  ...clusterServiceArgs,
103741
103744
  chainId: args.chainId ?? 46040,
@@ -103745,6 +103748,7 @@ function setNetworkDefaults(args) {
103745
103748
  gasPrice: args.gasPrice ?? 0,
103746
103749
  secondsPerBlock: args.secondsPerBlock ?? 2
103747
103750
  };
103751
+ }
103748
103752
  return clusterServiceArgs;
103749
103753
  }
103750
103754
  var BlockchainNetworkFragment = graphql(`
@@ -105159,26 +105163,30 @@ async function getPincodeVerificationChallenges({ userWalletAddress, accessToken
105159
105163
  }
105160
105164
  });
105161
105165
  if (!response.ok) {
105162
- if (response.status === 404)
105166
+ if (response.status === 404) {
105163
105167
  throw new Error(`No user wallet found with address '${userWalletAddress}' for node '${nodeId}'`);
105168
+ }
105164
105169
  throw new Error("Failed to get verification challenge");
105165
105170
  }
105166
105171
  const verificationChallenges = await response.json();
105167
105172
  return verificationChallenges;
105168
105173
  }
105169
105174
  function getPincodeVerificationChallengeResponse({ verificationChallenge, pincode }) {
105170
- if (!verificationChallenge?.challenge?.secret || !verificationChallenge?.challenge?.salt)
105175
+ if (!verificationChallenge?.challenge?.secret || !verificationChallenge?.challenge?.salt) {
105171
105176
  throw new Error("Could not authenticate pin code, invalid challenge format");
105177
+ }
105172
105178
  const { secret, salt } = verificationChallenge.challenge;
105173
105179
  return generateResponse(pincode, salt, secret);
105174
105180
  }
105175
105181
  function createSettleMintClient(options) {
105176
105182
  ensureServer();
105177
- if (options.instance === STANDALONE_INSTANCE2 || options.instance === LOCAL_INSTANCE2)
105178
- if (options.anonymous)
105183
+ if (options.instance === STANDALONE_INSTANCE2 || options.instance === LOCAL_INSTANCE2) {
105184
+ if (options.anonymous) {
105179
105185
  options.instance = "https://console.settlemint.com";
105180
- else
105186
+ } else {
105181
105187
  throw new Error("Standalone and local instances cannot connect to the SettleMint platform");
105188
+ }
105189
+ }
105182
105190
  const validatedOptions = options.anonymous ? validate3(exports_external2.object({
105183
105191
  ...ClientOptionsSchema.shape,
105184
105192
  accessToken: exports_external2.literal("")
@@ -107110,4 +107118,4 @@ await main().catch((error41) => {
107110
107118
  process.exit(1);
107111
107119
  });
107112
107120
 
107113
- //# debugId=FEF44927DF9E207064756E2164756E21
107121
+ //# debugId=A8C8B6BCBC7FC17E64756E2164756E21