Skip to main content

Use Case

Enable users to swap token 1 into token 2 across various chains. Examples:
  • Setup wallet address 1 which turns incoming USDC on Solana into EURC on Arbitrum
  • Setup wallet address 2 which turns incoming SOL on Solana into USDC on Arbitrum

Example Flow

1
User sets up a wallet address 1 on Solana owned by Iron
2
Now an autoramp is activatedi. which turns all incoming USDC on wallet address 1 into EURC on Arbitrumii. and delivers those into his connected wallet in wallet address 2
3
Now user sends 1000 USDC to wallet address 1
4
As soon as funds hit this address, Iron turns them into EURC on Arbitrum and delivers them to wallet address 2
This flow is a very easy way for applications to integrate bridging and automatic swaps without users having to interact with complex multi-step UIs. Send is the simplest API every wallet and frontend can integrate.

Implementation

Follow these example steps to integrate create an autoramp logic for turning USDC on Solana to USDC on Arbitrum.

Request

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_currency": {
      "type": "Crypto",
      "token": "USDC",
      "blockchain": "Solana"
    },
    "destination_currency": {
      "type": "Crypto",
      "token": "USDC",
      "blockchain": "Arbitrum"
    },
    "recipient_account": {
      "type": "Wallet",
      "blockchain": "Arbitrum",
      "address": "0xaf77d065e77c8cC2239327C5EDb3A432268e5831"
    },
    "customer_id": "123e4567-e89b-12d3-a456-426614174000",
    "source_is_third_party": false
  }'

Response

{
  "id": "d4e3c2b1-a9f8-7654-3210-fedcba987654",
  "status": "Created",
  "deposit_account": {
    "type": "Wallet",
    "id": "abc12345-defg-6789-hijk-9876543210",
    "blockchain": "Solana",
    "address": "savings.sol",
    "currency": {
      "code": "USDC"
    }
  },
  "created_at": "2025-01-20T14:23:45Z"
}
Now you are ready to show the user their custom wallet address which will be auto-connected to this offramp rule. Please also show supported assets for this wallet address (e.g. EURC, USDC). Non-supported assets will be returned to sender. Related Guide: For more details, refer to the API Reference Documentation.