GET /arbitrage-opportunity
Cross-DEX arbitrage opportunities with profit calculations.
Cost: $0.03 USDC
Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
| min_profit_usd | float | 1.0 | Minimum net profit filter |
| symbol | string | - | Filter by symbol (optional) |
| limit | int | 10 | Max results |
Request
response = client.get("https://api.foursec.xyz/arbitrage-opportunity?min_profit_usd=1.0")
data = response.json()
Response
{
"total_opportunities": 3,
"scanned_pairs": 25,
"opportunities": [
{
"symbol": "ETH",
"pair": "ETH/USDC",
"buy_dex": "SushiSwap",
"buy_price": 2450.28,
"buy_liquidity_usd": 4200000,
"sell_dex": "BaseSwap",
"sell_price": 2450.35,
"sell_liquidity_usd": 3100000,
"spread_pct": 0.07,
"gross_profit_per_unit": 0.07,
"gas_estimate_usd": 0.02,
"net_profit_per_unit": 0.05,
"max_trade_size_usd": 50000,
"estimated_net_profit_usd": 2.50,
"roi_pct": 0.005,
"timestamp": "2026-07-04T15:30:00Z"
}
]
}
Response Fields
| Field | Type | Description |
|---|---|---|
| total_opportunities | int | Number of opportunities found |
| scanned_pairs | int | Total pairs scanned |
| opportunities | array | List of arbitrage opportunities |
Opportunity Object
| Field | Type | Description |
|---|---|---|
| symbol | string | Token symbol |
| pair | string | Trading pair |
| buy_dex | string | DEX to buy (lowest price) |
| buy_price | float | Buy price |
| buy_liquidity_usd | float | Available liquidity at buy DEX |
| sell_dex | string | DEX to sell (highest price) |
| sell_price | float | Sell price |
| sell_liquidity_usd | float | Available liquidity at sell DEX |
| spread_pct | float | Price spread percentage |
| gross_profit_per_unit | float | Profit per unit before gas |
| gas_estimate_usd | float | Estimated gas cost |
| net_profit_per_unit | float | Profit per unit after gas |
| max_trade_size_usd | float | Max trade size (limited by liquidity) |
| estimated_net_profit_usd | float | Total estimated profit at max size |
| roi_pct | float | Return on investment percentage |
How It Works
- Scans all supported DEX pairs for price differences
- Calculates gross profit (sell_price - buy_price)
- Subtracts estimated gas costs (buy tx + sell tx)
- Filters by min_profit_usd threshold
- Returns sorted by net profit (highest first)
WARNING
Arbitrage opportunities are time-sensitive. Prices may change between detection and execution. Always verify prices before trading.