I built 53 pay-per-call APIs that AI agents can pay for autonomously (x402 + USDC on Base)

작성자

카테고리:

← 피드로
DEV Community · Laurent HALBRUN · 2026-07-22 개발(SW)

Laurent HALBRUN

AI agents are getting good at deciding what data they need. What they’re bad at is the human paperwork around getting it: creating accounts, clicking email confirmations, pasting API keys, entering a credit card. Every one of those is a wall an autonomous agent can’t climb on its own.

x402 removes that wall. It’s an open payment protocol: the server answers 402 Payment Required, the client pays a few cents in USDC on-chain, and the request goes through — no account, no key, no human. So I built a farm of APIs designed to be consumed exactly that way.

What’s in it

Base URL: https://api.x-402.online/ — the root returns a machine-readable JSON catalog, and there’s an /openapi.json + /llms.txt for agents.

53 endpoints, all pay-per-call in USDC (from $0.005), settled on Base (also accepts Polygon & Arbitrum):

  • Web tooling — clean-markdown extraction, JS-rendered HTML, screenshots, PDF, link/meta extraction
  • French business & open data — company lookup (SIREN/SIRET), full KYB dossiers, financial scores, real-estate AVM & investment scorecards, BODACC, cadastre, DVF sale prices, geocoding, weather, holidays, IBAN validation…
  • UK company data — Companies House profiles, officers, PSC/beneficial owners, one-call KYB verdict
  • US public companies — SEC EDGAR profiles, annual financials, filings, one-call financial snapshot

The friction is the value: these wrap sources that need signup, keys, or heavy parsing (XBRL, registries) and expose them as one clean, payable call.

How an agent uses it

import { wrapFetchWithPaymentFromConfig } from "@x402/fetch";
import { ExactEvmScheme } from "@x402/evm";
import { privateKeyToAccount } from "viem/accounts";

const account = privateKeyToAccount(process.env.AGENT_KEY);
const fetchPaid = wrapFetchWithPaymentFromConfig(fetch, {
  schemes: [{ network: "eip155:8453", client: new ExactEvmScheme(account) }],
});

// The wrapper handles the 402 -> sign -> retry automatically.
const res = await fetchPaid("https://api.x-402.online/v1/us/snapshot?ticker=AAPL");
console.log(await res.json());

Enter fullscreen mode Exit fullscreen mode

The agent’s wallet just needs USDC on Base. No gas needed on the client side — the facilitator settles.

It’s live and already settling

Real on-chain payments are going through today (verifiable on BaseScan). If you’re building agents that need company data, web extraction, or open-data lookups without the account/key dance, point them at https://api.x-402.online/ and let them pay their own way.

Feedback welcome — happy to add endpoints agents actually ask for.

원문에서 계속 ↗

코멘트

답글 남기기

이메일 주소는 공개되지 않습니다. 필수 필드는 *로 표시됩니다