@getpara/react-core 3.0.0-alpha.0 → 3.0.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.
@@ -5,8 +5,26 @@ import type { StoreApi } from 'zustand';
5
5
  import { type ParaStorageAdapter } from './stores/createCoreStore.js';
6
6
  import type { CoreStore, FarcasterMiniAppConfig } from './stores/types.js';
7
7
  export interface CoreProviderConfig {
8
- appName: string;
8
+ /**
9
+ * @deprecated Configure your app name at the partner level via the developer
10
+ * portal (the partner record's display name) — it's the canonical source of
11
+ * truth. Optional and will be removed in the next major release. There is no
12
+ * per-instance override: `appName` is excluded from `SdkOverridableAppConfig`
13
+ * (it's 1:1 with the apikey/project), so it cannot be passed via
14
+ * `configOverrides`.
15
+ */
16
+ appName?: string;
17
+ /**
18
+ * @deprecated Configure the RPC URL at the partner level via the developer
19
+ * portal. Will be removed in the next major release. For per-instance
20
+ * overrides use `configOverrides.rpcUrl` on `ParaProvider`.
21
+ */
9
22
  rpcUrl?: string;
23
+ /**
24
+ * Mini-app context for Farcaster integrations. Consumer-side context (the
25
+ * parent app's Farcaster integration) with no partner equivalent —
26
+ * intentionally not deprecated.
27
+ */
10
28
  farcasterMiniAppConfig?: FarcasterMiniAppConfig;
11
29
  }
12
30
  /**
@@ -40,7 +58,7 @@ export interface ParaProviderBaseProps<TClient extends ParaCore = ParaCore, TCon
40
58
  /** A pre-instantiated Para client, or a config object with `apiKey` and optional `env`/`opts`. */
41
59
  paraClientConfig: TClient | ParaClientConfig;
42
60
  /** Provider configuration (appName, rpcUrl, etc.). */
43
- config: TConfig;
61
+ config?: TConfig;
44
62
  /** Event callbacks fired during the authentication and signing lifecycle. */
45
63
  callbacks?: TCallbacks;
46
64
  /**
@@ -13,11 +13,12 @@ const EVENT_TO_CALLBACK = {
13
13
  [ParaEvent.WALLET_CREATED]: "onWalletCreated",
14
14
  [ParaEvent.WALLETS_CHANGE_EVENT]: "onWalletsChange"
15
15
  };
16
+ const DEFAULT_PROVIDER_CONFIG = {};
16
17
  function isClientConfig(v) {
17
18
  return typeof v === "object" && v !== null && "createClient" in v;
18
19
  }
19
20
  const ParaProviderCoreInner = ({ children, paraClientConfig: paraClient, config, callbacks, waitForReady, fallback }) => {
20
- var _a;
21
+ var _a, _b, _c, _d;
21
22
  const unsubRef = useRef(null);
22
23
  const setClient = useCoreStore((state) => state.setClient);
23
24
  const client = useCoreStore((state) => state.client);
@@ -29,15 +30,18 @@ const ParaProviderCoreInner = ({ children, paraClientConfig: paraClient, config,
29
30
  const rpcUrl = useCoreStore((state) => state.rpcUrl);
30
31
  const setParaState = useCoreStore((state) => state.setParaState);
31
32
  const paraState = useCoreStore((state) => state.paraState);
33
+ useCoreStore((state) => state.paraConfigVersion);
32
34
  useEffect(() => {
33
35
  setClient(paraClient);
34
36
  }, [paraClient, setClient]);
37
+ const resolvedAppName = (_b = (_a = paraClient.config.appName) != null ? _a : config.appName) != null ? _b : "";
38
+ const resolvedRpcUrl = (_c = paraClient.config.rpcUrl) != null ? _c : config.rpcUrl;
35
39
  useEffect(() => {
36
- if (rpcUrl !== config.rpcUrl) setRpcUrl(config.rpcUrl);
37
- }, [config.rpcUrl]);
40
+ if (rpcUrl !== resolvedRpcUrl) setRpcUrl(resolvedRpcUrl);
41
+ }, [resolvedRpcUrl]);
38
42
  useEffect(() => {
39
- if (appName !== config.appName) setAppName(config.appName);
40
- }, [config.appName]);
43
+ if (appName !== resolvedAppName) setAppName(resolvedAppName);
44
+ }, [resolvedAppName]);
41
45
  useEffect(() => {
42
46
  if (farcasterMiniAppConfig !== config.farcasterMiniAppConfig) {
43
47
  setFarcasterMiniAppConfig(config.farcasterMiniAppConfig);
@@ -69,14 +73,14 @@ const ParaProviderCoreInner = ({ children, paraClientConfig: paraClient, config,
69
73
  for (const [event, cbKey] of Object.entries(EVENT_TO_CALLBACK)) {
70
74
  unsubs.push(
71
75
  onParaEvent(event, (e) => {
72
- var _a2, _b;
73
- (_b = (_a2 = callbacksRef.current) == null ? void 0 : _a2[cbKey]) == null ? void 0 : _b.call(_a2, e);
76
+ var _a2, _b2;
77
+ (_b2 = (_a2 = callbacksRef.current) == null ? void 0 : _a2[cbKey]) == null ? void 0 : _b2.call(_a2, e);
74
78
  })
75
79
  );
76
80
  }
77
81
  return () => unsubs.forEach((fn) => fn());
78
82
  }, []);
79
- const isReady = (_a = paraState == null ? void 0 : paraState.isReady) != null ? _a : false;
83
+ const isReady = (_d = paraState == null ? void 0 : paraState.isReady) != null ? _d : false;
80
84
  if (!client) {
81
85
  return /* @__PURE__ */ jsx(Fragment, { children: fallback != null ? fallback : null });
82
86
  }
@@ -116,7 +120,7 @@ function ParaProviderCore({
116
120
  ParaProviderCoreInner,
117
121
  {
118
122
  paraClientConfig: resolvedClient,
119
- config,
123
+ config: config != null ? config : DEFAULT_PROVIDER_CONFIG,
120
124
  callbacks,
121
125
  waitForReady,
122
126
  fallback,
@@ -1,5 +1,5 @@
1
1
  import type ParaCore from '@getpara/core-sdk';
2
- import type { SignUpOrLogInParams, SignUpOrLogInResponse, WaitForLoginParams, WaitForLoginResponse, WaitForSignupParams, WaitForWalletCreationParams, WaitForWalletCreationResponse, VerifyOAuthProcessParams, OAuthResponse, VerifyFarcasterParams, VerifyTelegramParams, LoginExternalWalletParams, LoginExternalWalletResponse, VerifyExternalWalletParams, VerifyExternalWalletResponse, Setup2faResponse, Enable2faParams, Verify2faParams, Verify2faResponse, LogoutParams, ResendVerificationCodeParams, CreateWalletParams, CreateWalletResponse, CreateWalletPerTypeParams, CreateWalletPerTypeResponse, CreatePregenWalletParams, CreatePregenWalletResponse, CreatePregenWalletPerTypeParams, CreatePregenWalletPerTypeResponse, ClaimPregenWalletsParams, ClaimPregenWalletsResponse, HasPregenWalletParams, UpdatePregenWalletIdentifierParams, CreateGuestWalletsResponse, SignMessageParams, SignTransactionParams, FullSignatureRes, GetWalletBalanceParams, IssueJwtParams, IssueJwtResponse, GetLinkedAccountsParams, GetLinkedAccountsResponse, AddCredentialParams, ExportPrivateKeyParams, ExportPrivateKeyResponse, RequestFaucetParams, RequestFaucetResponse, AuthenticateWithEmailOrPhoneParams, AuthenticateWithEmailOrPhoneResponse, AuthenticateWithOAuthParams, AuthenticateWithOAuthResponse } from '@getpara/core-sdk';
2
+ import type { SignUpOrLogInParams, SignUpOrLogInResponse, WaitForLoginParams, WaitForLoginResponse, WaitForSignupParams, WaitForWalletCreationParams, WaitForWalletCreationResponse, VerifyOAuthProcessParams, OAuthResponse, VerifyFarcasterParams, VerifyTelegramParams, LoginExternalWalletParams, LoginExternalWalletResponse, VerifyExternalWalletParams, VerifyExternalWalletResponse, Setup2faResponse, Enable2faParams, Verify2faParams, Verify2faResponse, LogoutParams, ResendVerificationCodeParams, ResendVerificationCodeResponse, CreateWalletParams, CreateWalletResponse, CreateWalletPerTypeParams, CreateWalletPerTypeResponse, CreatePregenWalletParams, CreatePregenWalletResponse, CreatePregenWalletPerTypeParams, CreatePregenWalletPerTypeResponse, ClaimPregenWalletsParams, ClaimPregenWalletsResponse, HasPregenWalletParams, UpdatePregenWalletIdentifierParams, CreateGuestWalletsResponse, SignMessageParams, SignTransactionParams, FullSignatureRes, GetWalletBalanceParams, IssueJwtParams, IssueJwtResponse, GetLinkedAccountsParams, GetLinkedAccountsResponse, AddCredentialParams, ExportPrivateKeyParams, ExportPrivateKeyResponse, RequestFaucetParams, RequestFaucetResponse, AuthenticateWithEmailOrPhoneParams, AuthenticateWithEmailOrPhoneResponse, AuthenticateWithOAuthParams, AuthenticateWithOAuthResponse } from '@getpara/core-sdk';
3
3
  export { generateCoreAction, type CoreAction } from './utils.js';
4
4
  export { getEmbeddedAccount, type Account } from './getEmbeddedAccount.js';
5
5
  export { getWallet } from './getWallet.js';
@@ -18,18 +18,13 @@ export declare const enable2fa: (para?: ParaCore, args?: Enable2faParams) => Pro
18
18
  export declare const verify2fa: (para?: ParaCore, args?: Verify2faParams) => Promise<Verify2faResponse>;
19
19
  export declare const keepSessionAlive: (para?: ParaCore) => Promise<boolean>;
20
20
  export declare const logout: (para?: ParaCore, args?: LogoutParams) => Promise<void>;
21
- export declare const resendVerificationCode: (para?: ParaCore, args?: ResendVerificationCodeParams) => Promise<void>;
21
+ export declare const resendVerificationCode: (para?: ParaCore, args?: ResendVerificationCodeParams) => Promise<ResendVerificationCodeResponse>;
22
22
  export declare const createWallet: (para?: ParaCore, args?: CreateWalletParams) => Promise<CreateWalletResponse>;
23
23
  export declare const createWalletPerType: (para?: ParaCore, args?: CreateWalletPerTypeParams) => Promise<CreateWalletPerTypeResponse>;
24
- /** @deprecated Use the REST API (`POST /v1/wallets`) instead. See https://docs.getpara.com/v2/rest/migrate-from-sdk-pregen */
25
24
  export declare const createPregenWallet: (para?: ParaCore, args?: CreatePregenWalletParams) => Promise<CreatePregenWalletResponse>;
26
- /** @deprecated Use the REST API (`POST /v1/wallets`) instead. See https://docs.getpara.com/v2/rest/migrate-from-sdk-pregen */
27
25
  export declare const createPregenWalletPerType: (para?: ParaCore, args?: CreatePregenWalletPerTypeParams) => Promise<CreatePregenWalletPerTypeResponse>;
28
- /** @deprecated Use the REST API (`POST /v1/wallets`) instead. See https://docs.getpara.com/v2/rest/migrate-from-sdk-pregen */
29
26
  export declare const claimPregenWallets: (para?: ParaCore, args?: ClaimPregenWalletsParams) => Promise<ClaimPregenWalletsResponse>;
30
- /** @deprecated Use the REST API (`GET /v1/wallets`) instead. See https://docs.getpara.com/v2/rest/migrate-from-sdk-pregen */
31
27
  export declare const hasPregenWallet: (para?: ParaCore, args?: HasPregenWalletParams) => Promise<boolean>;
32
- /** @deprecated Use the REST API (`PATCH /v1/wallets/:id`) instead. See https://docs.getpara.com/v2/rest/migrate-from-sdk-pregen */
33
28
  export declare const updatePregenWalletIdentifier: (para?: ParaCore, args?: UpdatePregenWalletIdentifierParams) => Promise<void>;
34
29
  export declare const createGuestWallets: (para?: ParaCore) => Promise<CreateGuestWalletsResponse>;
35
30
  export declare const signMessage: (para?: ParaCore, args?: SignMessageParams) => Promise<FullSignatureRes>;
@@ -6,7 +6,9 @@ export declare const THIRDWEB_SMART_ACCOUNT_BASE_KEY = "PARA_THIRDWEB_SMART_ACCO
6
6
  * Factory that creates a `useThirdwebSmartAccount` hook with an optional enhancer.
7
7
  * Pass `useWagmiSignerEnhancer` on web to support external wallet signers.
8
8
  */
9
- export declare const createThirdwebSmartAccountHook: (useEnhancer?: (params: UseThirdwebSmartAccountParams) => SmartAccountEnhancement) => (params?: any) => import("./types.js").UseSmartAccountResult<SmartAccount>;
9
+ export declare const createThirdwebSmartAccountHook: (useEnhancer?: (params: UseThirdwebSmartAccountParams) => SmartAccountEnhancement) => (params?: import("@getpara/aa-thirdweb").ThirdwebSmartAccountConfig & {
10
+ enabled?: boolean;
11
+ }) => import("./types.js").UseSmartAccountResult<SmartAccount>;
10
12
  /**
11
13
  * React / React Native hook to create and manage a Thirdweb smart account.
12
14
  *
@@ -15,4 +17,6 @@ export declare const createThirdwebSmartAccountHook: (useEnhancer?: (params: Use
15
17
  *
16
18
  * Requires `@getpara/aa-thirdweb` to be installed.
17
19
  */
18
- export declare const useThirdwebSmartAccount: (params?: any) => import("./types.js").UseSmartAccountResult<SmartAccount>;
20
+ export declare const useThirdwebSmartAccount: (params?: import("@getpara/aa-thirdweb").ThirdwebSmartAccountConfig & {
21
+ enabled?: boolean;
22
+ }) => import("./types.js").UseSmartAccountResult<SmartAccount>;
@@ -1,8 +1,6 @@
1
1
  import type { ClaimPregenWalletsParams } from '@getpara/core-sdk';
2
2
  export declare const CLAIM_PREGEN_WALLETS_KEY = "CLAIM_PREGEN_WALLETS";
3
3
  /**
4
- * @deprecated Use the REST API (`POST /v1/wallets`) instead. See https://docs.getpara.com/v2/rest/migrate-from-sdk-pregen
5
- *
6
4
  * React hook for the `claimPregenWallets` mutation.
7
5
  *
8
6
  * Returns a mutation result object with all standard fields from `useMutation`, except:
@@ -1,8 +1,6 @@
1
1
  import type { CreatePregenWalletParams } from '@getpara/core-sdk';
2
2
  export declare const CREATE_PREGEN_WALLET_KEY = "CREATE_PREGEN_WALLET";
3
3
  /**
4
- * @deprecated Use the REST API (`POST /v1/wallets`) instead. See https://docs.getpara.com/v2/rest/migrate-from-sdk-pregen
5
- *
6
4
  * React hook for the `createPregenWallet` mutation.
7
5
  *
8
6
  * Returns a mutation result object with all standard fields from `useMutation`, except:
@@ -1,8 +1,6 @@
1
1
  import type { CreatePregenWalletPerTypeParams, CreatePregenWalletPerTypeResponse } from '@getpara/core-sdk';
2
2
  export declare const CREATE_PREGEN_WALLET_PER_TYPE_KEY = "CREATE_PREGEN_WALLET_PER_TYPE";
3
3
  /**
4
- * @deprecated Use the REST API (`POST /v1/wallets`) instead. See https://docs.getpara.com/v2/rest/migrate-from-sdk-pregen
5
- *
6
4
  * React hook for the `createPregenWalletPerType` mutation.
7
5
  *
8
6
  * Returns a mutation result object with all standard fields from `useMutation`, except:
@@ -6,6 +6,10 @@ export declare const EXPORT_PRIVATE_KEY_KEY = "EXPORT_PRIVATE_KEY";
6
6
  * Returns the portal URL for the export flow. On web, open this URL in a popup
7
7
  * (`shouldOpenPopup: true`). On React Native, load this URL in a WebView.
8
8
  *
9
+ * Supports both DKLS wallets (EVM, Cosmos — returns a `0x`-prefixed hex string)
10
+ * and ED25519 wallets (Solana, Stellar — returns an MPC-Ed25519 v1 base58
11
+ * string starting with `MPCS`). Pregenerated and external wallets are rejected.
12
+ *
9
13
  * @example
10
14
  * const { exportPrivateKey, exportPrivateKeyAsync } = useExportPrivateKey();
11
15
  * const { url } = await exportPrivateKeyAsync({ walletId: '...' });
@@ -1,8 +1,6 @@
1
1
  import type { HasPregenWalletParams } from '@getpara/core-sdk';
2
2
  export declare const HAS_PREGEN_WALLET_KEY = "HAS_PREGEN_WALLET";
3
3
  /**
4
- * @deprecated Use the REST API (`GET /v1/wallets`) instead. See https://docs.getpara.com/v2/rest/migrate-from-sdk-pregen
5
- *
6
4
  * React hook for the `hasPregenWallet` mutation.
7
5
  *
8
6
  * Returns a mutation result object with all standard fields from `useMutation`, except:
@@ -11,9 +11,10 @@ export type UseRequestFaucetArgs = Omit<RequestFaucetParams, 'walletId'> & {
11
11
  /**
12
12
  * React hook for the `requestFaucet` mutation.
13
13
  *
14
- * Requests testnet faucet funds for the active wallet. Automatically fills in
15
- * the walletId from the active wallet if not provided. Throws if neither the
16
- * caller nor the active wallet supplies a walletId.
14
+ * Submits a testnet faucet funding transaction for the active wallet.
15
+ * Automatically fills in the walletId from the active wallet if not provided.
16
+ * Throws if neither the caller nor the active wallet supplies a walletId. Wait
17
+ * for the returned transactionHash to confirm before assuming funds are spendable.
17
18
  *
18
19
  * @example
19
20
  * const { requestFaucet, requestFaucetAsync } = useRequestFaucet();
@@ -1,4 +1,4 @@
1
- import type { ResendVerificationCodeParams } from '@getpara/core-sdk';
1
+ import type { ResendVerificationCodeParams, ResendVerificationCodeResponse } from '@getpara/core-sdk';
2
2
  export declare const RESEND_VERIFICATION_CODE_KEY = "RESEND_VERIFICATION_CODE";
3
3
  /**
4
4
  * React hook for the `resendVerificationCode` mutation.
@@ -8,11 +8,14 @@ export declare const RESEND_VERIFICATION_CODE_KEY = "RESEND_VERIFICATION_CODE";
8
8
  * - `resendVerificationCode`: function to trigger the mutation (same as `mutate`)
9
9
  * - `resendVerificationCodeAsync`: async function to trigger the mutation (same as `mutateAsync`)
10
10
  *
11
+ * The resolved value is the server's resolved-channel info — `{ deliveryChannel, fallbackUsed,
12
+ * fallbackChannel, isSmsAllowed }` — so callers can surface channel-aware copy in the OTP UI.
13
+ *
11
14
  * @example
12
15
  * const { resendVerificationCode, resendVerificationCodeAsync } = useResendVerificationCode();
13
16
  * resendVerificationCode({ ...params });
14
17
  * // or
15
- * await resendVerificationCodeAsync({ ...params });
18
+ * const { deliveryChannel } = await resendVerificationCodeAsync({ ...params });
16
19
  */
17
20
  export declare const useResendVerificationCode: () => {
18
21
  data: undefined;
@@ -23,16 +26,16 @@ export declare const useResendVerificationCode: () => {
23
26
  isPending: false;
24
27
  isSuccess: false;
25
28
  status: "idle";
26
- mutate: import("@tanstack/react-query").UseMutateFunction<void, Error, void | ResendVerificationCodeParams, unknown>;
29
+ mutate: import("@tanstack/react-query").UseMutateFunction<ResendVerificationCodeResponse, Error, void | ResendVerificationCodeParams, unknown>;
27
30
  reset: () => void;
28
31
  context: unknown;
29
32
  failureCount: number;
30
33
  failureReason: Error;
31
34
  isPaused: boolean;
32
35
  submittedAt: number;
33
- mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<void, Error, void | ResendVerificationCodeParams, unknown>;
34
- resendVerificationCode: import("@tanstack/react-query").UseMutateFunction<void, Error, void | ResendVerificationCodeParams, unknown>;
35
- resendVerificationCodeAsync: import("@tanstack/react-query").UseMutateAsyncFunction<void, Error, void | ResendVerificationCodeParams, unknown>;
36
+ mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<ResendVerificationCodeResponse, Error, void | ResendVerificationCodeParams, unknown>;
37
+ resendVerificationCode: import("@tanstack/react-query").UseMutateFunction<ResendVerificationCodeResponse, Error, void | ResendVerificationCodeParams, unknown>;
38
+ resendVerificationCodeAsync: import("@tanstack/react-query").UseMutateAsyncFunction<ResendVerificationCodeResponse, Error, void | ResendVerificationCodeParams, unknown>;
36
39
  } | {
37
40
  data: undefined;
38
41
  variables: void | ResendVerificationCodeParams;
@@ -42,16 +45,16 @@ export declare const useResendVerificationCode: () => {
42
45
  isPending: true;
43
46
  isSuccess: false;
44
47
  status: "pending";
45
- mutate: import("@tanstack/react-query").UseMutateFunction<void, Error, void | ResendVerificationCodeParams, unknown>;
48
+ mutate: import("@tanstack/react-query").UseMutateFunction<ResendVerificationCodeResponse, Error, void | ResendVerificationCodeParams, unknown>;
46
49
  reset: () => void;
47
50
  context: unknown;
48
51
  failureCount: number;
49
52
  failureReason: Error;
50
53
  isPaused: boolean;
51
54
  submittedAt: number;
52
- mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<void, Error, void | ResendVerificationCodeParams, unknown>;
53
- resendVerificationCode: import("@tanstack/react-query").UseMutateFunction<void, Error, void | ResendVerificationCodeParams, unknown>;
54
- resendVerificationCodeAsync: import("@tanstack/react-query").UseMutateAsyncFunction<void, Error, void | ResendVerificationCodeParams, unknown>;
55
+ mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<ResendVerificationCodeResponse, Error, void | ResendVerificationCodeParams, unknown>;
56
+ resendVerificationCode: import("@tanstack/react-query").UseMutateFunction<ResendVerificationCodeResponse, Error, void | ResendVerificationCodeParams, unknown>;
57
+ resendVerificationCodeAsync: import("@tanstack/react-query").UseMutateAsyncFunction<ResendVerificationCodeResponse, Error, void | ResendVerificationCodeParams, unknown>;
55
58
  } | {
56
59
  data: undefined;
57
60
  error: Error;
@@ -61,18 +64,18 @@ export declare const useResendVerificationCode: () => {
61
64
  isPending: false;
62
65
  isSuccess: false;
63
66
  status: "error";
64
- mutate: import("@tanstack/react-query").UseMutateFunction<void, Error, void | ResendVerificationCodeParams, unknown>;
67
+ mutate: import("@tanstack/react-query").UseMutateFunction<ResendVerificationCodeResponse, Error, void | ResendVerificationCodeParams, unknown>;
65
68
  reset: () => void;
66
69
  context: unknown;
67
70
  failureCount: number;
68
71
  failureReason: Error;
69
72
  isPaused: boolean;
70
73
  submittedAt: number;
71
- mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<void, Error, void | ResendVerificationCodeParams, unknown>;
72
- resendVerificationCode: import("@tanstack/react-query").UseMutateFunction<void, Error, void | ResendVerificationCodeParams, unknown>;
73
- resendVerificationCodeAsync: import("@tanstack/react-query").UseMutateAsyncFunction<void, Error, void | ResendVerificationCodeParams, unknown>;
74
+ mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<ResendVerificationCodeResponse, Error, void | ResendVerificationCodeParams, unknown>;
75
+ resendVerificationCode: import("@tanstack/react-query").UseMutateFunction<ResendVerificationCodeResponse, Error, void | ResendVerificationCodeParams, unknown>;
76
+ resendVerificationCodeAsync: import("@tanstack/react-query").UseMutateAsyncFunction<ResendVerificationCodeResponse, Error, void | ResendVerificationCodeParams, unknown>;
74
77
  } | {
75
- data: void;
78
+ data: ResendVerificationCodeResponse;
76
79
  error: null;
77
80
  variables: void | ResendVerificationCodeParams;
78
81
  isError: false;
@@ -80,14 +83,14 @@ export declare const useResendVerificationCode: () => {
80
83
  isPending: false;
81
84
  isSuccess: true;
82
85
  status: "success";
83
- mutate: import("@tanstack/react-query").UseMutateFunction<void, Error, void | ResendVerificationCodeParams, unknown>;
86
+ mutate: import("@tanstack/react-query").UseMutateFunction<ResendVerificationCodeResponse, Error, void | ResendVerificationCodeParams, unknown>;
84
87
  reset: () => void;
85
88
  context: unknown;
86
89
  failureCount: number;
87
90
  failureReason: Error;
88
91
  isPaused: boolean;
89
92
  submittedAt: number;
90
- mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<void, Error, void | ResendVerificationCodeParams, unknown>;
91
- resendVerificationCode: import("@tanstack/react-query").UseMutateFunction<void, Error, void | ResendVerificationCodeParams, unknown>;
92
- resendVerificationCodeAsync: import("@tanstack/react-query").UseMutateAsyncFunction<void, Error, void | ResendVerificationCodeParams, unknown>;
93
+ mutateAsync: import("@tanstack/react-query").UseMutateAsyncFunction<ResendVerificationCodeResponse, Error, void | ResendVerificationCodeParams, unknown>;
94
+ resendVerificationCode: import("@tanstack/react-query").UseMutateFunction<ResendVerificationCodeResponse, Error, void | ResendVerificationCodeParams, unknown>;
95
+ resendVerificationCodeAsync: import("@tanstack/react-query").UseMutateAsyncFunction<ResendVerificationCodeResponse, Error, void | ResendVerificationCodeParams, unknown>;
93
96
  };
@@ -31,10 +31,7 @@ const useResendVerificationCode = () => {
31
31
  return resendVerificationCode(para, args);
32
32
  })
33
33
  });
34
- return renameMutations(
35
- mutation,
36
- "resendVerificationCode"
37
- );
34
+ return renameMutations(mutation, "resendVerificationCode");
38
35
  };
39
36
  export {
40
37
  RESEND_VERIFICATION_CODE_KEY,
@@ -1,8 +1,6 @@
1
1
  import type { UpdatePregenWalletIdentifierParams } from '@getpara/core-sdk';
2
2
  export declare const UPDATE_PREGEN_WALLET_IDENTIFIER_KEY = "UPDATE_PREGEN_WALLET_IDENTIFIER";
3
3
  /**
4
- * @deprecated Use the REST API (`PATCH /v1/wallets/:id`) instead. See https://docs.getpara.com/v2/rest/migrate-from-sdk-pregen
5
- *
6
4
  * React hook for the `updatePregenWalletIdentifier` mutation.
7
5
  *
8
6
  * Returns a mutation result object with all standard fields from `useMutation`, except:
@@ -2,7 +2,9 @@ const createCoreConfigSlice = (set) => ({
2
2
  appName: "",
3
3
  setAppName: (appName) => set({ appName }),
4
4
  farcasterMiniAppConfig: void 0,
5
- setFarcasterMiniAppConfig: (farcasterMiniAppConfig) => set({ farcasterMiniAppConfig })
5
+ setFarcasterMiniAppConfig: (farcasterMiniAppConfig) => set({ farcasterMiniAppConfig }),
6
+ paraConfigVersion: 0,
7
+ bumpParaConfigVersion: () => set((state) => ({ paraConfigVersion: state.paraConfigVersion + 1 }))
6
8
  });
7
9
  export {
8
10
  createCoreConfigSlice
@@ -20,6 +20,8 @@ export interface CoreConfigSlice {
20
20
  setAppName: (_: string) => void;
21
21
  farcasterMiniAppConfig?: FarcasterMiniAppConfig;
22
22
  setFarcasterMiniAppConfig: (_?: FarcasterMiniAppConfig) => void;
23
+ paraConfigVersion: number;
24
+ bumpParaConfigVersion: () => void;
23
25
  }
24
26
  export interface CoreParaStateSlice {
25
27
  paraState?: StateSnapshot;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@getpara/react-core",
3
- "version": "3.0.0-alpha.0",
3
+ "version": "3.0.0",
4
4
  "description": "Platform-agnostic ParaProvider, hooks, and store for Para SDK",
5
5
  "license": "MIT",
6
6
  "main": "dist/index.js",
@@ -82,17 +82,17 @@
82
82
  "test": "vitest run"
83
83
  },
84
84
  "dependencies": {
85
- "@getpara/core-sdk": "3.0.0-alpha.0",
85
+ "@getpara/core-sdk": "3.0.0",
86
86
  "zustand": "^5.0.0"
87
87
  },
88
88
  "devDependencies": {
89
89
  "@cosmjs/amino": "^0.32.0",
90
90
  "@cosmjs/proto-signing": "^0.32.0",
91
- "@getpara/cosmjs-v0-integration": "3.0.0-alpha.0",
92
- "@getpara/ethers-v6-integration": "3.0.0-alpha.0",
93
- "@getpara/solana-signers-v2-integration": "3.0.0-alpha.0",
94
- "@getpara/stellar-sdk-v14-integration": "3.0.0-alpha.0",
95
- "@getpara/viem-v2-integration": "3.0.0-alpha.0",
91
+ "@getpara/cosmjs-v0-integration": "3.0.0",
92
+ "@getpara/ethers-v6-integration": "3.0.0",
93
+ "@getpara/solana-signers-v2-integration": "3.0.0",
94
+ "@getpara/stellar-sdk-v14-integration": "3.0.0",
95
+ "@getpara/viem-v2-integration": "3.0.0",
96
96
  "@solana/signers": "^2.0.0",
97
97
  "@tanstack/react-query": "^5.74.0",
98
98
  "@testing-library/dom": "^10.4.0",
@@ -134,5 +134,5 @@
134
134
  "optional": true
135
135
  }
136
136
  },
137
- "gitHead": "f58e6e365ca63a447edaa44fba3b157e5ca7a368"
137
+ "gitHead": "e6c42e42adfcfadb0114b1ac65ba5203e6274712"
138
138
  }