@settlemint/sdk-cli 2.1.4-prc778834d → 2.1.4-prcd260cdb

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.
Files changed (3) hide show
  1. package/dist/cli.js +112 -60
  2. package/dist/cli.js.map +26 -25
  3. package/package.json +3 -3
package/dist/cli.js CHANGED
@@ -245340,7 +245340,7 @@ function pruneCurrentEnv(currentEnv, env2) {
245340
245340
  var package_default = {
245341
245341
  name: "@settlemint/sdk-cli",
245342
245342
  description: "Command-line interface for SettleMint SDK, providing development tools and project management capabilities",
245343
- version: "2.1.4-prc778834d",
245343
+ version: "2.1.4-prcd260cdb",
245344
245344
  type: "module",
245345
245345
  private: false,
245346
245346
  license: "FSL-1.1-MIT",
@@ -245389,8 +245389,8 @@ var package_default = {
245389
245389
  "@inquirer/input": "4.1.9",
245390
245390
  "@inquirer/password": "4.0.12",
245391
245391
  "@inquirer/select": "4.1.1",
245392
- "@settlemint/sdk-js": "2.1.4-prc778834d",
245393
- "@settlemint/sdk-utils": "2.1.4-prc778834d",
245392
+ "@settlemint/sdk-js": "2.1.4-prcd260cdb",
245393
+ "@settlemint/sdk-utils": "2.1.4-prcd260cdb",
245394
245394
  "@types/node": "22.14.1",
245395
245395
  "@types/semver": "7.7.0",
245396
245396
  "@types/which": "3.0.4",
@@ -246548,13 +246548,21 @@ class Separator {
246548
246548
  // ../utils/dist/terminal.mjs
246549
246549
  import { spawn } from "node:child_process";
246550
246550
  var import_console_table_printer2 = __toESM(require_dist2(), 1);
246551
- var ascii = () => console.log(magentaBright(`
246551
+ function shouldPrint() {
246552
+ return process.env.SETTLEMINT_DISABLE_TERMINAL !== "true";
246553
+ }
246554
+ var ascii = () => {
246555
+ if (!shouldPrint()) {
246556
+ return;
246557
+ }
246558
+ console.log(magentaBright(`
246552
246559
  _________ __ __ .__ _____ .__ __
246553
246560
  / _____/ _____/ |__/ |_| | ____ / \\ |__| _____/ |_
246554
246561
  \\_____ \\_/ __ \\ __\\ __\\ | _/ __ \\ / \\ / \\| |/ \\ __\\
246555
246562
  / \\ ___/| | | | | |_\\ ___// Y \\ | | \\ |
246556
246563
  /_________/\\_____>__| |__| |____/\\_____>____|____/__|___|__/__|
246557
246564
  `));
246565
+ };
246558
246566
  var maskTokens2 = (output) => {
246559
246567
  return output.replace(/sm_(pat|aat|sat)_[0-9a-zA-Z]+/g, "***");
246560
246568
  };
@@ -246604,11 +246612,17 @@ async function executeCommand(command, args, options) {
246604
246612
  });
246605
246613
  }
246606
246614
  var intro = (msg) => {
246615
+ if (!shouldPrint()) {
246616
+ return;
246617
+ }
246607
246618
  console.log("");
246608
246619
  console.log(magentaBright(maskTokens2(msg)));
246609
246620
  console.log("");
246610
246621
  };
246611
246622
  var note = (message, level = "info") => {
246623
+ if (!shouldPrint()) {
246624
+ return;
246625
+ }
246612
246626
  const maskedMessage = maskTokens2(message);
246613
246627
  console.log("");
246614
246628
  if (level === "warn") {
@@ -246633,6 +246647,9 @@ function list(title, items) {
246633
246647
  ${formatItems(items)}`);
246634
246648
  }
246635
246649
  var outro = (msg) => {
246650
+ if (!shouldPrint()) {
246651
+ return;
246652
+ }
246636
246653
  console.log("");
246637
246654
  console.log(inverse(greenBright(maskTokens2(msg))));
246638
246655
  console.log("");
@@ -246652,7 +246669,7 @@ var spinner = async (options) => {
246652
246669
  ${error.stack}`));
246653
246670
  throw new SpinnerError(errorMessage, error);
246654
246671
  };
246655
- if (is_in_ci_default) {
246672
+ if (is_in_ci_default || !shouldPrint()) {
246656
246673
  try {
246657
246674
  return await options.task();
246658
246675
  } catch (err) {
@@ -246680,6 +246697,9 @@ function camelCaseToWords(s) {
246680
246697
  return capitalized.replace(/\s+/g, " ").trim();
246681
246698
  }
246682
246699
  function table(title, data) {
246700
+ if (!shouldPrint()) {
246701
+ return;
246702
+ }
246683
246703
  note(title);
246684
246704
  if (!data || data.length === 0) {
246685
246705
  note("No data to display");
@@ -248210,6 +248230,7 @@ var getEnv = (gqlClient) => {
248210
248230
  };
248211
248231
  var LoadBalancerFragment = graphql(`
248212
248232
  fragment LoadBalancer on LoadBalancer {
248233
+ __typename
248213
248234
  id
248214
248235
  uniqueName
248215
248236
  name
@@ -250037,10 +250058,16 @@ async function getPackageManagerExecutable(targetDir) {
250037
250058
  }
250038
250059
  return { command: "npx", args: [] };
250039
250060
  }
250061
+ function shouldPrint2() {
250062
+ return process.env.SETTLEMINT_DISABLE_TERMINAL !== "true";
250063
+ }
250040
250064
  var maskTokens3 = (output) => {
250041
250065
  return output.replace(/sm_(pat|aat|sat)_[0-9a-zA-Z]+/g, "***");
250042
250066
  };
250043
250067
  var note2 = (message, level = "info") => {
250068
+ if (!shouldPrint2()) {
250069
+ return;
250070
+ }
250044
250071
  const maskedMessage = maskTokens3(message);
250045
250072
  console.log("");
250046
250073
  if (level === "warn") {
@@ -250093,6 +250120,9 @@ function tryParseJson3(value2, defaultValue = null) {
250093
250120
  }
250094
250121
  }
250095
250122
  function extractJsonObject(value2) {
250123
+ if (value2.length > 5000) {
250124
+ throw new Error("Input too long");
250125
+ }
250096
250126
  const result = /\{([\s\S]*)\}/.exec(value2);
250097
250127
  if (!result) {
250098
250128
  return null;
@@ -251600,6 +251630,9 @@ async function codegenTsconfig(env2, thegraphSubgraphNames) {
251600
251630
  };
251601
251631
  }
251602
251632
 
251633
+ // src/constants/default-subgraph.ts
251634
+ var DEFAULT_SUBGRAPH_NAME = "kit";
251635
+
251603
251636
  // src/utils/subgraph/sanitize-name.ts
251604
251637
  var import_slugify = __toESM(require_slugify(), 1);
251605
251638
  function sanitizeName(value4, length = 35) {
@@ -251862,7 +251895,13 @@ async function subgraphPrompt({
251862
251895
  if (env2.SETTLEMINT_THEGRAPH_DEFAULT_SUBGRAPH) {
251863
251896
  return [env2.SETTLEMINT_THEGRAPH_DEFAULT_SUBGRAPH];
251864
251897
  }
251865
- return subgraphNames.length === 1 ? subgraphNames : [];
251898
+ if (subgraphNames.length === 1) {
251899
+ return subgraphNames;
251900
+ }
251901
+ if (subgraphNames.includes(DEFAULT_SUBGRAPH_NAME)) {
251902
+ return [DEFAULT_SUBGRAPH_NAME];
251903
+ }
251904
+ return [];
251866
251905
  }
251867
251906
  if (!allowNew) {
251868
251907
  if (subgraphNames.length === 0) {
@@ -252815,7 +252854,7 @@ async function theGraphPrompt({
252815
252854
  envKey: "SETTLEMINT_THEGRAPH",
252816
252855
  isRequired,
252817
252856
  defaultHandler: async ({ defaultService: defaultMiddleware, choices }) => {
252818
- const filteredChoices = filterRunningOnly ? choices.filter(({ value: middleware }) => middleware === undefined || middleware?.status === "COMPLETED") : choices;
252857
+ const filteredChoices = filterRunningOnly ? choices.filter(({ value: middleware }) => isRunning(middleware)) : choices;
252819
252858
  return esm_default3({
252820
252859
  message: "Which The Graph instance do you want to connect to?",
252821
252860
  choices: filteredChoices,
@@ -253055,8 +253094,10 @@ async function getGraphEndpoint(settlemint, service, graphName) {
253055
253094
  })
253056
253095
  });
253057
253096
  const endpoints = theGraphMiddleware.subgraphs.map(({ graphqlQueryEndpoint }) => graphqlQueryEndpoint?.displayValue);
253097
+ const hasKitSubgraph = endpoints.map((endpoint) => endpoint.split("/").pop()).some((endpoint) => endpoint === DEFAULT_SUBGRAPH_NAME);
253058
253098
  return {
253059
- SETTLEMINT_THEGRAPH_SUBGRAPHS_ENDPOINTS: endpoints
253099
+ SETTLEMINT_THEGRAPH_SUBGRAPHS_ENDPOINTS: endpoints,
253100
+ SETTLEMINT_THEGRAPH_DEFAULT_SUBGRAPH: hasKitSubgraph ? DEFAULT_SUBGRAPH_NAME : undefined
253060
253101
  };
253061
253102
  }
253062
253103
  function getIpfsEndpoints(service) {
@@ -253143,7 +253184,7 @@ async function blockchainNodeOrLoadBalancerPrompt({
253143
253184
  envKey: "SETTLEMINT_BLOCKCHAIN_NODE_OR_LOAD_BALANCER",
253144
253185
  isRequired,
253145
253186
  defaultHandler: async ({ defaultService: defaultNode, choices }) => {
253146
- const filteredChoices = filterRunningOnly ? choices.filter(({ value: node }) => node === undefined || node?.status === "COMPLETED") : choices;
253187
+ const filteredChoices = filterRunningOnly ? choices.filter(({ value: node }) => isRunning(node)) : choices;
253147
253188
  return esm_default3({
253148
253189
  message: promptMessage ?? "Which blockchain node or load balancer do you want to connect to?",
253149
253190
  choices: filteredChoices,
@@ -253213,7 +253254,7 @@ function connectCommand() {
253213
253254
  env: { ...env2, ...graphEndpoints },
253214
253255
  accept: acceptDefaults,
253215
253256
  message: "Which The Graph subgraph do you want to use as the default?"
253216
- }) : [];
253257
+ }) : [graphEndpoints.SETTLEMINT_THEGRAPH_DEFAULT_SUBGRAPH];
253217
253258
  const portal = await portalPrompt({
253218
253259
  env: env2,
253219
253260
  middlewares,
@@ -257237,13 +257278,16 @@ function getCreateCommand({
257237
257278
  region: selectedRegion?.id ?? ""
257238
257279
  });
257239
257280
  if (wait) {
257240
- await waitForCompletion({
257281
+ const isDeployed = await waitForCompletion({
257241
257282
  settlemint,
257242
257283
  type: waitFor?.resourceType ?? type4,
257243
257284
  uniqueName: waitFor?.uniqueName ?? result.uniqueName,
257244
257285
  action: "deploy",
257245
257286
  restartIfTimeout
257246
257287
  });
257288
+ if (!isDeployed) {
257289
+ throw new Error(`Failed to deploy ${waitFor?.resourceType ?? type4} ${waitFor?.uniqueName ?? result.uniqueName}`);
257290
+ }
257247
257291
  if (waitFor) {
257248
257292
  outro(`${capitalizeFirstLetter2(waitFor.resourceType)} ${waitFor.name} created successfully`);
257249
257293
  }
@@ -257788,22 +257832,26 @@ function blockscoutInsightsCreateCommand() {
257788
257832
  if (!applicationUniqueName) {
257789
257833
  return missingApplication();
257790
257834
  }
257791
- let blockchainNodeUniqueName = loadBalancer ? undefined : blockchainNode ?? env2.SETTLEMINT_BLOCKCHAIN_NODE;
257792
- const loadBalancerUniqueName = blockchainNodeUniqueName ? undefined : loadBalancer ?? env2.SETTLEMINT_BLOCKCHAIN_NODE_OR_LOAD_BALANCER;
257835
+ let blockchainNodeUniqueName = blockchainNode;
257836
+ let loadBalancerUniqueName = loadBalancer;
257793
257837
  if (!blockchainNodeUniqueName && !loadBalancerUniqueName) {
257794
257838
  const blockchainNodes = await serviceSpinner("blockchain node", () => settlemint.blockchainNode.list(applicationUniqueName));
257795
257839
  const loadBalancers = await serviceSpinner("load balancer", () => settlemint.loadBalancer.list(applicationUniqueName));
257796
- const node = await blockchainNodeOrLoadBalancerPrompt({
257840
+ const nodeOrLoadbalancer = await blockchainNodeOrLoadBalancerPrompt({
257797
257841
  env: env2,
257798
257842
  nodes: blockchainNodes,
257799
257843
  loadBalancers,
257800
257844
  accept: acceptDefaults,
257801
257845
  isRequired: true
257802
257846
  });
257803
- if (!node) {
257847
+ if (!nodeOrLoadbalancer) {
257804
257848
  return nothingSelectedError("blockchain node");
257805
257849
  }
257806
- blockchainNodeUniqueName = node.uniqueName;
257850
+ if (nodeOrLoadbalancer.__typename?.endsWith("LoadBalancer")) {
257851
+ loadBalancerUniqueName = nodeOrLoadbalancer.uniqueName;
257852
+ } else {
257853
+ blockchainNodeUniqueName = nodeOrLoadbalancer.uniqueName;
257854
+ }
257807
257855
  }
257808
257856
  const result = await showSpinner(() => settlemint.insights.create({
257809
257857
  name: name3,
@@ -257916,7 +257964,7 @@ function loadBalancerEvmCreateCommand() {
257916
257964
  type: "load balancer",
257917
257965
  subType: "EVM",
257918
257966
  execute: (cmd2, baseAction) => {
257919
- addClusterServiceArgs(cmd2).option("--app, --application <application>", "The application unique name to create the load balancer in (defaults to application from env)").option("--blockchain-nodes <blockchainNodes...>", "Blockchain node unique names where the load balancer connects to (must be from the same network)").option("--blockchain-network <blockchainNetwork>", "Blockchain network unique name where the load balancer connects to").action(async (name3, {
257967
+ addClusterServiceArgs(cmd2).option("--app, --application <application>", "The application unique name to create the load balancer in (defaults to application from env)").option("--blockchain-nodes <blockchainNodes...>", "Blockchain node unique names where the load balancer connects to (must be from the same network)").option("--blockchain-network <blockchainNetwork>", "Blockchain network unique name where the load balancer connects to, can be skipped if the --blockchain-nodes option is used (defaults to network from env)").action(async (name3, {
257920
257968
  application,
257921
257969
  provider,
257922
257970
  region,
@@ -257990,7 +258038,8 @@ function loadBalancerEvmCreateCommand() {
257990
258038
  mapDefaultEnv: () => {
257991
258039
  return {
257992
258040
  SETTLEMINT_APPLICATION: applicationUniqueName,
257993
- SETTLEMINT_BLOCKCHAIN_NODE_OR_LOAD_BALANCER: result.uniqueName
258041
+ SETTLEMINT_BLOCKCHAIN_NODE_OR_LOAD_BALANCER: result.uniqueName,
258042
+ ...getBlockchainNodeOrLoadBalancerEndpoints(result)
257994
258043
  };
257995
258044
  }
257996
258045
  };
@@ -258682,7 +258731,15 @@ function getRestartCommand({
258682
258731
  stopMessage: `${capitalizeFirstLetter2(type4)} restart initiated`
258683
258732
  });
258684
258733
  if (wait) {
258685
- await waitForCompletion({ settlemint, type: type4, uniqueName: serviceUniqueName, action: "restart" });
258734
+ const isRestarted = await waitForCompletion({
258735
+ settlemint,
258736
+ type: type4,
258737
+ uniqueName: serviceUniqueName,
258738
+ action: "restart"
258739
+ });
258740
+ if (!isRestarted) {
258741
+ throw new Error(`Failed to restart ${type4} ${uniqueName}`);
258742
+ }
258686
258743
  }
258687
258744
  outro(`${capitalizeFirstLetter2(type4)} ${result.name} restart initiated successfully`);
258688
258745
  });
@@ -258938,10 +258995,7 @@ function yamlOutput(data) {
258938
258995
  // src/commands/platform/config.ts
258939
258996
  function configCommand() {
258940
258997
  return new Command("config").alias("cfg").description("Get platform configuration").option("--prod", "Connect to your production environment").option("-i, --instance <instance>", "The instance to connect to (defaults to the instance in the .env file)").addOption(new Option("-o, --output <output>", "The output format").choices(["json", "yaml"])).action(async ({ prod, instance, output }) => {
258941
- const printToTerminal = !output;
258942
- if (printToTerminal) {
258943
- intro("Getting platform configuration");
258944
- }
258998
+ intro("Getting platform configuration");
258945
258999
  const env2 = await loadEnv(false, !!prod);
258946
259000
  const selectedInstance = instance ? sanitizeAndValidateInstanceUrl(instance) : await instancePrompt(env2, true);
258947
259001
  const settlemint = createSettleMintClient({
@@ -258971,19 +259025,17 @@ function configCommand() {
258971
259025
  }))).sort((a8, b4) => a8.providerId.localeCompare(b4.providerId) || a8.regionId.localeCompare(b4.regionId)),
258972
259026
  preDeployedContracts: platformConfig.preDeployedContracts.sort()
258973
259027
  };
258974
- if (printToTerminal) {
259028
+ if (output === "json") {
259029
+ jsonOutput(platformConfigData);
259030
+ } else if (output === "yaml") {
259031
+ yamlOutput(platformConfigData);
259032
+ } else {
258975
259033
  table("Templates (Kits)", platformConfigData.kits);
258976
259034
  table("Use cases (Smart Contract Sets)", platformConfigData.useCases);
258977
259035
  table("Providers and regions", platformConfigData.deploymentEngineTargets);
258978
259036
  list("Pre-deployed abis (Smart Contract Portal)", platformConfigData.preDeployedContracts);
258979
- } else if (output === "json") {
258980
- jsonOutput(platformConfigData);
258981
- } else if (output === "yaml") {
258982
- yamlOutput(platformConfigData);
258983
- }
258984
- if (printToTerminal) {
258985
- outro("Platform configuration retrieved");
258986
259037
  }
259038
+ outro("Platform configuration retrieved");
258987
259039
  });
258988
259040
  }
258989
259041
 
@@ -259030,6 +259082,9 @@ function getUrlPathForService(service, serviceType) {
259030
259082
  if (serviceType === "insights") {
259031
259083
  return `insights/${encodeURIComponent(service.id)}/details`;
259032
259084
  }
259085
+ if (serviceType === "load-balancer") {
259086
+ return `loadbalancers/${encodeURIComponent(service.id)}/details`;
259087
+ }
259033
259088
  return "";
259034
259089
  }
259035
259090
  function getWorkspaceUrlPath(workspace) {
@@ -259059,10 +259114,7 @@ function applicationsListCommand() {
259059
259114
  command: "platform list applications -o yaml > applications.yaml"
259060
259115
  }
259061
259116
  ])).option("-w, --workspace <workspace>", "The workspace unique name to list applications for (defaults to workspace from env)").addOption(new Option("-o, --output <output>", "The output format").choices(["wide", "json", "yaml"])).action(async ({ workspace, output }) => {
259062
- const printToTerminal = !output || output === "wide";
259063
- if (printToTerminal) {
259064
- intro("Listing applications");
259065
- }
259117
+ intro("Listing applications");
259066
259118
  const env2 = await loadEnv(false, false);
259067
259119
  const selectedInstance = await instancePrompt(env2, true);
259068
259120
  const personalAccessToken = await getInstanceCredentials(selectedInstance);
@@ -259075,13 +259127,12 @@ function applicationsListCommand() {
259075
259127
  });
259076
259128
  const workspaceUniqueName = workspace ?? env2.SETTLEMINT_WORKSPACE ?? await selectWorkspace(settlemint, env2);
259077
259129
  const applications = await applicationsSpinner(settlemint, workspaceUniqueName);
259078
- const wide = output === "wide";
259079
259130
  const applicationsData = applications.map((application) => {
259080
259131
  const basicFields = {
259081
259132
  name: application.name,
259082
259133
  uniqueName: application.uniqueName
259083
259134
  };
259084
- if (wide || !printToTerminal) {
259135
+ if (output) {
259085
259136
  return {
259086
259137
  ...basicFields,
259087
259138
  url: getApplicationUrl(selectedInstance, application)
@@ -259089,17 +259140,15 @@ function applicationsListCommand() {
259089
259140
  }
259090
259141
  return basicFields;
259091
259142
  });
259092
- if (printToTerminal) {
259093
- const selectedWorkspace = await settlemint.workspace.read(workspaceUniqueName);
259094
- table(`Applications for workspace ${selectedWorkspace.name} (${selectedWorkspace.uniqueName}) - ${getWorkspaceUrl(selectedInstance, selectedWorkspace)}`, applicationsData);
259095
- } else if (output === "json") {
259143
+ const selectedWorkspace = await settlemint.workspace.read(workspaceUniqueName);
259144
+ if (output === "json") {
259096
259145
  jsonOutput(applicationsData);
259097
259146
  } else if (output === "yaml") {
259098
259147
  yamlOutput(applicationsData);
259148
+ } else {
259149
+ table(`Applications for workspace ${selectedWorkspace.name} (${selectedWorkspace.uniqueName}) - ${getWorkspaceUrl(selectedInstance, selectedWorkspace)}`, applicationsData);
259099
259150
  }
259100
- if (printToTerminal) {
259101
- outro("Applications listed");
259102
- }
259151
+ outro("Applications listed");
259103
259152
  });
259104
259153
  }
259105
259154
  async function selectWorkspace(settlemint, env2) {
@@ -259113,7 +259162,7 @@ function formatServiceSubType(service, printToTerminal = true) {
259113
259162
  if ("__typename" in service && typeof service.__typename === "string") {
259114
259163
  return printToTerminal ? camelCaseToWords2(service.__typename) : service.__typename;
259115
259164
  }
259116
- return printToTerminal ? "Unknown" : "Unknown";
259165
+ return "Unknown";
259117
259166
  }
259118
259167
 
259119
259168
  // src/commands/platform/utils/formatting/format-health-status.ts
@@ -259144,6 +259193,7 @@ function formatStatus(status, printToTerminal = true) {
259144
259193
  var SERVICE_TYPES = [
259145
259194
  "blockchain-network",
259146
259195
  "blockchain-node",
259196
+ "load-balancer",
259147
259197
  "custom-deployment",
259148
259198
  "insights",
259149
259199
  "integration-tool",
@@ -259182,10 +259232,7 @@ function servicesCommand() {
259182
259232
  command: "platform list services --type blockchain-network blockchain-node middleware"
259183
259233
  }
259184
259234
  ])).option("--app, --application <application>", "The application unique name to list the services in (defaults to application from env)").addOption(new Option("-t, --type <type...>", "The type(s) of service to list").choices(SERVICE_TYPES)).addOption(new Option("-o, --output <output>", "The output format").choices(["wide", "json", "yaml"])).action(async ({ application, type: type4, output }) => {
259185
- const printToTerminal = !output || output === "wide";
259186
- if (printToTerminal) {
259187
- intro("Listing application services");
259188
- }
259235
+ intro("Listing application services");
259189
259236
  const env2 = await loadEnv(false, false);
259190
259237
  const selectedInstance = await instancePrompt(env2, true);
259191
259238
  const personalAccessToken = await getInstanceCredentials(selectedInstance);
@@ -259197,6 +259244,7 @@ function servicesCommand() {
259197
259244
  accessToken,
259198
259245
  instance: selectedInstance
259199
259246
  });
259247
+ const printToTerminal = !output || output === "wide";
259200
259248
  const applicationUniqueName = application ?? env2.SETTLEMINT_APPLICATION ?? (printToTerminal ? await selectApplication(settlemint, env2) : null);
259201
259249
  if (!applicationUniqueName) {
259202
259250
  return nothingSelectedError("application");
@@ -259224,16 +259272,14 @@ function servicesCommand() {
259224
259272
  },
259225
259273
  services: servicesToShow
259226
259274
  };
259227
- if (printToTerminal) {
259228
- table(`Services for ${selectedApplication.name} (${applicationUniqueName}) - ${getApplicationUrl(selectedInstance, selectedApplication)}`, servicesToShow);
259229
- } else if (output === "json") {
259275
+ if (output === "json") {
259230
259276
  jsonOutput(data);
259231
259277
  } else if (output === "yaml") {
259232
259278
  yamlOutput(data);
259279
+ } else {
259280
+ table(`Services for ${selectedApplication.name} (${applicationUniqueName}) - ${getApplicationUrl(selectedInstance, selectedApplication)}`, servicesToShow);
259233
259281
  }
259234
- if (printToTerminal) {
259235
- outro("Application services listed");
259236
- }
259282
+ outro("Application services listed");
259237
259283
  });
259238
259284
  }
259239
259285
  async function selectApplication(settlemint, env2) {
@@ -259302,6 +259348,8 @@ function getItemsForServiceType(services, serviceType) {
259302
259348
  return services.blockchainNetworks;
259303
259349
  case "blockchain-node":
259304
259350
  return services.blockchainNodes;
259351
+ case "load-balancer":
259352
+ return services.loadBalancers;
259305
259353
  default:
259306
259354
  return [];
259307
259355
  }
@@ -260286,7 +260334,8 @@ function subgraphDeployCommand() {
260286
260334
  await writeEnvSpinner(!!prod, {
260287
260335
  ...env2,
260288
260336
  SETTLEMINT_THEGRAPH: theGraphMiddleware.uniqueName,
260289
- ...graphEndpoints
260337
+ ...graphEndpoints,
260338
+ SETTLEMINT_THEGRAPH_DEFAULT_SUBGRAPH: env2.SETTLEMINT_THEGRAPH_DEFAULT_SUBGRAPH ?? graphName
260290
260339
  });
260291
260340
  outro(`Subgraph ${graphName} deployed successfully`);
260292
260341
  });
@@ -260356,8 +260405,8 @@ function subgraphRemoveCommand() {
260356
260405
  await writeEnvSpinner(!!prod, {
260357
260406
  ...env2,
260358
260407
  SETTLEMINT_THEGRAPH: theGraphMiddleware.uniqueName,
260359
- SETTLEMINT_THEGRAPH_DEFAULT_SUBGRAPH: env2.SETTLEMINT_THEGRAPH_DEFAULT_SUBGRAPH === graphName ? undefined : env2.SETTLEMINT_THEGRAPH_DEFAULT_SUBGRAPH,
260360
- ...graphEndpoints
260408
+ ...graphEndpoints,
260409
+ SETTLEMINT_THEGRAPH_DEFAULT_SUBGRAPH: env2.SETTLEMINT_THEGRAPH_DEFAULT_SUBGRAPH === graphName ? undefined : env2.SETTLEMINT_THEGRAPH_DEFAULT_SUBGRAPH
260361
260410
  });
260362
260411
  outro(`Subgraph ${graphName} removed successfully`);
260363
260412
  });
@@ -260419,7 +260468,10 @@ function addHooksToCommand(cmd2, rootCmd, argv) {
260419
260468
  rootCmd._lastCommand = thisCommand;
260420
260469
  rootCmd._lastCommand._commandPath = commandPath;
260421
260470
  }
260422
- if (isLeafCommand(thisCommand) && !isJsonOrYamlOutput(thisCommand)) {
260471
+ if (isJsonOrYamlOutput(thisCommand)) {
260472
+ process.env.SETTLEMINT_DISABLE_TERMINAL = "true";
260473
+ }
260474
+ if (isLeafCommand(thisCommand)) {
260423
260475
  ascii();
260424
260476
  await validateSdkVersionFromCommand(thisCommand);
260425
260477
  }
@@ -260503,4 +260555,4 @@ async function sdkCliCommand(argv = process.argv) {
260503
260555
  // src/cli.ts
260504
260556
  sdkCliCommand();
260505
260557
 
260506
- //# debugId=874C2D77AB00DF9564756E2164756E21
260558
+ //# debugId=EE08CC4DEE8FBF5E64756E2164756E21