casualos 3.7.2-alpha.18014719607 → 3.8.0-alpha.18204122333

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 (2) hide show
  1. package/dist/cli.js +34 -10
  2. package/package.json +4 -4
package/dist/cli.js CHANGED
@@ -93467,7 +93467,7 @@ var trace = TraceAPI.getInstance();
93467
93467
  function hashLowEntropyPasswordWithSalt2(password, salt) {
93468
93468
  const tracer = trace.getTracer(
93469
93469
  "InstrumentedHashHelpers",
93470
- false ? void 0 : "v3.7.2-alpha.18014719607"
93470
+ false ? void 0 : "v3.8.0-alpha.18204122333"
93471
93471
  );
93472
93472
  return tracer.startActiveSpan(
93473
93473
  "hashLowEntropyPasswordWithSalt",
@@ -93485,7 +93485,7 @@ function hashLowEntropyPasswordWithSalt2(password, salt) {
93485
93485
  function hashHighEntropyPasswordWithSalt2(password, salt) {
93486
93486
  const tracer = trace.getTracer(
93487
93487
  "InstrumentedHashHelpers",
93488
- false ? void 0 : "v3.7.2-alpha.18014719607"
93488
+ false ? void 0 : "v3.8.0-alpha.18204122333"
93489
93489
  );
93490
93490
  return tracer.startActiveSpan(
93491
93491
  "hashHighEntropyPasswordWithSalt",
@@ -93503,7 +93503,7 @@ function hashHighEntropyPasswordWithSalt2(password, salt) {
93503
93503
  function verifyPasswordAgainstHashes2(password, salt, hashes) {
93504
93504
  const tracer = trace.getTracer(
93505
93505
  "InstrumentedHashHelpers",
93506
- false ? void 0 : "v3.7.2-alpha.18014719607"
93506
+ false ? void 0 : "v3.8.0-alpha.18204122333"
93507
93507
  );
93508
93508
  return tracer.startActiveSpan(
93509
93509
  "verifyPasswordAgainstHashes",
@@ -100895,7 +100895,7 @@ var import_semantic_conventions = __toESM(require_src3());
100895
100895
  function traced(tracerName, options = {}, metricOptions = {}) {
100896
100896
  const tracer = trace.getTracer(
100897
100897
  tracerName,
100898
- false ? void 0 : "v3.7.2-alpha.18014719607"
100898
+ false ? void 0 : "v3.8.0-alpha.18204122333"
100899
100899
  );
100900
100900
  return function(target, propertyKey, descriptor) {
100901
100901
  const originalMethod = descriptor.value;
@@ -100977,7 +100977,7 @@ function getHistogram(meter) {
100977
100977
  }
100978
100978
  return metrics.getMeter(
100979
100979
  meter.meter,
100980
- false ? void 0 : "v3.7.2-alpha.18014719607"
100980
+ false ? void 0 : "v3.8.0-alpha.18204122333"
100981
100981
  ).createHistogram(meter.name, meter.options);
100982
100982
  }
100983
100983
  function getCounter(meter) {
@@ -100986,7 +100986,7 @@ function getCounter(meter) {
100986
100986
  }
100987
100987
  return metrics.getMeter(
100988
100988
  meter.meter,
100989
- false ? void 0 : "v3.7.2-alpha.18014719607"
100989
+ false ? void 0 : "v3.8.0-alpha.18204122333"
100990
100990
  ).createCounter(meter.name, meter.options);
100991
100991
  }
100992
100992
  function traceHttpResponse(options = {}) {
@@ -111472,7 +111472,7 @@ var RecordsServer = class {
111472
111472
  this._databaseRecordsController = databaseRecordsController;
111473
111473
  this._tracer = trace.getTracer(
111474
111474
  "RecordsServer",
111475
- false ? void 0 : "v3.7.2-alpha.18014719607"
111475
+ false ? void 0 : "v3.8.0-alpha.18204122333"
111476
111476
  );
111477
111477
  this._procedures = this._createProcedures();
111478
111478
  this._setupRoutes();
@@ -113728,6 +113728,26 @@ var RecordsServer = class {
113728
113728
  });
113729
113729
  return result;
113730
113730
  }),
113731
+ aiListChatModels: procedure().origins("api").http("GET", "/api/v2/ai/chat/models").inputs(z.object({})).handler(async (_2, context) => {
113732
+ if (!this._aiController) {
113733
+ return AI_NOT_SUPPORTED_RESULT;
113734
+ }
113735
+ const sessionKeyValidation = await this._validateSessionKey(
113736
+ context.sessionKey
113737
+ );
113738
+ if (sessionKeyValidation.success === false) {
113739
+ if (sessionKeyValidation.errorCode === "no_session_key") {
113740
+ return NOT_LOGGED_IN_RESULT;
113741
+ }
113742
+ return sessionKeyValidation;
113743
+ }
113744
+ const result = await this._aiController.listChatModels({
113745
+ userId: sessionKeyValidation.userId,
113746
+ userSubscriptionTier: sessionKeyValidation.subscriptionTier,
113747
+ userRole: sessionKeyValidation.role
113748
+ });
113749
+ return genericResult(result);
113750
+ }),
113731
113751
  createAiSkybox: procedure().origins("api").http("POST", "/api/v2/ai/skybox").inputs(
113732
113752
  z.object({
113733
113753
  prompt: z.string().nonempty().max(600),
@@ -114584,8 +114604,8 @@ var RecordsServer = class {
114584
114604
  return {
114585
114605
  success: true,
114586
114606
  ...metadata,
114587
- version: true ? "v3.7.2-alpha.18014719607" : void 0,
114588
- versionHash: true ? "5de8c62ae0b479666b2031b51ebb1af069a13389" : void 0
114607
+ version: true ? "v3.8.0-alpha.18204122333" : void 0,
114608
+ versionHash: true ? "61916dc671764c173e2e371073f08df6985b866f" : void 0
114589
114609
  };
114590
114610
  })
114591
114611
  };
@@ -131529,6 +131549,10 @@ var WebhookRecordsController = class extends CrudRecordsController {
131529
131549
  fetchTimeoutMs: checkMetrics.features.fetchTimeoutMs ?? 5e3,
131530
131550
  addStateTimeoutMs: checkMetrics.features.addStateTimeoutMs ?? 1e3
131531
131551
  };
131552
+ console.log(
131553
+ `[WebhookRecordsController] [recordName: ${recordName} address: ${webhook.address}] Running webhook with options`,
131554
+ options
131555
+ );
131532
131556
  const result = await this._environment.handleHttpRequest({
131533
131557
  state,
131534
131558
  recordName: stateRecordName,
@@ -146328,7 +146352,7 @@ var config = new Conf({
146328
146352
  projectName: "casualos-cli"
146329
146353
  });
146330
146354
  var program2 = new Command();
146331
- program2.name("casualos").description("A CLI for CasualOS").version("v3.7.2-alpha.18014719607").option(
146355
+ program2.name("casualos").description("A CLI for CasualOS").version("v3.8.0-alpha.18204122333").option(
146332
146356
  "-e, --endpoint <url>",
146333
146357
  "The endpoint to use for queries. Can be used to override the current endpoint."
146334
146358
  );
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "casualos",
3
- "version": "3.7.2-alpha.18014719607",
3
+ "version": "3.8.0-alpha.18204122333",
4
4
  "description": "Command line interface for CasualOS.",
5
5
  "main": "./dist/index.js",
6
6
  "types": "index.d.ts",
@@ -35,8 +35,8 @@
35
35
  "access": "public"
36
36
  },
37
37
  "dependencies": {
38
- "@casual-simulation/aux-common": "^3.7.2-alpha.18014719607",
39
- "@casual-simulation/aux-records": "^3.7.2-alpha.18014719607",
38
+ "@casual-simulation/aux-common": "^3.8.0-alpha.18204122333",
39
+ "@casual-simulation/aux-records": "^3.8.0-alpha.18204122333",
40
40
  "@octokit/app": "^15.1.0",
41
41
  "@octokit/auth-oauth-device": "^7.1.1",
42
42
  "@octokit/core": "^6.1.2",
@@ -63,5 +63,5 @@
63
63
  "**/*.def",
64
64
  "templates/**"
65
65
  ],
66
- "gitHead": "5de8c62ae0b479666b2031b51ebb1af069a13389"
66
+ "gitHead": "61916dc671764c173e2e371073f08df6985b866f"
67
67
  }