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

# Onramp

> Convert fiat to stablecoins via virtual IBANs tied to autoramp rules. Includes API request/response examples for EUR to USDC flows.

## Use Case

Enable users to onramp **fiat into stablecoins and other digital assets (e.g. BTC)** on various chains.

This works via spinning up virtual IBANs in the names of customers which are tied to automatic onramping rules.

Examples:

* Create a **vIBAN 1** which turns EUR to USDC on Solana address 1
* Create a **vIBAN 2** which turns EUR to USDC on Arbitrum address 1
* Create a **vIBAN 3** which turns EUR to EURC on Arbitrum address 2
* Create a **vIBAN 4** which turns USD to BTC delivered to address 1

## Example Flow

<Steps>
  <Step>
    Max sets up a vIBAN 1 with an `autoramp` which turns EUR to USDC on Solana address 3DkN...BV4Lm
  </Step>

  <Step>
    Max triggers a EUR 1000 transfer from their banking app
  </Step>

  <Step>
    Iron will monitor the vIBAN 1; as soon as funds arrive, 1100 USDC are delivered to 3DkN...BV4Lm
  </Step>

  <Step>
    Max can at any time transfer more funds into this vIBAN 1 and they autoramp to USDC. It is persistent.
  </Step>
</Steps>

## Prerequisites

Every step must complete before moving to the next. Sandbox-only steps are marked.

<Steps>
  <Step title="Customer is Active">
    Your customer must have `Active` status. This means they have completed [identification](/onboarding) (KYC/KYB) and signed all required documents.
  </Step>

  <Step title="Register the recipient wallet address">
    Register the destination wallet via [Crypto Addresses](/crypto-addresses) for [Travel Rule](/travel-rule) compliance. Self-hosted wallets require a signed proof-of-ownership message; hosted wallets require the custodian's DID.

    The wallet you pass in `recipient_account` must match an address you have already registered for this customer.
  </Step>

  <Step title="(Optional) Get a quote">
    If you need a locked rate (and lower-bps fee profiles), request a quote via `GET /autoramps/quote`. See [Quotes](/quotes). Otherwise, the onramp executes at the current mid-market rate.

    Standalone onramp autoramps cannot attach quotes later. If you anticipate needing locked rates over time, start with a quote-source autoramp.
  </Step>

  <Step title="Create the onramp autoramp">
    Create the autoramp via `POST /autoramps` using the registered wallet address as the recipient. See the Implementation example below.
  </Step>

  <Step title="Sandbox: approve the autoramp">
    In Sandbox, the autoramp starts in `Authorized` status. Approve it to enable transaction processing:

    ```bash theme={null}
    curl -X PUT "https://api.sandbox.iron.xyz/api/sandbox/autoramp/<autoramp_id>" \
      -H "Content-Type: application/json" \
      -H "X-API-Key: $API_KEY" \
      -d '"Approved"'
    ```

    In production, autoramps are approved automatically after compliance review.
  </Step>
</Steps>

## Implementation

Follow these example steps to create an autoramp logic for EUR to USDC on Ethereum.

### Request

<CodeGroup>
  ```bash Shell expandable theme={null}
  curl -X POST "https://api.sandbox.iron.xyz/api/autoramps" \
    -H "Content-Type: application/json; charset=utf-8" \
    -H "IDEMPOTENCY-KEY: <your-idempotency-key>" \
    -H "X-API-Key: <your-api-key>" \
    -d '{
      "source_currencies": [{
        "type": "Fiat",
        "code": "EUR"
      }],
      "destination_currency": {
        "type": "Crypto",
        "token": "USDC",
        "blockchain": "Ethereum"
      },
      "recipient_account": {
        "type": "Crypto",
        "chain": "Ethereum",
        "address": "myholdings.eth"
      },
      "customer_id": "123e4567-e89b-12d3-a456-426614174000",
      "source_is_third_party": false
    }'
  ```
</CodeGroup>

### Response

<CodeGroup>
  ```json Shell theme={null}
  {
    "id": "f8f9a8c7-d8b1-4f1a-8f15-7e6c8a1a8e50",
    "status": "Authorized",
    "deposit_rails": [],
    "created_at": "2025-01-20T12:34:56Z"
  }
  ```
</CodeGroup>

<Note>
  `deposit_rails` is empty at `Authorized`. Poll `GET /autoramps/{id}` or subscribe to webhooks until `status = Approved` before sharing deposit details with end users. See [Autoramp Status](/autoramp-status).
</Note>

Once the autoramp reaches `Approved`, the response includes the deposit vIBAN under `deposit_rails`. Share it with the user. vIBANs are named; no specific deposit instructions are required.
