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

# Wallet and Onramp Tools

> Most agent sessions start with these two small tools. One tells you where the user's funds live, and the other gives the user a link to buy crypto with fiat.

Both need authentication; see [Authentication](https://docs.openfinance.tech/mcp/authentication.md). Neither one moves funds, so they are safe to call early in a session.

## get\_wallet\_addresses

This tool returns the user's embedded wallet addresses. It takes no arguments:

```json theme={"system"}
{
  "name": "get_wallet_addresses",
  "arguments": {}
}
```

The response has two fields:

| Field | Meaning |
| - | - |
| `ethereum` | The EVM address. It is the same address on every EVM chain, including Ethereum, Base, Arbitrum, Polygon, Optimism and Robinhood Chain |
| `solana` | The Solana address |

Either field can be empty if that wallet is not set up yet. In that case, send the user to [openfinance.tech](https://openfinance.tech) to finish setup.

Use it to:

* **Check the connection.** One call confirms the credentials and the wallet. See [Verifying the connection](https://docs.openfinance.tech/reference/verifying-connection.md).
* **Start a balance check.** Take the addresses, then read holdings one chain at a time with `onchain_get_address_holdings`.
* **Decide whether a transfer is external.** Compare a recipient with these addresses and with the Polymarket deposit wallet from the `polymarket` action `get_deposit_wallet`.

> [!NOTE]
>
> Hyperliquid and Polymarket have their own funding addresses. Use the `hyperliquid` action `get_deposit_address` and the `polymarket` action `get_deposit_wallet` for those.

## get\_onramp\_url

This tool returns a checkout link where the user buys crypto with fiat. The crypto is delivered to the user's own wallet. The agent never signs anything and never sees payment details. Here is a request to buy 100 dollars of USDC on Base:

```json theme={"system"}
{
  "name": "get_onramp_url",
  "arguments": {
    "baseCurrency": "usd",
    "chain": "base",
    "currency": "usdc",
    "amount": 100
  }
}
```

The request takes these fields:

| Field | Meaning |
| - | - |
| `baseCurrency` | The fiat currency the user pays in. It also selects the provider |
| `chain` | The chain to deliver on, for example `ethereum`, `polygon`, `base`, `arbitrum`, `optimism`, `bsc`, `tron` or `solana` |
| `currency` | The token to buy, for example `usdc`, `usdt`, `eth` or `sol` |
| `amount` | The fiat amount to spend |
| `walletAddress` | Optional. Defaults to the user's own wallet for the chosen chain |

The response includes the `provider` and a `url`. Give the URL to the user to open.

### Provider routing

| `baseCurrency` | Provider | Ways to pay |
| - | - | - |
| `inr` | Onramp.money | UPI, IMPS and bank transfer |
| Anything else | Moonpay | Card, Apple Pay, Google Pay and bank transfer |

You do not choose the provider. Set `baseCurrency` and the server routes the request.

### INR pairs

With `baseCurrency: 'inr'`, the token and chain must be one of these pairs or the call is rejected:

| Token | Chains |
| - | - |
| `usdt` | `ethereum`, `polygon`, `bsc`, `tron` |
| `usdc` | `polygon`, `bsc` |
| `eth` | `ethereum`, `polygon` |
| `sol` | `solana` |
| `matic` | `polygon` |
| `bnb`, `busd` | `bsc` |

If the user asks for a pair outside the list, propose a supported one. For example, for USDC with INR on Ethereum, suggest Polygon.

## Tips

* **Do not ask for card or bank details.** The provider collects them on its own page, along with any identity check it requires.
* **Do not poll for payment status.** Confirm delivery by reading the wallet's holdings on the destination chain.
* **Plan the next step.** Funds land in the wallet, not on a venue. For Hyperliquid from INR: buy USDC on Polygon or BNB Chain, bridge to Arbitrum with the [Relay tools](https://docs.openfinance.tech/mcp/tools-relay.md), then deposit.
* **Check other wallets first.** Before suggesting an onramp, check whether the user already holds funds on another chain that could be bridged.

## Next

> [card] [Fund with card or bank](https://docs.openfinance.tech/markets/fund-with-card-or-bank.md)
>
> The plain-language guide.

> [card] [Onchain tools](https://docs.openfinance.tech/mcp/tools-onchain.md)
>
> Read holdings and send tokens.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.