> ## Documentation Index
> Fetch the complete documentation index at: https://docs.crossmint.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Hooks

> React Native hooks for React Native SDK reference for Crossmint wallets

<Warning>
  **You are viewing docs for the previous version of the Wallets SDK.** We recommend upgrading to V1.
  See the [updated version of this page](/sdk-reference/wallets/react-native/hooks) or the [V1 migration guide](/wallets/guides/migrate-to-v1).
</Warning>

***

## useWallet()

### Returns

<ResponseField name="wallet" type="Wallet | undefined">
  The current wallet instance, or undefined if no wallet is loaded.
</ResponseField>

<ResponseField name="status" type="WalletStatus">
  Current wallet status. Options: `not-loaded` | `in-progress` | `loaded` | `error`.
</ResponseField>

<ResponseField name="getOrCreateWallet" type="(args: WalletArgsFor<Chain>) => Promise<Wallet | undefined>">
  Creates a new wallet or retrieves an existing one.

  <Expandable title="parameters">
    <ResponseField name="chain" type="Chain">
      The blockchain to create the wallet on (e.g. "base-sepolia").
    </ResponseField>

    <ResponseField name="signer" type="SignerConfigForChain">
      The signer configuration (e.g. `{ type: "email" }`).
    </ResponseField>

    <ResponseField name="owner" type="string">
      Optional owner identifier.
    </ResponseField>

    <ResponseField name="alias" type="string">
      Optional wallet alias.
    </ResponseField>

    <ResponseField name="plugins" type="WalletPlugin[]">
      Optional array of wallet plugins.
    </ResponseField>

    <ResponseField name="delegatedSigners" type="DelegatedSigner[]">
      Optional array of delegated signers.
    </ResponseField>
  </Expandable>
</ResponseField>

### Usage

```tsx theme={null}
import { useWallet } from "@crossmint/client-sdk-react-native-ui";
import { View, Text, TouchableOpacity } from "react-native";

function WalletActions() {
    const { wallet, status } = useWallet();

    if (status === "in-progress") return <Text>Loading wallet...</Text>;
    if (!wallet) return <Text>No wallet</Text>;

    const handleSend = async () => {
        const tx = await wallet.send("0x...", "usdc", "10");
        console.log("Transaction:", tx.explorerLink);
    };

    const handleBalances = async () => {
        const balances = await wallet.balances();
        console.log("USDC:", balances.usdc.amount);
        console.log("Native:", balances.nativeToken.amount);
    };

    return (
        <View>
            <Text>Wallet: {wallet.address}</Text>
            <TouchableOpacity onPress={handleBalances}>
                <Text>Check Balances</Text>
            </TouchableOpacity>
            <TouchableOpacity onPress={handleSend}>
                <Text>Send USDC</Text>
            </TouchableOpacity>
        </View>
    );
}
```

***

## useWalletEmailSigner()

Hook for managing email-based signer authentication flows. Provides OTP send/verify functions for wallets using an email signer. Must be used within a CrossmintWalletProvider.

### Returns

<ResponseField name="needsAuth" type="boolean">
  Whether the email signer currently requires authentication (OTP verification).
</ResponseField>

<ResponseField name="sendEmailWithOtp" type="() => Promise<void>">
  Sends a one-time password to the user's email address.
</ResponseField>

<ResponseField name="verifyOtp" type="(otp: string) => Promise<void>">
  Verifies the one-time password entered by the user.
</ResponseField>

<ResponseField name="reject" type="(error: Error) => void">
  Rejects the current authentication request with an error.
</ResponseField>

### Usage

```tsx theme={null}
import { useWalletEmailSigner } from "@crossmint/client-sdk-react-native-ui";
import { View, Text, TextInput, TouchableOpacity } from "react-native";
import { useState } from "react";

function EmailSignerFlow() {
    const { needsAuth, sendEmailWithOtp, verifyOtp, reject } = useWalletEmailSigner();
    const [otp, setOtp] = useState("");

    if (!needsAuth) return null;

    return (
        <View>
            <Text>Email verification required</Text>
            <TouchableOpacity onPress={sendEmailWithOtp}>
                <Text>Send OTP</Text>
            </TouchableOpacity>
            <TextInput value={otp} onChangeText={setOtp} placeholder="Enter OTP" />
            <TouchableOpacity onPress={() => verifyOtp(otp)}>
                <Text>Verify</Text>
            </TouchableOpacity>
            <TouchableOpacity onPress={() => reject(new Error("User cancelled"))}>
                <Text>Cancel</Text>
            </TouchableOpacity>
        </View>
    );
}
```

***

## Wallet Methods

The `wallet` instance returned by `useWallet()` provides methods for token transfers, balances, signing, and more.

Since the React Native SDK wraps the Wallets SDK, see the **[Wallets SDK Reference](/sdk-reference/wallets/v0/typescript/classes/Wallet)** for complete documentation.

| Method                                                                                                                | Description                                                                                                                                                                                                 |
| --------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| [`wallet.addDelegatedSigner()`](/sdk-reference/wallets/v0/typescript/classes/Wallet#adddelegatedsigner)               | Add a delegated signer to the wallet                                                                                                                                                                        |
| [`wallet.balances()`](/sdk-reference/wallets/v0/typescript/classes/Wallet#balances)                                   | Get the wallet balances - always includes USDC and native token (ETH/SOL)                                                                                                                                   |
| [`wallet.delegatedSigners()`](/sdk-reference/wallets/v0/typescript/classes/Wallet#delegatedsigners)                   | List the delegated signers for this wallet.                                                                                                                                                                 |
| [`wallet.experimental_activity()`](/sdk-reference/wallets/v0/typescript/classes/Wallet#experimental-activity)         | Get the wallet activity                                                                                                                                                                                     |
| [`wallet.experimental_nfts()`](/sdk-reference/wallets/v0/typescript/classes/Wallet#experimental-nfts)                 | Get the wallet NFTs                                                                                                                                                                                         |
| [`wallet.experimental_transaction()`](/sdk-reference/wallets/v0/typescript/classes/Wallet#experimental-transaction)   | Get a transaction by id                                                                                                                                                                                     |
| [`wallet.experimental_transactions()`](/sdk-reference/wallets/v0/typescript/classes/Wallet#experimental-transactions) | Get the wallet transactions                                                                                                                                                                                 |
| [`wallet.send()`](/sdk-reference/wallets/v0/typescript/classes/Wallet#send)                                           | Send a token to a wallet or user locator                                                                                                                                                                    |
| [`wallet.stagingFund()`](/sdk-reference/wallets/v0/typescript/classes/Wallet#stagingfund)                             | Funds the wallet with Crossmint's stablecoin (USDXM).  **Note:** This method is only available in staging environments and exclusively supports USDXM tokens. It cannot be used in production environments. |

**Chain-specific:**

* [`EVMWallet`](/sdk-reference/wallets/v0/typescript/classes/EVMWallet) — `getViemClient()`, `sendTransaction()`, `signMessage()`, `signTypedData()`
* [`SolanaWallet`](/sdk-reference/wallets/v0/typescript/classes/SolanaWallet) — `sendTransaction()`
* [`StellarWallet`](/sdk-reference/wallets/v0/typescript/classes/StellarWallet) — `sendTransaction()`
