Pay-per-use DeFi swap quote with price impact analysis via x402 micropayments on Base.
What it does
The Silverback swap-quote endpoint returns an optimal swap route with price impact analysis for token pairs on Base (chain ID 8453). It does not execute trades — it returns a read-only quote including expected output amount, price impact, fees, and routing information. Payment is $0.01 per call via the x402 micropayment protocol using USDC on Base, Solana, or SKALE.
This endpoint is part of the broader Silverback x402 DeFi Intelligence API, which offers 11 pay-per-use endpoints covering swap execution, technical analysis, DeFi yield intelligence, arbitrage scanning, token security audits, whale tracking, wallet portfolio lookups, liquidity pool analysis, Jupiter DEX quotes (Solana), and holder analytics. All endpoints accept JSON POST bodies (or GET with query params where noted) and return JSON responses with a `success` boolean field.
To call the endpoint, send a POST request with `tokenIn`, `tokenOut`, and `amountIn` fields. Tokens can be specified as symbols (e.g. "WETH", "USDC") or 0x contract addresses. Amounts are in human-readable units (e.g. "1.5" for 1.5 WETH). The initial request returns a 402 Payment Required response with an `accepts` array; after completing the x402 payment flow, resend with the payment proof header to receive the quote. A 15% discount is available when paying with the $BACK token via Permit2 on Base.
Capabilities
Use cases
- —Get a swap quote before executing a trade to evaluate price impact
- —Compare expected output amounts across different token pairs on Base
- —Build agent workflows that check swap economics before committing to execution
- —Monitor price impact for large trades to optimize execution timing
- —Integrate swap pricing into portfolio rebalancing logic
Fit
Best for
- —AI agents needing on-chain swap pricing without executing trades
- —DeFi applications requiring pre-trade price impact analysis
- —Autonomous trading agents evaluating swap routes on Base
- —Developers building agent-driven DeFi workflows with pay-per-use pricing
Not for
- —Executing actual token swaps (use the /swap endpoint instead)
- —Solana DEX quotes (use the /jupiter-quote endpoint instead)
- —Free or subscription-based API access — this is strictly pay-per-call
Quick start
curl -X POST https://silverback-x402.onrender.com/api/v1/swap-quote \
-H "Content-Type: application/json" \
-d '{"tokenIn": "WETH", "tokenOut": "USDC", "amountIn": "1.0"}'Example
Request
{
"tokenIn": "WETH",
"amountIn": "1.0",
"tokenOut": "USDC"
}Endpoint
Quality
Full OpenAPI schema with clear endpoint description, request parameters, and pricing. The endpoint is live (402 challenge captured). However, no example response body is documented, the 402 challenge object was empty (no accepts array details captured), and the external docs link returned a 404. Pricing and capabilities are well-documented in the OpenAPI guidance section.
Warnings
- —No example response schema or sample response is provided in the OpenAPI spec
- —The 402 challenge object captured was empty — accepts array details not available in probe
- —External docs at /docs returned 'Cannot GET /docs' (404)
- —Response format is inferred from description only ('amountOut, priceImpact, fee, route') — no formal schema
Citations
- —Swap quote endpoint costs $0.01 per callhttps://silverback-x402.onrender.com
- —Endpoint returns quote with amountOut, priceImpact, fee, route — does not executehttps://silverback-x402.onrender.com
- —Supports USDC payments on Base, Solana, and SKALE; 15% discount with $BACK tokenhttps://silverback-x402.onrender.com
- —11 pay-per-use endpoints via x402 micropaymentshttps://silverback-x402.onrender.com
- —Token identifiers accept symbols (WETH, USDC) or 0x contract addresseshttps://silverback-x402.onrender.com