# Portfolio & Treasury

Unified views of all your assets, stablecoins, and staking positions across every chain — plus patterns for managing funds between hot wallets and cold BTC storage.

### Portfolio overview

See everything you own in one command:

```bash
xverse-wallet portfolio --json
```

To scan multiple accounts (recommended — funds may be on a different account):

```bash
xverse-wallet portfolio --accounts 0-4 --json
```

Output includes tags like `staked`, `unclaimed rewards`, `withdrawing`, `stable`, and `rune` so your agent can categorize holdings.

> **Always use `portfolio --accounts 0-4 --json` first** when searching for funds — assets may be on a different account than the default.

### Stablecoin overview

Unified view of stablecoins across all chains: USDC (Starknet), USDB (Spark), USDCx (Stacks).

```bash
# All stablecoin balances
xverse-wallet cash balance --json

# Receive addresses for each stablecoin
xverse-wallet cash receive --json

# Stablecoin transaction history
xverse-wallet cash history --json
```

### Earning overview

Check staking position, claimable rewards, and suggested next actions:

```bash
xverse-wallet earn status --json
```

For a step-by-step walkthrough of WBTC staking:

```bash
xverse-wallet earn guide
```

***

### Treasury management patterns

#### Sweep to cold BTC vault

Move funds from hot wallets (Spark, Starknet, Stacks) to cold Bitcoin L1 storage:

```bash
# Spark → BTC L1
xverse-wallet spark withdraw --amount 0.01 --speed fast --yes --json

# Starknet WBTC → BTC L1
xverse-wallet swap execute --from starknet:WBTC --to bitcoin:BTC --amount 0.01 --yes --json

# Starknet STRK → BTC L1
xverse-wallet swap execute --from starknet:STRK --to bitcoin:BTC --amount 100 --yes --json

# Stacks STX → BTC L1
xverse-wallet swap execute --from stacks:STX --to bitcoin:BTC --amount 100 --yes --json
```

#### Rebalance between stables and BTC

```bash
# Check current allocation
xverse-wallet portfolio --json
xverse-wallet cash balance --json

# BTC → stables
xverse-wallet swap execute --from bitcoin:BTC --to starknet:USDC --amount 0.01 --yes --json

# Stables → BTC
xverse-wallet swap execute --from starknet:USDC --to bitcoin:BTC --amount 100 --yes --json
```

#### Periodic reward harvesting

```bash
# Check and claim staking rewards
xverse-wallet earn status --json
xverse-wallet starknet staking claim --yes --json

# Convert STRK rewards to BTC
xverse-wallet swap execute --from starknet:STRK --to bitcoin:BTC --amount 50 --yes --json
```

### Buy crypto with fiat

Buy BTC, STX, WBTC, STRK, or USDC using credit card, bank transfer, or Apple Pay via on-ramp providers (MoonPay, Revolut, Banxa, etc.).

```bash
# Simplest — auto-detects everything, opens browser
xverse-wallet fund buy --crypto BTC --amount 100

# Specific provider
xverse-wallet fund buy --crypto BTC --amount 100 --provider moonpay

# Check provider limits
xverse-wallet fund providers --fiat usd --crypto BTC --json

# Get quotes before buying
xverse-wallet fund quote --crypto BTC --amount 100 --json
```
