> For the complete documentation index, see [llms.txt](https://docs.enclave.money/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.enclave.money/integrate-with-enclave-money/embedded-wallet/onboarding-and-account-access.md).

# Onboarding and Account Access

## 1. Import useWallet hook to access embedded wallet functions

```tsx
import { useWallet } from "@enclavemoney/enclave-wallet-sdk/dist/components/WalletProvider";

export function Page() {
     const {
          isLoggedIn,
          username,
          connect,
          walletSDK,
          disconnect,
     } = useWallet();

     return (
          <div>
               <!-- -->
               {
                    isLoggedIn ? 
                    <div>
                         <button onClick = {() => walletSDK.openWalletModal()}>Welcome {username}</button>
                         <button onClick = {() => disconnect()}>Log Out</button>
                    </div> :
                    <div>
                         <button onClick = {() => connect()}>Log In</button>
                    </div>
               }
          </div>
     )
     
}
```

### 1.a. Login modal after calling connect()

Calling the **connect()** funtion triggers the modal displayed below where user's can continue onboarding

<figure><img src="/files/fq9JGSqSRdeBJU4b9YwR" alt="" width="375"><figcaption></figcaption></figure>

### 1.b. Wallet modal after calling walletSDK.openWalletModal()

<figure><img src="/files/uTTd9Q4dSgnntiTfBIZe" alt="" width="375"><figcaption></figcaption></figure>
