@stytch/vanilla-js 4.10.0 → 4.11.0
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/CHANGELOG.md +18 -0
- package/dist/b2b/index.esm.js +22 -15
- package/dist/b2b/index.headless.esm.js +44 -39
- package/dist/b2b/index.headless.js +18 -13
- package/dist/b2b/index.js +154 -147
- package/dist/index.esm.js +144 -156
- package/dist/index.headless.esm.js +1 -13
- package/dist/index.headless.js +1 -13
- package/dist/index.js +185 -197
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
# @stytch/vanilla-js
|
|
2
2
|
|
|
3
|
+
## 4.11.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 5f4ba4a: Add `stytch.organization.getBySlug` method to B2B clients
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- Updated dependencies [5f4ba4a]
|
|
12
|
+
- @stytch/core@2.15.0
|
|
13
|
+
|
|
14
|
+
## 4.10.1
|
|
15
|
+
|
|
16
|
+
### Patch Changes
|
|
17
|
+
|
|
18
|
+
- Updated dependencies [821c884]
|
|
19
|
+
- @stytch/core@2.14.1
|
|
20
|
+
|
|
3
21
|
## 4.10.0
|
|
4
22
|
|
|
5
23
|
### Minor Changes
|
package/dist/b2b/index.esm.js
CHANGED
|
@@ -2393,6 +2393,23 @@ var tt = Promise.resolve({
|
|
|
2393
2393
|
}
|
|
2394
2394
|
}, e, this);
|
|
2395
2395
|
}));
|
|
2396
|
+
}, this.getBySlug = function (e) {
|
|
2397
|
+
return xe(r, void 0, void 0, fe().mark(function t() {
|
|
2398
|
+
return fe().wrap(function (t) {
|
|
2399
|
+
for (;;) switch (t.prev = t.next) {
|
|
2400
|
+
case 0:
|
|
2401
|
+
return Ye("stytch.organization.getBySlug").isString("organization_slug", e.organization_slug), t.abrupt("return", this._networkClient.fetchSDK({
|
|
2402
|
+
url: "/b2b/organizations/search",
|
|
2403
|
+
errorMessage: "Failed to get organization by slug.",
|
|
2404
|
+
method: "POST",
|
|
2405
|
+
body: e
|
|
2406
|
+
}));
|
|
2407
|
+
case 2:
|
|
2408
|
+
case "end":
|
|
2409
|
+
return t.stop();
|
|
2410
|
+
}
|
|
2411
|
+
}, t, this);
|
|
2412
|
+
}));
|
|
2396
2413
|
}, this.members = {
|
|
2397
2414
|
create: function create(e) {
|
|
2398
2415
|
return xe(r, void 0, void 0, fe().mark(function t() {
|
|
@@ -3704,18 +3721,6 @@ var tt = Promise.resolve({
|
|
|
3704
3721
|
});
|
|
3705
3722
|
});
|
|
3706
3723
|
}
|
|
3707
|
-
}, {
|
|
3708
|
-
key: "searchOrganization",
|
|
3709
|
-
value: function value(e) {
|
|
3710
|
-
return this._networkClient.fetchSDK({
|
|
3711
|
-
url: "/b2b/organizations/search",
|
|
3712
|
-
method: "POST",
|
|
3713
|
-
body: {
|
|
3714
|
-
organization_slug: e
|
|
3715
|
-
},
|
|
3716
|
-
errorMessage: "Error searching slug"
|
|
3717
|
-
});
|
|
3718
|
-
}
|
|
3719
3724
|
}, {
|
|
3720
3725
|
key: "searchMember",
|
|
3721
3726
|
value: function value(e, t) {
|
|
@@ -4349,7 +4354,7 @@ var Nt = /*#__PURE__*/function () {
|
|
|
4349
4354
|
},
|
|
4350
4355
|
sdk: {
|
|
4351
4356
|
identifier: "Stytch.js Javascript SDK",
|
|
4352
|
-
version: "4.
|
|
4357
|
+
version: "4.11.0"
|
|
4353
4358
|
}
|
|
4354
4359
|
});
|
|
4355
4360
|
}
|
|
@@ -13884,9 +13889,11 @@ var Kp = cs.button(_templateObject45 || (_templateObject45 = _taggedTemplateLite
|
|
|
13884
13889
|
r = _mr58[1],
|
|
13885
13890
|
o = ks(),
|
|
13886
13891
|
i = bu(n),
|
|
13887
|
-
_u19 = _u("
|
|
13892
|
+
_u19 = _u("stytchClient.organization.getBySlug", function (e, _ref130) {
|
|
13888
13893
|
var t = _ref130.arg.slug;
|
|
13889
|
-
return
|
|
13894
|
+
return o.organization.getBySlug({
|
|
13895
|
+
organization_slug: t
|
|
13896
|
+
});
|
|
13890
13897
|
}, {
|
|
13891
13898
|
onSuccess: function onSuccess(_ref131) {
|
|
13892
13899
|
var e = _ref131.organization;
|
|
@@ -149,8 +149,8 @@ var h, p, _, f, m, v, g;
|
|
|
149
149
|
e[e.emailMagicLinks = 0] = "emailMagicLinks", e[e.oauth = 1] = "oauth", e[e.otp = 2] = "otp", e[e.passwords = 3] = "passwords";
|
|
150
150
|
}(g || (g = {}));
|
|
151
151
|
var b,
|
|
152
|
-
k,
|
|
153
152
|
y,
|
|
153
|
+
k,
|
|
154
154
|
w,
|
|
155
155
|
S = function (e) {
|
|
156
156
|
function t(e, r) {
|
|
@@ -629,14 +629,14 @@ function fe() {
|
|
|
629
629
|
function v() {}
|
|
630
630
|
function g() {}
|
|
631
631
|
function b() {}
|
|
632
|
-
var
|
|
633
|
-
u(
|
|
632
|
+
var y = {};
|
|
633
|
+
u(y, s, function () {
|
|
634
634
|
return this;
|
|
635
635
|
});
|
|
636
|
-
var
|
|
637
|
-
w =
|
|
638
|
-
w && w !== r && n.call(w, s) && (
|
|
639
|
-
var S = b.prototype = v.prototype = Object.create(
|
|
636
|
+
var k = Object.getPrototypeOf,
|
|
637
|
+
w = k && k(k(D([])));
|
|
638
|
+
w && w !== r && n.call(w, s) && (y = w);
|
|
639
|
+
var S = b.prototype = v.prototype = Object.create(y);
|
|
640
640
|
function T(e) {
|
|
641
641
|
["next", "throw", "return"].forEach(function (t) {
|
|
642
642
|
u(e, t, function (e) {
|
|
@@ -897,7 +897,7 @@ function ge(e) {
|
|
|
897
897
|
function be(e, t) {
|
|
898
898
|
if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function");
|
|
899
899
|
}
|
|
900
|
-
function
|
|
900
|
+
function ye(e, t, r) {
|
|
901
901
|
return t = Te(t), function (e, t) {
|
|
902
902
|
if (t && ("object" === _e(t) || "function" == typeof t)) return t;
|
|
903
903
|
if (void 0 !== t) throw new TypeError("Derived constructors may only return object or undefined");
|
|
@@ -907,9 +907,9 @@ function ke(e, t, r) {
|
|
|
907
907
|
}(e);
|
|
908
908
|
}(e, we() ? Reflect.construct(t, r || [], Te(e).constructor) : t.apply(e, r));
|
|
909
909
|
}
|
|
910
|
-
function
|
|
910
|
+
function ke(e) {
|
|
911
911
|
var t = "function" == typeof Map ? new Map() : void 0;
|
|
912
|
-
return
|
|
912
|
+
return ke = function ke(e) {
|
|
913
913
|
if (null === e || !function (e) {
|
|
914
914
|
try {
|
|
915
915
|
return -1 !== Function.toString.call(e).indexOf("[native code]");
|
|
@@ -939,7 +939,7 @@ function ye(e) {
|
|
|
939
939
|
configurable: !0
|
|
940
940
|
}
|
|
941
941
|
}), Se(r, e);
|
|
942
|
-
},
|
|
942
|
+
}, ke(e);
|
|
943
943
|
}
|
|
944
944
|
function we() {
|
|
945
945
|
try {
|
|
@@ -963,9 +963,9 @@ function Te(e) {
|
|
|
963
963
|
e.emailMagicLinks = "emailMagicLinks", e.sso = "sso", e.passwords = "passwords", e.oauth = "oauth";
|
|
964
964
|
}(b || (b = {})), function (e) {
|
|
965
965
|
e.Discovery = "Discovery", e.Organization = "Organization", e.PasswordReset = "PasswordReset";
|
|
966
|
-
}(k || (k = {})), function (e) {
|
|
967
|
-
e.smsOtp = "smsOtp", e.totp = "totp";
|
|
968
966
|
}(y || (y = {})), function (e) {
|
|
967
|
+
e.smsOtp = "smsOtp", e.totp = "totp";
|
|
968
|
+
}(k || (k = {})), function (e) {
|
|
969
969
|
e.Google = "google", e.Microsoft = "microsoft";
|
|
970
970
|
}(w || (w = {}));
|
|
971
971
|
var Ce,
|
|
@@ -1001,7 +1001,7 @@ var Ae,
|
|
|
1001
1001
|
xe = function (e) {
|
|
1002
1002
|
function t(e) {
|
|
1003
1003
|
var r;
|
|
1004
|
-
return be(this, t), (r =
|
|
1004
|
+
return be(this, t), (r = ye(this, t, [e])).type = e, r;
|
|
1005
1005
|
}
|
|
1006
1006
|
return function (e, t) {
|
|
1007
1007
|
if ("function" != typeof t && null !== t) throw new TypeError("Super expression must either be null or a function");
|
|
@@ -1014,7 +1014,7 @@ var Ae,
|
|
|
1014
1014
|
}), Object.defineProperty(e, "prototype", {
|
|
1015
1015
|
writable: !1
|
|
1016
1016
|
}), t && Se(e, t);
|
|
1017
|
-
}(t,
|
|
1017
|
+
}(t, ke(Error)), ve(t);
|
|
1018
1018
|
}();
|
|
1019
1019
|
function De(e) {
|
|
1020
1020
|
var t,
|
|
@@ -2269,6 +2269,23 @@ var et = Promise.resolve({
|
|
|
2269
2269
|
}
|
|
2270
2270
|
}, e, this);
|
|
2271
2271
|
}));
|
|
2272
|
+
}, this.getBySlug = function (e) {
|
|
2273
|
+
return Ee(n, void 0, void 0, fe().mark(function t() {
|
|
2274
|
+
return fe().wrap(function (t) {
|
|
2275
|
+
for (;;) switch (t.prev = t.next) {
|
|
2276
|
+
case 0:
|
|
2277
|
+
return Je("stytch.organization.getBySlug").isString("organization_slug", e.organization_slug), t.abrupt("return", this._networkClient.fetchSDK({
|
|
2278
|
+
url: "/b2b/organizations/search",
|
|
2279
|
+
errorMessage: "Failed to get organization by slug.",
|
|
2280
|
+
method: "POST",
|
|
2281
|
+
body: e
|
|
2282
|
+
}));
|
|
2283
|
+
case 2:
|
|
2284
|
+
case "end":
|
|
2285
|
+
return t.stop();
|
|
2286
|
+
}
|
|
2287
|
+
}, t, this);
|
|
2288
|
+
}));
|
|
2272
2289
|
}, this.members = {
|
|
2273
2290
|
create: function create(e) {
|
|
2274
2291
|
return Ee(n, void 0, void 0, fe().mark(function t() {
|
|
@@ -3580,18 +3597,6 @@ var et = Promise.resolve({
|
|
|
3580
3597
|
});
|
|
3581
3598
|
});
|
|
3582
3599
|
}
|
|
3583
|
-
}, {
|
|
3584
|
-
key: "searchOrganization",
|
|
3585
|
-
value: function value(e) {
|
|
3586
|
-
return this._networkClient.fetchSDK({
|
|
3587
|
-
url: "/b2b/organizations/search",
|
|
3588
|
-
method: "POST",
|
|
3589
|
-
body: {
|
|
3590
|
-
organization_slug: e
|
|
3591
|
-
},
|
|
3592
|
-
errorMessage: "Error searching slug"
|
|
3593
|
-
});
|
|
3594
|
-
}
|
|
3595
3600
|
}, {
|
|
3596
3601
|
key: "searchMember",
|
|
3597
3602
|
value: function value(e, t) {
|
|
@@ -3687,8 +3692,8 @@ mt.REFRESH_INTERVAL_MS = 18e4;
|
|
|
3687
3692
|
var vt,
|
|
3688
3693
|
gt,
|
|
3689
3694
|
bt,
|
|
3690
|
-
kt,
|
|
3691
3695
|
yt,
|
|
3696
|
+
kt,
|
|
3692
3697
|
wt,
|
|
3693
3698
|
St,
|
|
3694
3699
|
Tt,
|
|
@@ -3803,9 +3808,9 @@ function Rt(e, t, r, n) {
|
|
|
3803
3808
|
e.Vessel = "Vessel", e.Phantom = "Phantom", e.Metamask = "Metamask", e.Coinbase = "Coinbase", e.Binance = "Binance", e.GenericEthereumWallet = "Other Ethereum Wallet", e.GenericSolanaWallet = "Other Solana Wallet";
|
|
3804
3809
|
}(bt || (bt = {})), function (e) {
|
|
3805
3810
|
e.embedded = "embedded", e.floating = "floating", e.embeddedOnly = "embeddedOnly", e.floatingOrEmbedded = "floatingOrEmbedded", e.forceLegacyEmbedded = "forceLegacyEmbedded";
|
|
3806
|
-
}(kt || (kt = {})), function (e) {
|
|
3807
|
-
e.SMS = "sms", e.WhatsApp = "whatsapp", e.Email = "email";
|
|
3808
3811
|
}(yt || (yt = {})), function (e) {
|
|
3812
|
+
e.SMS = "sms", e.WhatsApp = "whatsapp", e.Email = "email";
|
|
3813
|
+
}(kt || (kt = {})), function (e) {
|
|
3809
3814
|
e.MagicLinkLoginOrCreateEvent = "MAGIC_LINK_LOGIN_OR_CREATE", e.OTPsLoginOrCreateEvent = "OTP_LOGIN_OR_CREATE", e.OTPsAuthenticate = "OTP_AUTHENTICATE", e.CryptoWalletAuthenticateStart = "CRYPTO_WALLET_AUTHENTICATE_START", e.CryptoWalletAuthenticate = "CRYPTO_WALLET_AUTHENTICATE", e.PasswordCreate = "PASSWORD_CREATE", e.PasswordAuthenticate = "PASSWORD_AUTHENTICATE", e.PasswordResetByEmailStart = "PASSWORD_RESET_BY_EMAIL_START", e.PasswordResetByEmail = "PASSWORD_RESET_BY_EMAIL", e.PasskeyRegister = "PASSKEY_REGISTER", e.PasskeyAuthenticate = "PASSKEY_AUTHENTICATE", e.PasskeySkip = "PASSKEY_SKIP", e.PasskeyDone = "PASSKEY_DONE", e.B2BMagicLinkEmailLoginOrSignup = "B2B_MAGIC_LINK_EMAIL_LOGIN_OR_SIGNUP", e.B2BMagicLinkAuthenticate = "B2B_MAGIC_LINK_AUTHENTICATE", e.B2BMagicLinkEmailDiscoverySend = "B2B_MAGIC_LINK_EMAIL_DISCOVERY_SEND", e.B2BMagicLinkDiscoveryAuthenticate = "B2B_MAGIC_LINK_DISCOVERY_AUTHENTICATE", e.B2BSSOStart = "B2B_SSO_START", e.B2BSSOAuthenticate = "B2B_SSO_AUTHENTICATE", e.B2BOAuthAuthenticate = "B2B_OAUTH_AUTHENTICATE", e.B2BOAuthDiscoveryAuthenticate = "B2B_OAUTH_DISCOVERY_AUTHENTICATE", e.B2BDiscoveryOrganizationsCreate = "B2B_DISCOVERY_ORGANIZATIONS_CREATE", e.B2BDiscoveryIntermediateSessionExchange = "B2B_DISCOVERY_INTERMEDIATE_SESSION_EXCHANGE", e.B2BPasswordAuthenticate = "B2B_PASSWORD_AUTHENTICATE", e.B2BPasswordResetByEmailStart = "B2B_PASSWORD_RESET_BY_EMAIL_START", e.B2BPasswordResetByEmail = "B2B_PASSWORD_RESET_BY_EMAIL", e.B2BPasswordResetBySession = "B2B_PASSWORD_RESET_BY_SESSION", e.B2BSMSOTPSend = "B2B_SMS_OTP_SEND", e.B2BSMSOTPAuthenticate = "B2B_SMS_OTP_AUTHENTICATE", e.B2BTOTPCreate = "B2B_TOTP_CREATE", e.B2BTOTPAuthenticate = "B2B_TOTP_AUTHENTICATE", e.B2BRecoveryCodesRecover = "B2B_RECOVERY_CODES_RECOVER";
|
|
3810
3815
|
}(wt || (wt = {})), function (e) {
|
|
3811
3816
|
e[e.emailMagicLinks = 0] = "emailMagicLinks", e[e.oauth = 1] = "oauth", e[e.otp = 2] = "otp", e[e.passwords = 3] = "passwords";
|
|
@@ -4225,7 +4230,7 @@ var Nt = /*#__PURE__*/function () {
|
|
|
4225
4230
|
},
|
|
4226
4231
|
sdk: {
|
|
4227
4232
|
identifier: "Stytch.js Javascript SDK",
|
|
4228
|
-
version: "4.
|
|
4233
|
+
version: "4.11.0"
|
|
4229
4234
|
}
|
|
4230
4235
|
});
|
|
4231
4236
|
}
|
|
@@ -5226,20 +5231,20 @@ var lr = /*#__PURE__*/_createClass(function lr(e, t) {
|
|
|
5226
5231
|
this._networkClient = new Nt(e, this._dataLayer, i.endpoints.sdkBackendURL, m), this._apiNetworkClient = new ur(e, this._dataLayer, i.endpoints.liveAPIURL, i.endpoints.testAPIURL, m);
|
|
5227
5232
|
var g = new Mt(e, this._networkClient, this._dataLayer),
|
|
5228
5233
|
b = new Ft(g.getAsync()),
|
|
5229
|
-
|
|
5230
|
-
|
|
5234
|
+
y = new $e(e, i.endpoints.dfpBackendURL, g.getAsync(), b.executeRecaptcha),
|
|
5235
|
+
k = new jt(i.endpoints.clientsideServicesIframeURL),
|
|
5231
5236
|
w = new Ut(this._dataLayer, "oauth"),
|
|
5232
5237
|
S = new cr(this._apiNetworkClient, w, g.getAsync());
|
|
5233
|
-
this.organization = new it(this._networkClient, this._subscriptionService), this.member = new rt(this._networkClient, this._subscriptionService), this.self = new rt(this._networkClient, this._subscriptionService), this.session = new st(this._networkClient, this._subscriptionService), this.magicLinks = new tt(this._networkClient, this._subscriptionService, new Ut(this._dataLayer, "magic_links"), v, g.getAsync(),
|
|
5238
|
+
this.organization = new it(this._networkClient, this._subscriptionService), this.member = new rt(this._networkClient, this._subscriptionService), this.self = new rt(this._networkClient, this._subscriptionService), this.session = new st(this._networkClient, this._subscriptionService), this.magicLinks = new tt(this._networkClient, this._subscriptionService, new Ut(this._dataLayer, "magic_links"), v, g.getAsync(), y), this.oauth = new Bt(this._networkClient, this._subscriptionService, w, g.getAsync(), {
|
|
5234
5239
|
publicToken: e,
|
|
5235
5240
|
testAPIURL: i.endpoints.testAPIURL,
|
|
5236
5241
|
liveAPIURL: i.endpoints.liveAPIURL
|
|
5237
|
-
},
|
|
5242
|
+
}, y, S), this.sso = new nt(this._networkClient, this._subscriptionService, new Ut(this._dataLayer, "sso"), g.getAsync(), {
|
|
5238
5243
|
publicToken: e,
|
|
5239
5244
|
testAPIURL: i.endpoints.testAPIURL,
|
|
5240
5245
|
liveAPIURL: i.endpoints.liveAPIURL
|
|
5241
|
-
}), this.discovery = new at(this._networkClient, this._subscriptionService), this.passwords = new ut(this._networkClient, this._subscriptionService, v, g.getAsync(),
|
|
5242
|
-
var T = new ft(this._networkClient,
|
|
5246
|
+
}), this.discovery = new at(this._networkClient, this._subscriptionService), this.passwords = new ut(this._networkClient, this._subscriptionService, v, g.getAsync(), y), this.otps = new lt(this._networkClient, this._subscriptionService, y), this.totp = new dt(this._networkClient, this._subscriptionService, y), this.recoveryCodes = new ht(this._networkClient, this._subscriptionService, y), this.rbac = new pt(g.getSync(), g.getAsync(), this._subscriptionService), this._sessionManager = new mt(this._subscriptionService, this.session);
|
|
5247
|
+
var T = new ft(this._networkClient, y);
|
|
5243
5248
|
this._dataLayer.readSessionCookie().session_token && this._sessionManager.performBackgroundRefresh(), this._networkClient.logEvent({
|
|
5244
5249
|
name: "b2b_sdk_instance_instantiated",
|
|
5245
5250
|
details: {
|
|
@@ -5252,7 +5257,7 @@ var lr = /*#__PURE__*/_createClass(function lr(e, t) {
|
|
|
5252
5257
|
Object.assign(e, _defineProperty({}, nr, t));
|
|
5253
5258
|
})(this, {
|
|
5254
5259
|
bootstrap: g,
|
|
5255
|
-
clientsideServices:
|
|
5260
|
+
clientsideServices: k,
|
|
5256
5261
|
publicToken: e,
|
|
5257
5262
|
searchManager: T,
|
|
5258
5263
|
dataLayer: this._dataLayer,
|
|
@@ -5260,4 +5265,4 @@ var lr = /*#__PURE__*/_createClass(function lr(e, t) {
|
|
|
5260
5265
|
oneTap: S
|
|
5261
5266
|
});
|
|
5262
5267
|
});
|
|
5263
|
-
export {
|
|
5268
|
+
export { y as AuthFlowType, k as B2BMFAProducts, w as B2BOAuthProviders, b as B2BProducts, ee as BiometricsFailedError, M as BiometricsUnavailableError, J as ChallengeSigningFailedError, z as DeviceCredentialsNotAllowedError, X as FailedCodeChallengeError, Q as FailedToDecryptDataError, B as InternalError, H as InvalidAuthorizationCredentialError, ie as InvalidCredentialTypeError, re as InvalidRedirectSchemeError, te as InvalidStartUrlError, se as JSONDataNotConvertibleToStringError, F as KeyInvalidatedError, j as KeystoreUnavailableError, oe as MissingAttestationObjectError, W as MissingAuthorizationCredentialIDTokenError, q as MissingGoogleClientIDError, G as MissingPKCEError, V as MissingPublicKeyError, ne as MissingUrlError, N as NoBiometricsEnrolledError, L as NoBiometricsRegistrationError, Y as NoCredentialsPresentError, I as NoCurrentSessionError, p as OAuthProviders, m as OTPMethods, f as OneTapPositions, ce as PasskeysInvalidEncoding, ue as PasskeysMisconfigured, Z as PasskeysUnsupportedError, h as Products, g as RNUIProducts, ae as RandomNumberGenerationFailed, S as SDKAPIUnreachableError, $ as SDKNotConfiguredError, le as SignInWithAppleMisconfigured, D as StytchAPIError, x as StytchAPISchemaError, A as StytchAPIUnreachableError, lr as StytchB2BHeadlessClient, E as StytchError, v as StytchEventType, P as StytchSDKAPIError, R as StytchSDKError, C as StytchSDKSchemaError, T as StytchSDKUsageError, O as UNRECOVERABLE_ERROR_TYPES, K as UserCancellationError, U as UserLockedOutError, _ as Wallets, de as errorToStytchError };
|
|
@@ -2195,6 +2195,23 @@ var ze = Promise.resolve({
|
|
|
2195
2195
|
}
|
|
2196
2196
|
}, e, this);
|
|
2197
2197
|
}));
|
|
2198
|
+
}, this.getBySlug = function (e) {
|
|
2199
|
+
return me(n, void 0, void 0, ne().mark(function t() {
|
|
2200
|
+
return ne().wrap(function (t) {
|
|
2201
|
+
for (;;) switch (t.prev = t.next) {
|
|
2202
|
+
case 0:
|
|
2203
|
+
return Fe("stytch.organization.getBySlug").isString("organization_slug", e.organization_slug), t.abrupt("return", this._networkClient.fetchSDK({
|
|
2204
|
+
url: "/b2b/organizations/search",
|
|
2205
|
+
errorMessage: "Failed to get organization by slug.",
|
|
2206
|
+
method: "POST",
|
|
2207
|
+
body: e
|
|
2208
|
+
}));
|
|
2209
|
+
case 2:
|
|
2210
|
+
case "end":
|
|
2211
|
+
return t.stop();
|
|
2212
|
+
}
|
|
2213
|
+
}, t, this);
|
|
2214
|
+
}));
|
|
2198
2215
|
}, this.members = {
|
|
2199
2216
|
create: function create(e) {
|
|
2200
2217
|
return me(n, void 0, void 0, ne().mark(function t() {
|
|
@@ -3506,18 +3523,6 @@ var ze = Promise.resolve({
|
|
|
3506
3523
|
});
|
|
3507
3524
|
});
|
|
3508
3525
|
}
|
|
3509
|
-
}, {
|
|
3510
|
-
key: "searchOrganization",
|
|
3511
|
-
value: function value(e) {
|
|
3512
|
-
return this._networkClient.fetchSDK({
|
|
3513
|
-
url: "/b2b/organizations/search",
|
|
3514
|
-
method: "POST",
|
|
3515
|
-
body: {
|
|
3516
|
-
organization_slug: e
|
|
3517
|
-
},
|
|
3518
|
-
errorMessage: "Error searching slug"
|
|
3519
|
-
});
|
|
3520
|
-
}
|
|
3521
3526
|
}, {
|
|
3522
3527
|
key: "searchMember",
|
|
3523
3528
|
value: function value(e, t) {
|
|
@@ -4151,7 +4156,7 @@ var Et = /*#__PURE__*/function () {
|
|
|
4151
4156
|
},
|
|
4152
4157
|
sdk: {
|
|
4153
4158
|
identifier: "Stytch.js Javascript SDK",
|
|
4154
|
-
version: "4.
|
|
4159
|
+
version: "4.11.0"
|
|
4155
4160
|
}
|
|
4156
4161
|
});
|
|
4157
4162
|
}
|