@stackframe/stack 2.6.30 → 2.6.31

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.
@@ -530,6 +530,7 @@ type Team = {
530
530
  listInvitations(): Promise<TeamInvitation[]>;
531
531
  useInvitations(): TeamInvitation[];
532
532
  update(update: TeamUpdateOptions): Promise<void>;
533
+ delete(): Promise<void>;
533
534
  };
534
535
  type TeamUpdateOptions = {
535
536
  displayName?: string;
@@ -530,6 +530,7 @@ type Team = {
530
530
  listInvitations(): Promise<TeamInvitation[]>;
531
531
  useInvitations(): TeamInvitation[];
532
532
  update(update: TeamUpdateOptions): Promise<void>;
533
+ delete(): Promise<void>;
533
534
  };
534
535
  type TeamUpdateOptions = {
535
536
  displayName?: string;
@@ -64,7 +64,7 @@ var import_url = require("../utils/url");
64
64
  var import_auth = require("./auth");
65
65
  var import_cookie = require("./cookie");
66
66
  var NextNavigation = (0, import_compile_time.scrambleDuringCompileTime)(NextNavigationUnscrambled);
67
- var clientVersion = "js @stackframe/stack@2.6.30";
67
+ var clientVersion = "js @stackframe/stack@2.6.31";
68
68
  function getUrls(partial) {
69
69
  const handler = partial.handler ?? "/handler";
70
70
  const home = partial.home ?? "/";
@@ -114,7 +114,7 @@ function getDefaultSuperSecretAdminKey() {
114
114
  return process.env.STACK_SUPER_SECRET_ADMIN_KEY || (0, import_errors.throwErr)(new Error("No super secret admin key provided. Please copy your key from the Stack dashboard and put it in the STACK_SUPER_SECRET_ADMIN_KEY environment variable."));
115
115
  }
116
116
  function getDefaultBaseUrl() {
117
- return process.env.NEXT_PUBLIC_STACK_URL || defaultBaseUrl;
117
+ return process.env.NEXT_PUBLIC_STACK_API_URL || process.env.NEXT_PUBLIC_STACK_URL || defaultBaseUrl;
118
118
  }
119
119
  var defaultBaseUrl = "https://api.stack-auth.com";
120
120
  function createEmptyTokenStore() {
@@ -636,6 +636,10 @@ var _StackClientAppImpl = class __StackClientAppImpl {
636
636
  async update(data) {
637
637
  await app._interface.updateTeam({ data: teamUpdateOptionsToCrud(data), teamId: crud.id }, session);
638
638
  await app._currentUserTeamsCache.refresh([session]);
639
+ },
640
+ async delete() {
641
+ await app._interface.deleteTeam(crud.id, session);
642
+ await app._currentUserTeamsCache.refresh([session]);
639
643
  }
640
644
  };
641
645
  }