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

# Worked example

> End-to-end walkthrough — install the CLI, pair your machine, create a wallet, fund it, and execute a sandbox offramp.

This walkthrough takes you from a fresh install through a completed sandbox offramp. All steps run against the sandbox environment.

## Prerequisites

* Node.js 22 or later
* A Veil developer account (sandbox onboarding complete: KYC approved, bank account added). If you haven't done this yet, start with the [Developer sandbox guide](/developers/sandbox/overview).

***

<Steps>
  <Step title="Install the CLI">
    ```bash theme={null}
    npm install -g @useveil/cli
    ```

    Verify:

    ```bash theme={null}
    veil health
    ```

    Expected output: `ok` with the API version.
  </Step>

  <Step title="Pair your machine">
    ```bash theme={null}
    veil login
    ```

    The CLI opens your browser. Approve the pairing request. After confirmation:

    ```
    Paired as you@example.com on device "macbook-pro-a3f2".
    Sandbox mode: ready
    Live mode:    locked
    ```

    Confirm you're in sandbox:

    ```bash theme={null}
    veil mode
    ```

    Expected: `sandbox`.
  </Step>

  <Step title="Create a wallet on Base">
    ```bash theme={null}
    veil wallets create --chain base --name "sandbox-base"
    ```

    The CLI prints the wallet ID and deposit address:

    ```
    Created wallet: sandbox-base (base)
    Address: 0xabc...
    ```

    Save the wallet ID — you'll use it when creating the offramp.
  </Step>

  <Step title="Fund the wallet with test tokens">
    Use the Veil faucet to send USDC\_TEST to your new wallet:

    ```bash theme={null}
    veil wallets fund <wallet-id>
    ```

    The CLI prints the transaction hash and notes that the deposit lands in about 30 seconds. After a moment, the balance appears:

    ```bash theme={null}
    veil wallets show <wallet-id>
    ```

    Look for a USDC\_TEST balance in the output. (The dashboard **Fund** button does the same thing — see [Get test tokens](/developers/sandbox/faucet).)
  </Step>

  <Step title="Quote the offramp">
    Check the rate and fees before committing:

    ```bash theme={null}
    veil offramp quote --token USDC --amount 10 --wallet-id <wallet-id>
    ```

    The CLI prints the exchange rate, output amount, fees, and a balance check.
  </Step>

  <Step title="Create the offramp">
    ```bash theme={null}
    veil offramp create --wallet-id <wallet-id> --amount 10 --token USDC
    ```

    The CLI shows the pre-send summary and asks you to confirm:

    ```
    About to send 10 USDC from wallet <wallet-id> to your primary bank (fee ~0.10 USD, you receive ~9.90 USD).
    ? Continue? (y/N)
    ```

    Enter `y`. This send requires a code, so Veil emails a six-digit one (if your offramp security settings waived it, the CLI would print the transaction details here instead):

    ```
    Sent a 6-digit code to y***@example.com. The code expires in 10 minutes.
    ? Enter the 6-digit code:
    ```

    Enter the code from your email. On success, the CLI prints the transaction details:

    ```
    ID: txn_abc123
    Type: offramp
    Status: pending
    Amount In: 10 USDC
    Amount Out: 9.90 USD
    Fee: 0.10
    ...
    ```
  </Step>

  <Step title="Check the transaction status">
    ```bash theme={null}
    veil offramp show txn_abc123
    ```

    Or list recent transactions:

    ```bash theme={null}
    veil transactions list --type offramp
    ```

    Sandbox offramps settle quickly. Once settled, the status changes to `completed` and the wire reference appears.
  </Step>
</Steps>

***

## What's next

* [Switch to live mode](/cli/environments) with `veil mode live` once you've completed production KYC
* Set up [auto-settle rules](/cli/rules) for unattended conversions
* Use [usernames](/cli/usernames) to route offramps by `@handle`
