Skip to content

Relayer terms

Read current fees and enabled relayer services.

Endpoint
GET /relayer/v1/terms

Examples

cURL
curl -sS "https://api-testnet.veylor.cash/relayer/v1/terms"
HTTP 200
{
  "relayer": "0xd9633572041886fa7584a2e12f36c8c7f1126412",
  "chainId": 11155111,
  "contract": "0x62ce626c5a30528b8ee33145d491785082a6cf8a",
  "contractKind": "windows",
  "minWindow": 1800,
  "lateWindow": 3600,
  "fee": "100000",
  "feeExpiresAt": 1795997487,
  "reverseFunding": {
    "relayAdapt": "0x7e3d929ebd5bdc84d02bd3205c777578f33a214d",
    "token": "0x64c4a5cb09fe0b706d4cf24dc0a45fff275d727c",
    "maker": "0x2bac02b5032e9092493814c705f156b49e288922",
    "maxGasLimit": 4000000,
    "maxGasPriceWei": "20000000000",
    "maxCalldataBytes": 65536,
    "fee": "250000"
  },
  "railgunSends": {
    "railgunAddress": "0zk1qy25r4x4qjhtlfe0k9z22jy9psfm83j4k4fgvqs3pmv4he4ytefm8rv7j6fe3z53lltumh8amd66g2axaej92dmjk6mvnuveqtmmwccdm593pft827p4xpwljug",
    "railgunProxy": "0xecfcf3b4ec647c4ca6d49108b311b7a7c9543fea",
    "token": "0x64c4a5cb09fe0b706d4cf24dc0a45fff275d727c",
    "fee": "500000",
    "feePerUnitGas": "1791697989",
    "feeExpiresAt": 1795994487,
    "maxGasLimit": 3000000,
    "maxGasPriceWei": "20000000000",
    "maxCalldataBytes": 65536
  },
  "deposits": {
    "contract": "0x58324e9a866c9690aca08169d3c67630e84c9019",
    "relayer": "0xedc4c88a3f6ae8130a2c18babbabd8100cc1a446",
    "token": "0x64c4a5cb09fe0b706d4cf24dc0a45fff275d727c",
    "fee": "100000",
    "feeBps": 10,
    "feeExpiresAt": 1795994487,
    "minValue": "2000000",
    "maxValidity": 86400,
    "maxGasPriceWei": "50000000000"
  }
}

Responses

HTTP 200

object · RelayerTerms

Field JSON type Presence Meaning
relayer string · EthereumAddress Required Ethereum address of the swap relayer.
chainId integer · Uint64 Required EIP-155 chain ID of the settlement network.
contract string · EthereumAddress Required Ethereum address of the settlement contract.
contractKind string Optional Contract family reported by the deployment. The window-based client expects windows.
minWindow integer · Uint64 Optional Minimum interval required by the contract between opening and t0, and between t0 and t1, in seconds.
lateWindow integer · Uint64 Optional Length of the forward maker's refund window after t1, in seconds.
fee string · DecimalUint128 Required Swap payout fee in escrow-token base units.
feeExpiresAt integer · UnixSeconds Optional Last time the relayer honors the advertised fee or rate, in Unix seconds.
reverseFunding object · ReverseFundingTerms Optional Present when this relayer sponsors initial reverse funding.
railgunSends object · RailgunSendTerms Optional Present when this relayer broadcasts RAILGUN transfers and withdrawals.
deposits object · DepositTerms Optional Present when this relayer shields tokens received at public deposit addresses.
Fields of reverseFunding
Field JSON type Presence Meaning
relayAdapt string · EthereumAddress Required V2 Relay Adapt contract used for funding.
token string · EthereumAddress Required Ethereum address of the escrow token.
maker string · EthereumAddress Required Maker whose escrow can be funded.
maxGasLimit integer · Uint64 Required Maximum gas units the relayer will submit for one transaction.
maxGasPriceWei string · DecimalUint128 Required Maximum accepted gas price in wei per unit of gas.
maxCalldataBytes integer Required Maximum accepted calldata size in bytes.
fee string · DecimalUint128 Required Fee the funding transaction pays the relayer in escrow-token base units.
Fields of railgunSends
Field JSON type Presence Meaning
railgunAddress string Required Relayer's 0zk address for the broadcaster fee note.
railgunProxy string · EthereumAddress Required Pinned RAILGUN proxy the transaction calls.
token string · EthereumAddress Required Token used to pay the fee.
fee string · DecimalUint128 Required Minimum broadcaster fee in token base units.
feePerUnitGas string · DecimalUint128 Optional Rate in token base units per 10^18 wei of gas cost, including the relayer's margin.
feeExpiresAt integer · UnixSeconds Optional Last time the relayer honors the advertised fee or rate, in Unix seconds.
maxGasLimit integer · Uint64 Required Maximum gas units the relayer will submit for one transaction.
maxGasPriceWei string · DecimalUint128 Required Maximum accepted gas price in wei per unit of gas.
maxCalldataBytes integer Required Maximum accepted calldata size in bytes.
Fields of deposits
Field JSON type Presence Meaning
contract string · EthereumAddress Required Deposits contract the authorization must pay.
relayer string · EthereumAddress Required Ethereum account bound to the deposit fee authorization.
token string · EthereumAddress Required Ethereum address of the escrow token.
fee string · DecimalUint128 Required Base portion in token units. The total is fee plus ceil(value × feeBps / 10000). A rescue pays the base fee alone.
feeBps integer · Uint32 Required Variable portion of the deposit fee, in basis points.
feeExpiresAt integer · UnixSeconds Optional Last time the relayer honors the advertised fee or rate, in Unix seconds.
minValue string · DecimalUint128 Required Minimum deposit in token base units.
maxValidity integer · Uint64 Required Maximum number of seconds from now to validBefore.
maxGasPriceWei string · DecimalUint128 Required Maximum accepted gas price in wei per unit of gas.

Errors

HTTP Body Meaning
503 object · ErrorResponse Temporarily unavailable, throttled, or waiting for a chain event. Respect Retry-After when present. Retry-After — Seconds to wait before retrying, when supplied.
Other object · ErrorResponse Other service error. Read code and error.
ErrorResponse fields
Field JSON type Presence Meaning
code string · ErrorCode Required Machine-readable service error code.
error string Required Human-readable detail.