Skip to main content

Pre-requisites

In this guide, you’ll create your first conversion transaction — converting cryptocurrency to fiat currency. For example, we’ll convert 1000 USDC on Ethereum to USDT on Tron.
1

Create a quote

To create a quote, call the /quotes endpoint. This provides the current conversion rate for the given source and destination assets.Request example
curl --request POST \
  --url https://api.conduit.financial/quotes \
  --header "X-API-Key: your_api_key" \
  --header "X-API-Secret: your_api_secret" \
  --header "Content-Type: application/json" \
  --header "Api-Version: 2024-12-01" \
  --data '{
    "source": {
      "asset": "USDC",
      "network": "ethereum",
      "amount": "1000.00"
    },
    "target": {
      "asset": "USDT",
      "network": "tron"
    }
  }'

Response example
  "id": "quote_2nqjHpNLK6wSNlFyMvZgX8SYeAO",
  "source": {
    "asset": "USDC",
    "network": "ethereum",
    "amount": "1000.000000"
  },
  "target": {
    "asset": "USDT",
    "network": "tron",
    "amount": "998.500000"
  },
  "createdAt": "2024-10-26T02:21:03.742Z",
  "expiresAt": "2024-10-26T02:24:03.742Z"
}
Save this quote ID - you’ll need it for the conversion transaction.
2

Create a conversion transaction

To execute the conversion, call the /transactions endpoint with your quote ID. This creates a conversion transaction between your Conduit custody accounts.
Conversion transactions are used to convert assets or networks within your own Conduit custody — not to send funds to external wallets or third parties.
Request example
curl --request POST \
  --url https://api.conduit.financial/transactions \
  --header "X-API-Key: your_api_key" \
  --header "X-API-Secret: your_api_secret" \
  --header "Content-Type: application/json" \
  --header "Api-Version: 2024-12-01" \
  --data '{
    "type": "conversion",
    "quote": "quote_2nqjHpNLK6wSNlFyMvZgX8SYeAO",
    "source": "acct_3wghbZOojOc7MggcwSXlYl1193K",
    "destination": "acct_3wghbZOojOc7MggcwSXlYl1193K",
    "documents": ["doc_2nqjHpNLK6wSNlFyMvZgX8SYeAO"],
    "purpose": "Other",
    "reference": "TRX#09123A"
  }'
Response example
{
  "type": "conversion",
  "id": "trxn_2abc...",
  "quote": "quote_2nqjHpNLK6wSNlFyMvZgX8SYeAO",
  "source": {
    "id": "acct_3wghbZOojOc7MggcwSXlYl1193K",
    "asset": "USDC",
    "network": "ethereum",
    "amount": "1000.00"
  },
  "destination": {
    "id": "acct_3wghbZOojOc7MggcwSXlYl1193K",
    "asset": "USDT",
    "network": "tron",
    "amount": "998.50"
  },
  "status": "created",
  "createdAt": "2024-10-26T02:21:03.742Z"
}

Monitor Transaction Status

After creating the transaction, you can track its progress using the Transaction Status field.
You listen to webhook events to stay updated as the transaction moves through each stage of processing.
StatusDescription
initializingTransaction is being set up
createdTransaction created successfully
processing conversionConverting assets between networks
completedUSDT delivered to your Tron wallet ✅

🎉 You’re Done!

Once the status iscompleted, your conversion is finalized. What just happened:
  • USDC was withdrawn from your Ethereum custody account.
  • Conduit converted it to USDT at the quoted rate.
  • USDT was deposited into your Tron custody account.
  • All applicable network fees were included in the quote.

Troubleshooting

Use this section to quickly diagnose and resolve common conversion errors.

Quick checklist

  • Use custody account IDs (acct_...) for both source and destination
  • Use a valid, unexpired quote (valid for 3 minutes)
  • Ensure sufficient balance in the source custody account (including network fees)
  • Verify the conversion pair is supported (networks and assets)

Common errors

Invalid source or destination ID

Incorrect: using wallet IDs Request example
{
  "source": "wlt_2kezVryAA3Uw9LJYBiXUV7Pj6gu",
  "destination": "wlt_2nqjHpNLK6wSNlFyMvZgX8SYeAO"
}
Response example
{
"errors": [{
"details": "source: Invalid id format. Expected format: ^acct_[a-zA-Z0-9]{27}$"
}]
}
Solution: Conversion transactions require account IDs (acct_...), not wallet IDs (wlt_...) or bank IDs (bank_...). Use your Conduit custody account IDs for both source and destination. Correct: using account IDs (custody accounts) Request example
{
  "source": "acct_2kezVryAA3Uw9LJYBiXUV7Pj6gu",
  "destination": "acct_2nqjHpNLK6wSNlFyMvZgX8SYeAO"
}

Invalid or expired quote

Request example
{
  "quote": "quote_2nqjHpNLK6wSNlFyMvZgX8SYeAO"
}
Response example
{
  "errors": [{
    "detail": "Quote has expired or is invalid",
    "code": "INVALID_QUOTE"
  }]
}
Solution: Generate a new quote and retry. Quotes expire after 3 minutes.

Insufficient funds

Response example
{
  "errors": [{
    "detail": "Insufficient balance in source wallet",
    "code": "INSUFFICIENT_FUNDS"
  }]
}
Solution: Check your source custody account balance. Ensure you have enough to cover both the conversion amount and network fees.

Incompatible networks

Response example
{
  "errors": [{
    "detail": "Conversion not supported between these networks",
    "code": "UNSUPPORTED_CONVERSION"
  }]
}
Solution: Verify that both networks are supported. Check the quote response for available conversion pairs.

What’s next

API Reference

Also check our API Reference to learn how to create conversion transactions using our API.
I