Cross-Chain Payments

Pay from any chain.

We handle the rest.

Move funds across networks automatically — no bridges, no manual swaps.

You pay once. We handle routing, bridging, and settlement.

We abstract cross-chain payments into a single API call.

~3s
Settlement time
No canonical bridge delays
1%
Bridge fee
Gas sponsored — $0 for user
Native
USDC only
No wrapped tokens ever
Without RelAI
manually bridge funds
manage liquidity across chains
handle failures and delays
switch wallets per chain
track multiple transactions
With RelAI
fund once on any chain
pay anywhere automatically
zero manual steps
one API call
built-in failure recovery

How it works

01You fund on any supported chain
02Agent initiates a payment request
03RelAI routes funds to the destination chain
04Payment settles automatically — ~3 seconds

Liquidity guard: Pool balance is checked before payment is requested. You are never charged for an unavailable route.

Built for agents

Agents don't need to know chains.
They just send a payment request.
RelAI resolves the route, submits the transaction, and confirms settlement.
No chain switching. No wallet management. No manual steps.

Works with Metered API Access — agents get cross-chain payments automatically with a single API key.

Smart routing

RelAI automatically selects the best path for every transfer.

Fastest routeDestination pool is pre-funded — no waiting for on-chain bridge confirmation
Lowest cost pathGas is sponsored by RelAI facilitator — $0 gas for the user on every chain
Correct destination chainRoute is determined by direction ID — no manual chain selection needed
Auto-rebalancingPools rebalance automatically via Circle CCTP in the background — without blocking payouts

Reliability

Automatic retriesTransient failures are retried automatically before surfacing an error
Fallback routesIf a direct route is unavailable, alternative paths are evaluated
Failure recovery built-inYou are never charged if the destination pool cannot fulfill the transfer
Both tx hashes returnedResponse includes the source payment tx and destination payout tx with explorer links

Supported networks

SolanaSVM
svm-exactLive
SKALE BaseEVM
exactLive
BaseEVM
exactLive

Query GET /v1/bridge/networks at runtime to get available directions. The bridge UI and SDK use this endpoint automatically.

Fees & limits

Bridge fee1% of input amount, minimum $0.01
Gas feesSponsored by RelAI — $0 for user
Minimum$0.05 USDC
Maximum$1 USDC per transaction (beta)
Settlement time~3 seconds on destination chain

Bridge UI

Available at /bridge. Supports Phantom (Solana) and MetaMask / any EVM wallet (SKALE Base).

01Select direction: Solana → SKALE Base or SKALE Base → Solana
02Connect your source wallet
03Enter amount and destination wallet address
04Click Bridge — approve the x402 payment. USDC arrives within seconds.

SDK integration

Use createX402Client from @relai-fi/x402 — it handles the 402 payment automatically.

Solana → SKALE Base (Node.js agent)
import { createX402Client } from '@relai-fi/x402';
import { Keypair } from '@solana/web3.js';

const keypair = Keypair.fromSecretKey(Buffer.from(process.env.SOLANA_KEY!, 'base64'));
const x402 = createX402Client({
  wallets: {
    solana: {
      publicKey: keypair.publicKey,
      signTransaction: async (tx: any) => { tx.sign([keypair]); return tx; },
    },
  },
  defaultHeaders: { 'X-Service-Key': process.env.RELAI_SERVICE_KEY! },
});

const res = await x402.fetch(
  'https://api.relai.fi/v1/bridge/solana-to-skale-base',
  {
    method: 'POST',
    headers: { 'Content-Type': 'application/json' },
    body: JSON.stringify({ amount: 10.0, destinationWallet: '0xYourSkaleBaseAddress' }),
  }
);
const result = await res.json();
// result.paymentTxHash  — Solana payment tx
// result.txHash         — SKALE Base payout tx
console.log('Payout:', result.explorerUrl);
SKALE Base → Solana (Node.js agent)
import { ethers } from 'ethers';
import { createX402Client } from '@relai-fi/x402';

const signer = new ethers.Wallet(process.env.EVM_KEY!, new ethers.JsonRpcProvider(process.env.SKALE_RPC_URL));
const x402 = createX402Client({
  wallets: {
    evm: {
      address: signer.address,
      signTypedData: (domain: any, types: any, message: any) =>
        signer.signTypedData(domain, types, message),
    },
  },
  defaultHeaders: { 'X-Service-Key': process.env.RELAI_SERVICE_KEY! },
});

const res = await x402.fetch(
  'https://api.relai.fi/v1/bridge/skale-base-to-solana',
  {
    method: 'POST',
    headers: { 'Content-Type': 'application/json' },
    body: JSON.stringify({ amount: 5.0, destinationWallet: 'YourSolanaAddress' }),
  }
);
const result = await res.json();
console.log('Payout:', result.explorerUrl); // solscan.io

Management API

Requires X-Service-Key header. Routes are config-driven — new networks appear without changing endpoints.

GET/v1/bridge/networks

List all enabled bridge directions

GET/v1/bridge/quote

Fee and net output for a given amount (params: amount, from, to)

GET/v1/bridge/balances

Current USDC liquidity on all networks

POST/v1/bridge/:direction

Execute bridge. Returns 402 — handled automatically by x402 SDK.

Successful bridge response
{
  "success": true,
  "direction": "solana-to-skale-base",
  "destinationWallet": "0xYourSkaleAddress",
  "amountOutUsd": 9.99,
  "txHash": "0xabc123...",
  "explorerUrl": "https://skale-base-explorer.skalenodes.com/tx/0xabc123...",
  "paymentTxHash": "5Kq7...",
  "paymentExplorerUrl": "https://solscan.io/tx/5Kq7..."
}

Error reference

503insufficient_liquidity

Destination pool cannot fulfill the transfer. Returned before payment is requested — you are never charged. Check /v1/bridge/balances and retry.

402Payment Required

Standard x402 response. Handled automatically by createX402Client.

400Validation error

Invalid amount or destinationWallet format. EVM addresses: 0x... · Solana: base58.

Error handling in SDK
try {
  const res = await x402.fetch('https://api.relai.fi/v1/bridge/solana-to-skale-base', {
    method: 'POST',
    body: JSON.stringify({ amount: 10.0, destinationWallet: '0x...' }),
  });
  const result = await res.json();
} catch (err) {
  if (err.message.includes('insufficient_liquidity')) {
    // Check available liquidity and retry later
    const balRes = await fetch('https://api.relai.fi/v1/bridge/balances',
      { headers: { 'X-Service-Key': process.env.RELAI_SERVICE_KEY! } });
    const { balances } = await balRes.json();
    console.log('Available on SKALE Base:', balances['skale-base']);
  }
}
    Cross-Chain Payments (Bridge) — Pay from any chain | RelAI Documentation | RelAI