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

# Wallets

> Understanding Monei's unified programmable wallet infrastructure

## Overview

Monei provides a **unified custodial wallet** that is automatically created when you sign up. This single wallet contains multiple subwallets for different assets and chains, giving you one interface to manage fiat, EVM tokens, and Solana assets.

**What you'll learn:**

* How the unified wallet works
* Understanding subwallets
* Viewing balances and portfolios
* Managing transactions across chains

***

## Unified Wallet Architecture

When you create a Monei account, you automatically get one unified wallet that contains:

<CardGroup cols={3}>
  <Card title="Fiat Subwallet" icon="building-columns">
    Nigerian Naira balance with virtual account for deposits
  </Card>

  <Card title="EVM Subwallet" icon="ethereum">
    Single address for all EVM chains (Ethereum, BSC, Polygon, etc.)
  </Card>

  <Card title="Solana Subwallet" icon="s">
    Solana address for SOL and SPL tokens
  </Card>
</CardGroup>

### Key Characteristics

<Tabs>
  <Tab title="Custodial">
    **Monei manages the private keys**

    * No seed phrases to manage
    * Built-in security measures
    * Recovery through KYC verification
    * Insurance coverage
    * Hardware security modules (HSM)

    You authenticate via API key - Monei handles the blockchain interactions securely.
  </Tab>

  <Tab title="Programmable">
    **API-first design**

    * Send tokens programmatically
    * Query balances across all chains
    * Execute swaps and transfers
    * Automate financial operations
    * Build AI agents on top

    Perfect for businesses, platforms, and autonomous systems.
  </Tab>

  <Tab title="Multi-Chain">
    **One wallet, multiple chains**

    * Same EVM address across 9+ chains
    * Separate Solana address
    * Unified balance view
    * Cross-chain operations
    * No network switching needed
  </Tab>
</Tabs>

***

## Getting Your Wallet

Your wallet is automatically created when you sign up. Access it via the API:

<CodeGroup>
  ```javascript Node.js theme={null}
  import MoneiSDK from 'monei-sdk';

  const monei = new MoneiSDK({
    apiKey: process.env.MONEI_API_KEY,
  });

  // Get complete wallet information
  const wallet = await monei.account.me();

  console.log('Naira Balance:', wallet.nairaBalance);
  console.log('Subwallets:', wallet.subwallets.length);

  // Access specific subwallet
  const evmWallet = wallet.subwallets.find(w => w.chain === 'EVM');
  console.log('EVM Address:', evmWallet.publicAddress);

  const solWallet = wallet.subwallets.find(w => w.chain === 'SOLANA');
  console.log('Solana Address:', solWallet.publicAddress);
  ```

  ```python Python theme={null}
  from monei import MoneiClient
  import os

  monei = MoneiClient(
      api_key=os.getenv('MONEI_API_KEY')
  )

  # Get complete wallet information
  wallet = monei.account.me()

  print(f'Naira Balance: {wallet.naira_balance}')
  print(f'Subwallets: {len(wallet.subwallets)}')

  # Access specific subwallet
  evm_wallet = next(w for w in wallet.subwallets if w.chain == 'EVM')
  print(f'EVM Address: {evm_wallet.public_address}')

  sol_wallet = next(w for w in wallet.subwallets if w.chain == 'SOLANA')
  print(f'Solana Address: {sol_wallet.public_address}')
  ```

  ```bash cURL theme={null}
  curl -X GET https://api.monei.cc/api/v1/wallet/me \
    -H "x-api-key: YOUR_API_KEY"
  ```
</CodeGroup>

**Response Structure:**

```json theme={null}
{
  "statusCode": 200,
  "message": "User wallet retreived succesfully",
  "data": {
    "nairaBalance": "1805.00",
    "subwallets": [
      {
        "id": "uuid-here",
        "type": "FIAT",
        "currency": "NGN",
        "balance": 1805,
        "chain": null,
        "publicAddress": null,
        "virtualAccount": {
          "accountNumber": "9907581802",
          "bankName": "Indulge MFB"
        }
      },
      {
        "id": "uuid-here",
        "type": "CRYPTO",
        "currency": "ETH",
        "balance": 0.00008,
        "chain": "EVM",
        "publicAddress": "0x4e7859f17B7A6b3D440D444b3e2157e3806EDA23",
        "evmPortfolio": { /* portfolio data */ }
      },
      {
        "id": "uuid-here",
        "type": "CRYPTO",
        "currency": "",
        "balance": 0,
        "chain": "SOLANA",
        "publicAddress": "6E5g2d1roqFZqL1eQay6Us29hzUKn52Ren5jRiiL3Qi",
        "solPortfolio": { /* portfolio data */ }
      }
    ]
  }
}
```

***

## Fiat Subwallet (Naira)

Your Naira balance with a virtual bank account for easy deposits.

### Virtual Account

<CodeGroup>
  ```javascript Node.js theme={null}
  // Get or create virtual account
  const virtualAccount = await monei.account.createVirtualAccount({
    nin: 'your-nin-number', // National ID Number
    reference: 'optional-reference'
  });

  console.log('Account Number:', virtualAccount.accountNumber);
  console.log('Bank Name:', virtualAccount.bankName);
  console.log('Account Name:', virtualAccount.accountName);

  // Use this account number to receive Naira deposits
  ```

  ```python Python theme={null}
  # Get or create virtual account
  virtual_account = monei.account.create_virtual_account(
      nin='your-nin-number',
      reference='optional-reference'
  )

  print(f'Account Number: {virtual_account.account_number}')
  print(f'Bank Name: {virtual_account.bank_name}')
  ```

  ```bash cURL theme={null}
  curl -X POST https://api.monei.cc/api/v1/wallet/virtual-account \
    -H "x-api-key: YOUR_API_KEY" \
    -H "Content-Type: application/json" \
    -d '{
      "nin": "your-nin-number"
    }'
  ```
</CodeGroup>

### Naira Operations

<CodeGroup>
  ```javascript Node.js theme={null}
  // Send Naira to bank account
  const transfer = await monei.payout.bankTransfer({
    amount: 5000,
    bank: '058', // GTBank bank code
    accountNumber: '0123456789',
    transactionPin: 'your-pin',
    narration: 'Payment for services'
  });

  // Transfer to another Monei user (P2P)
  const p2pTransfer = await monei.payout.peerTransfer({
    receiver: 'user@email.com', // or phone number
    amount: 1000,
    transactionPin: 'your-pin',
    currency: 'NGN'
  });
  ```

  ```python Python theme={null}
  # Send Naira to bank account
  transfer = monei.payout.bank_transfer(
      amount=5000,
      bank='GTBINGLA',
      account_number='0123456789',
      transaction_pin='your-pin',
      narration='Payment for services'
  )

  # Transfer to another Monei user
  p2p_transfer = monei.payout.peer_transfer(
      receiver='user@email.com',
      amount=1000,
      transaction_pin='your-pin',
      currency='NGN'
  )
  ```
</CodeGroup>

***

## EVM Subwallet

One address for all EVM chains - Ethereum, BSC, Polygon, Base, Arbitrum, Optimism, Scroll, Lisk, and Starknet.

### Get EVM Portfolio

<CodeGroup>
  ```javascript Node.js theme={null}
  // Get portfolio for specific chain
  const portfolio = await monei.evm.getPortfolio(56); // BSC chain ID

  console.log('Total Value:', portfolio.totalPortfolioValueUSD);
  console.log('Native Token:', portfolio.nativeToken.symbol);
  console.log('Native Balance:', portfolio.nativeToken.balance);

  // List all ERC-20 tokens
  portfolio.tokens.forEach(token => {
    console.log(`${token.symbol}: ${token.balance} ($${token.balanceUSD})`);
  });
  ```

  ```python Python theme={null}
  # Get portfolio for specific chain
  portfolio = monei.evm.get_portfolio(56)  # BSC chain ID

  print(f'Total Value: ${portfolio.total_portfolio_value_usd}')
  print(f'Native Token: {portfolio.native_token.symbol}')
  print(f'Native Balance: {portfolio.native_token.balance}')

  # List all ERC-20 tokens
  for token in portfolio.tokens:
      print(f'{token.symbol}: {token.balance} (${token.balance_usd})')
  ```

  ```bash cURL theme={null}
  curl https://api.monei.cc/api/v1/evm/portfolio/56 \
    -H "x-api-key: YOUR_API_KEY"
  ```
</CodeGroup>

### Get Supported Networks

<CodeGroup>
  ```javascript Node.js theme={null}
  // Get all supported EVM networks
  const networks = await monei.evm.getSupportedNetworks();

  networks.forEach(network => {
    console.log(`${network.name} (Chain ID: ${network.chainId})`);
    console.log(`Native Token: ${network.nativeToken}`);
    console.log(`Explorer: ${network.blockExplorerUrl}`);
  });
  ```

  ```python Python theme={null}
  # Get all supported networks
  networks = monei.evm.get_supported_networks()

  for network in networks:
      print(f'{network.name} (Chain ID: {network.chain_id})')
      print(f'Native Token: {network.native_token}')
      print(f'Explorer: {network.block_explorer_url}')
  ```
</CodeGroup>

### Send EVM Tokens

<CodeGroup>
  ```javascript Node.js theme={null}
  // Send native token (ETH, BNB, MATIC, etc.)
  const nativeTx = await monei.evm.sendNativeToken({
    to: '0xRecipientAddress',
    amount: '0.01',
    chainId: 56 // BSC
  });

  console.log('Transaction Hash:', nativeTx.txHash);

  // Send ERC-20 token
  const tokenTx = await monei.evm.sendToken({
    to: '0xRecipientAddress',
    tokenAddress: '0xUSDTContractAddress',
    amount: '100',
    chainId: 56
  });

  console.log('Transaction Hash:', tokenTx.txHash);
  ```

  ```python Python theme={null}
  # Send native token
  native_tx = monei.evm.send_native_token(
      to='0xRecipientAddress',
      amount='0.01',
      chain_id=56
  )

  print(f'Transaction Hash: {native_tx.tx_hash}')

  # Send ERC-20 token
  token_tx = monei.evm.send_token(
      to='0xRecipientAddress',
      token_address='0xUSDTContractAddress',
      amount='100',
      chain_id=56
  )
  ```
</CodeGroup>

***

## Solana Subwallet

Your Solana address for SOL and SPL tokens.

### Get Solana Portfolio

<CodeGroup>
  ```javascript Node.js theme={null}
  // Get complete Solana portfolio
  const solPortfolio = await monei.solana.getPortfolio({
    network: 'mainnet-beta' // or 'devnet'
  });

  console.log('SOL Balance:', solPortfolio.nativeBalance);
  console.log('USD Value:', solPortfolio.nativeBalanceUsd);
  console.log('Total Value:', solPortfolio.totalValueUsd);

  // List SPL tokens
  solPortfolio.tokens.forEach(token => {
    console.log(`${token.symbol}: ${token.balance}`);
    if (token.priceUsd) {
      console.log(`  Value: $${token.valueUsd}`);
    }
  });
  ```

  ```python Python theme={null}
  # Get Solana portfolio
  sol_portfolio = monei.solana.get_portfolio(network='mainnet-beta')

  print(f'SOL Balance: {sol_portfolio.native_balance}')
  print(f'USD Value: ${sol_portfolio.native_balance_usd}')
  print(f'Total Value: ${sol_portfolio.total_value_usd}')

  # List SPL tokens
  for token in sol_portfolio.tokens:
      print(f'{token.symbol}: {token.balance}')
      if token.price_usd:
          print(f'  Value: ${token.value_usd}')
  ```

  ```bash cURL theme={null}
  curl https://api.monei.cc/api/v1/solana/portfolio \
    -H "x-api-key: YOUR_API_KEY"
  ```
</CodeGroup>

### Send Solana Tokens

<CodeGroup>
  ```javascript Node.js theme={null}
  // Send SOL
  const solTx = await monei.solana.sendNativeToken({
    to: '5AH3qo1v1EZfT3QKQpSsx1F8W5JyGEVZPcD5DzkX1N1d',
    amount: '0.1',
    network: 'mainnet-beta'
  });

  console.log('Signature:', solTx.signature);

  // Send SPL token
  const splTx = await monei.solana.sendToken({
    to: '5AH3qo1v1EZfT3QKQpSsx1F8W5JyGEVZPcD5DzkX1N1d',
    tokenMintAddress: 'EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v', // USDC
    amount: '10',
    network: 'mainnet-beta'
  });

  console.log('Signature:', splTx.signature);
  ```

  ```python Python theme={null}
  # Send SOL
  sol_tx = monei.solana.send_native_token(
      to='5AH3qo1v1EZfT3QKQpSsx1F8W5JyGEVZPcD5DzkX1N1d',
      amount='0.1',
      network='mainnet-beta'
  )

  print(f'Signature: {sol_tx.signature}')

  # Send SPL token
  spl_tx = monei.solana.send_token(
      to='5AH3qo1v1EZfT3QKQpSsx1F8W5JyGEVZPcD5DzkX1N1d',
      token_mint_address='EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v',
      amount='10',
      network='mainnet-beta'
  )
  ```
</CodeGroup>

***

## Wallet Security

<AccordionGroup>
  <Accordion icon="shield-check" title="Custodial Security">
    **How Monei protects your assets:**

    * Private keys stored in Hardware Security Modules (HSM)
    * Multi-signature protection for large transactions
    * Encrypted at rest and in transit
    * Regular security audits
    * Insurance coverage
    * KYC-based recovery system

    You never handle private keys directly - Monei manages them securely.
  </Accordion>

  <Accordion icon="key" title="API Key Security">
    **Protect your API keys:**

    * Store in environment variables
    * Never commit to version control
    * Use different keys for dev/prod
    * Rotate keys every 90 days
    * Monitor key usage
    * Set IP whitelisting (enterprise)
  </Accordion>

  <Accordion icon="lock" title="Transaction Security">
    **Additional protection layers:**

    * Transaction PIN for withdrawals
    * KYC tier limits (₦200K-₦2M daily)
    * Two-factor authentication
    * Webhook notifications
    * Real-time monitoring
    * Fraud detection
  </Accordion>

  <Accordion icon="bell" title="Recovery">
    **Account recovery options:**

    * Email/phone verification
    * KYC document verification
    * Support team assistance
    * Multi-device access

    <Info>
      Because Monei is custodial, you can recover access through KYC verification even if you lose your credentials.
    </Info>
  </Accordion>
</AccordionGroup>

***

## Understanding Subwallet Types

| Subwallet Type      | Chain  | Purpose            | Key Feature                   |
| ------------------- | ------ | ------------------ | ----------------------------- |
| **FIAT**            | None   | Naira storage      | Virtual bank account          |
| **CRYPTO (EVM)**    | EVM    | Multi-chain tokens | Same address across 9+ chains |
| **CRYPTO (SOLANA)** | Solana | SOL & SPL tokens   | Separate Solana address       |

<Note>
  All subwallets are part of your single unified wallet. You don't create or delete subwallets - they're automatically available.
</Note>

***

## Common Operations

<CardGroup cols={2}>
  <Card title="Check Balances" icon="wallet">
    View balances across all chains and currencies in one API call
  </Card>

  <Card title="Send Transactions" icon="arrow-right">
    Send fiat, native tokens, or ERC-20/SPL tokens programmatically
  </Card>

  <Card title="Receive Payments" icon="arrow-down">
    Share your addresses or virtual account to receive payments
  </Card>

  <Card title="Portfolio Tracking" icon="chart-line">
    Monitor portfolio value and token balances across all chains
  </Card>
</CardGroup>

***

## Best Practices

<AccordionGroup>
  <Accordion icon="shield" title="Security First">
    * Never share API keys
    * Use transaction PINs for withdrawals
    * Enable 2FA for your account
    * Monitor transaction history regularly
    * Set up webhook notifications
  </Accordion>

  <Accordion icon="network-wired" title="Network Selection">
    * Use low-fee networks for small transactions (Polygon, BSC)
    * Consider confirmation time vs. cost
    * Verify recipient network before sending
    * Check gas prices before transactions
  </Accordion>

  <Accordion icon="chart-simple" title="Balance Management">
    * Keep minimum balance for gas fees
    * Monitor KYC tier limits
    * Spread assets across networks as needed
    * Regular balance reconciliation
  </Accordion>
</AccordionGroup>

***

## Next Steps

<CardGroup cols={2}>
  <Card title="Transactions" icon="arrow-right-arrow-left" href="/core-concepts/transactions">
    Learn how to manage and track transactions
  </Card>

  <Card title="Networks" icon="network-wired" href="/core-concepts/networks">
    Understand supported blockchain networks
  </Card>

  <Card title="Naira Wallet Operations" icon="building-columns" href="/naira-wallet/deposits">
    Deep dive into fiat wallet management
  </Card>

  <Card title="EVM Operations" icon="ethereum" href="/evm-blockchain/wallet-operations">
    Complete EVM wallet operations guide
  </Card>
</CardGroup>
