API Documentation
Programmatically search and discover x402 endpoints
Base URL: https://agentindex.netlify.app/api
All endpoints return JSON. Free endpoints require no authentication. Premium endpoints require x402 payment.
Free Endpoints
Search indexed x402 endpoints by keyword, category, or filters.
Query Parameters
Example
GET /api/search?q=crypto&maxPrice=0.05&healthyOnly=true
{
"count": 9,
"results": [
{
"url": "https://example.com/api/prices",
"domain": "example.com",
"description": "Real-time crypto prices",
"priceUsd": 0.02,
"category": "crypto-data",
"health": "healthy",
"tier": "A"
}
]
}
Get aggregate statistics about indexed endpoints.
Response
{
"total": 108,
"healthy": 63,
"healthRate": "58.3%",
"avgPriceUsd": "0.0238",
"uniqueDomains": 48,
"indexed": "2026-01-28T13:45:06.521Z"
}
List all categories and endpoint counts.
{
"categories": {
"ai/ml": 24,
"defi": 18,
"crypto-data": 15,
"content/ipfs": 12,
...
}
}
Premium Endpoints (x402)
These endpoints require x402 payment. They return 402 Payment Required with payment instructions in the response header.
Deep analytics: most reliable endpoints, best value services, price distribution stats.
{
"mostReliable": [...],
"bestValue": [...],
"priceDistribution": {
"min": 0.001,
"max": 0.5,
"avg": 0.024
},
"totalIndexed": 108
}
Get newest endpoints and top-tier rated services.
{
"newest": [...],
"topTier": [...]
}
Compare multiple endpoints side-by-side.
Query Parameters
GET /api/premium/compare?urls=https://api1.com,https://api2.com
AI-powered endpoint recommendation. Describe what you need in plain language.
Query Parameters
GET /api/premium/recommend?need=I need real-time crypto prices&maxPrice=0.05
Detailed reputation and reliability history for a specific endpoint.
Query Parameters
{
"reputation": {
"overallScore": 87,
"uptimePercent": "99.2",
"avgResponseTime": 245,
"trend": "stable"
}
}
Get the top-rated endpoint in each category. One call to find the best across all categories.
{
"leaders": {
"ai/ml": { "url": "...", "score": 95, "price": 0.02 },
"defi": { "url": "...", "score": 92, "price": 0.01 }
}
}
Find highest quality endpoints within your budget. Optimizes quality-per-dollar.
Query Parameters
GET /api/premium/budget?maxPricePerCall=0.02&category=defi
Using x402 Payments
To call premium endpoints, use the @x402/fetch SDK:
import { wrapFetchWithPayment } from '@x402/fetch';
const fetchWithPayment = wrapFetchWithPayment(fetch, client, {
facilitatorUrl: 'https://api.cdp.coinbase.com/platform/v2/x402'
});
const response = await fetchWithPayment(
'https://agentindex.netlify.app/api/premium/analytics'
);
const data = await response.json();
Rate Limits
Free endpoints: 100 requests/minute
Premium endpoints: Unlimited (payment required per call)