@injectivelabs/wallet-turnkey 1.20.1 → 1.20.3

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.
@@ -428,10 +428,13 @@ var TurnkeyWallet = class {
428
428
  providerName
429
429
  });
430
430
  if (!(response === null || response === void 0 || (_response$data = response.data) === null || _response$data === void 0 ? void 0 : _response$data.credentialBundle) || !(response === null || response === void 0 || (_response$data2 = response.data) === null || _response$data2 === void 0 ? void 0 : _response$data2.organizationId)) throw new __injectivelabs_exceptions.WalletException(/* @__PURE__ */ new Error(`${providerName} OAuth2 exchange failed`));
431
- const { credentialBundle, organizationId } = response.data;
431
+ const { credentialBundle, organizationId, email } = response.data;
432
432
  await indexedDbClient.loginWithSession(credentialBundle);
433
433
  this.userOrganizationId = organizationId;
434
- return credentialBundle;
434
+ return {
435
+ session: credentialBundle,
436
+ email
437
+ };
435
438
  }
436
439
  async refreshSession() {
437
440
  var _session$session;
@@ -112,7 +112,10 @@ declare class TurnkeyWallet {
112
112
  codeVerifier: string;
113
113
  targetPublicKey: string;
114
114
  providerName: TurnkeyOAuthProvider;
115
- }): Promise<string>;
115
+ }): Promise<{
116
+ session: string;
117
+ email: string | undefined;
118
+ }>;
116
119
  refreshSession(): Promise<string>;
117
120
  private initClient;
118
121
  }
@@ -112,7 +112,10 @@ declare class TurnkeyWallet {
112
112
  codeVerifier: string;
113
113
  targetPublicKey: string;
114
114
  providerName: TurnkeyOAuthProvider;
115
- }): Promise<string>;
115
+ }): Promise<{
116
+ session: string;
117
+ email: string | undefined;
118
+ }>;
116
119
  refreshSession(): Promise<string>;
117
120
  private initClient;
118
121
  }
package/dist/esm/index.js CHANGED
@@ -428,10 +428,13 @@ var TurnkeyWallet = class {
428
428
  providerName
429
429
  });
430
430
  if (!(response === null || response === void 0 || (_response$data = response.data) === null || _response$data === void 0 ? void 0 : _response$data.credentialBundle) || !(response === null || response === void 0 || (_response$data2 = response.data) === null || _response$data2 === void 0 ? void 0 : _response$data2.organizationId)) throw new WalletException(/* @__PURE__ */ new Error(`${providerName} OAuth2 exchange failed`));
431
- const { credentialBundle, organizationId } = response.data;
431
+ const { credentialBundle, organizationId, email } = response.data;
432
432
  await indexedDbClient.loginWithSession(credentialBundle);
433
433
  this.userOrganizationId = organizationId;
434
- return credentialBundle;
434
+ return {
435
+ session: credentialBundle,
436
+ email
437
+ };
435
438
  }
436
439
  async refreshSession() {
437
440
  var _session$session;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@injectivelabs/wallet-turnkey",
3
- "version": "1.20.1",
3
+ "version": "1.20.3",
4
4
  "description": "Turnkey wallet strategy for use with @injectivelabs/wallet-core.",
5
5
  "license": "Apache-2.0",
6
6
  "author": {
@@ -45,11 +45,11 @@
45
45
  "@turnkey/sdk-browser": "5.16.1",
46
46
  "@turnkey/viem": "0.13.1",
47
47
  "viem": "^2.41.2",
48
- "@injectivelabs/exceptions": "1.20.1",
49
- "@injectivelabs/sdk-ts": "1.20.1",
50
- "@injectivelabs/ts-types": "1.20.1",
51
- "@injectivelabs/wallet-base": "1.20.1",
52
- "@injectivelabs/utils": "1.20.1"
48
+ "@injectivelabs/exceptions": "1.20.3",
49
+ "@injectivelabs/sdk-ts": "1.20.3",
50
+ "@injectivelabs/wallet-base": "1.20.3",
51
+ "@injectivelabs/utils": "1.20.3",
52
+ "@injectivelabs/ts-types": "1.20.3"
53
53
  },
54
54
  "publishConfig": {
55
55
  "access": "public"