Docs
Launch an API agents pay for
Overview
Connex is the agentic x402 launchpad for APIs. You put a price on an endpoint with x402, launch it here, and AI agents can find it and pay for each call in stablecoins. Agents need no API keys, accounts or invoices.
Connex currently lists 4.1K projects and 119.1K paid endpoints, which handled 904.9K paid calls in the last 30 days.
How x402 works
x402 uses the HTTP status code 402 Payment Required. Payment happens inside a normal HTTP request:
- The agent calls your endpoint.
- Your server answers
402with aPAYMENT-REQUIREDheader: the price, the network and yourpayTowallet. - The agent signs a stablecoin payment and retries with a
PAYMENT-SIGNATUREheader. - A facilitator verifies and settles the payment on-chain, and your server returns the data. The money lands in your wallet.
Prices can be fractions of a cent, so per-call pricing works for data, inference and tools that would never justify a subscription.
Launch your API
Launch without code: hosted gateway
Already have an API? Sign in on the dashboard with email, Google, X or a wallet, paste your API's URL and set a price. If you don't have a wallet, one is created for your earnings. Connex gives you a gateway at connex.fun/x/your-api that answers 402, takes payment in USDG or $CONNEX on Robinhood Chain, and forwards paid requests to your API. Payments go straight to your wallet, and your dashboard shows calls and earnings.
- Your API must be public and use https. Gateways don't follow redirects.
- If your API needs a key, add it as an auth header; it's encrypted and added to every forwarded call.
- Requests up to 1 MB and responses up to 5 MB, with a 25-second timeout.
- A payment only settles when your API answers successfully (status below 400).
Or run x402 on your own server:
01Add x402 to your server
Install the middleware for your framework. This example uses Express; Next.js, Hono, Fastify, Go and Python work the same way.
npm install @x402/express @x402/core @x402/evmimport express from "express";
import { paymentMiddleware, x402ResourceServer } from "@x402/express";
import { ExactEvmScheme } from "@x402/evm/exact/server";
import { HTTPFacilitatorClient } from "@x402/core/server";
const app = express();
const payTo = "0xYourWalletAddress"; // where payments land
// Testnet facilitator (Base Sepolia). Switch to a mainnet facilitator to go live.
const facilitator = new HTTPFacilitatorClient({ url: "https://x402.org/facilitator" });
app.use(
paymentMiddleware(
{
"GET /weather": {
accepts: [{ scheme: "exact", price: "$0.001", network: "eip155:84532", payTo }],
description: "Current weather for a city",
mimeType: "application/json",
},
},
new x402ResourceServer(facilitator).register("eip155:84532", new ExactEvmScheme()),
),
);
app.get("/weather", (req, res) => {
res.json({ city: "Lisbon", weather: "sunny", tempC: 24 });
});
app.listen(4021);This runs on Base Sepolia, a testnet, so you can try it without real money. To go live, switch to a mainnet network (Base is eip155:8453) and a mainnet facilitator, as described in the x402 seller quickstart.
02Check that it answers 402
curl -i http://localhost:4021/weather
# HTTP/1.1 402 Payment Required
# PAYMENT-REQUIRED: <price, network and payTo, base64-encoded>03Launch it on Connex
There are two ways to get a self-hosted endpoint listed:
- Automatically. Register your endpoint with a facilitator that supports Bazaar discovery. Connex imports the Coinbase CDP and PayAI catalogs, groups endpoints by host and shows price, network and usage.
- Through the launch form. Request a launch with your website and a paid endpoint URL. Every request is reviewed by hand, and APIs with a live
402endpoint go fastest.
Connect your agent
01Find APIs to pay for
Search the catalog through the free discovery API. No key is needed and CORS is open, so it works from servers, browsers and agent tools.
const res = await fetch(
"https://connex.fun/api/v1/projects?q=weather&network=base&sort=price&limit=5",
);
const { data } = await res.json();
for (const p of data) {
console.log(p.name, p.website, p.minPriceUsd);
}02Pay per call
Wrap fetch with an x402 client. When an API answers 402, the client pays and retries automatically.
npm install @x402/fetch @x402/core @x402/evm viemimport { wrapFetchWithPayment } from "@x402/fetch";
import { x402Client } from "@x402/core/client";
import { ExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";
// A dedicated agent wallet holding a small USDC balance.
const signer = privateKeyToAccount(process.env.AGENT_PRIVATE_KEY as `0x${string}`);
const client = new x402Client();
client.register("eip155:*", new ExactEvmScheme(signer));
const fetchWithPayment = wrapFetchWithPayment(fetch, client);
// Pays automatically when the API answers 402, then retries.
const res = await fetchWithPayment("https://api.example.com/weather");
console.log(await res.json());Use a dedicated wallet for your agent and keep only a small balance in it. Never commit private keys.
API reference
Read-only JSON, free while in beta. No key, open CORS, and responses are cached for 5 minutes. Full parameters and examples are on the API reference page.
| GET /api/v1/projects | Search and filter projects: q, category, network, sort, page, limit |
| GET /api/v1/projects/{slug} | One project with up to 500 paid endpoints, prices, networks and 30-day calls |
| GET /api/v1/stats | Totals, counts per category and the most common networks |
| GET /api/v1/pro/endpoints | Paid: endpoint-level search with payment details (see Pro API) |
Pro API
GET /api/v1/pro/endpoints searches individual endpoints across the whole catalog and returns what an agent needs to call and pay them: URL, method, price, network, asset, payTo, scheme, facilitator and 30-day usage. Filter by q, network and maxPrice (USD), sort by popular or price, up to 200 results per page. Testnet endpoints are left out.
It is paid per call with x402, so there is no key or account: the agent pays and gets the data.
Coming soon. The Pro API will accept USDG and $CONNEX on Robinhood Chain. Until it is switched on, it answers 503.
import { wrapFetchWithPayment } from "@x402/fetch";
import { x402Client } from "@x402/core/client";
import { ExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";
const signer = privateKeyToAccount(process.env.AGENT_PRIVATE_KEY as `0x${string}`);
const client = new x402Client();
client.register("eip155:*", new ExactEvmScheme(signer));
const fetchWithPayment = wrapFetchWithPayment(fetch, client);
// Endpoints under $0.01 matching "weather", cheapest first
const res = await fetchWithPayment(
"https://connex.fun/api/v1/pro/endpoints?q=weather&maxPrice=0.01&sort=price",
);
const { data } = await res.json(); // url, method, priceUsd, network, payTo, ...Paying with USDG
USDG (Global Dollar) on Robinhood Chain supports EIP-3009, so each payment is a single signature: no approval step and no gas for the agent. Hold USDG on Robinhood Chain and the x402 client above handles the rest.
Paying with $CONNEX
$CONNEX payments run on Robinhood Chain through Permit2. Before the first payment, the paying wallet approves the Permit2 contract (0x000000000022D473030F116dDEE9F6B43aC78BA3) to spend its $CONNEX, once, which needs a little ETH on Robinhood Chain for gas. After that, each call is a signature and the agent pays no gas.
Where the data comes from
- Paid services come from the Coinbase CDP and PayAI Bazaar discovery catalogs. Endpoints are grouped into one project per host, with price, network, facilitator and 30-day usage for each.
- Ecosystem projects such as facilitators, SDKs, extensions and explorers are checked by hand.
- Testnet-only services are hidden. The catalog is re-imported periodically, so new endpoints can take a while to appear.
- Usage numbers are paid calls reported by facilitators over the last 30 days.
$CONNEX token
The official $CONNEX contract address is:
0xe83c85e1ead16fcfe85401e2b337fb4fb5b5cc96$CONNEX can be used to pay for the Pro API once it is switched on.
The address is also in the bar at the top of every page. Always check it on connex.fun before you buy: copies posted elsewhere can be fake. Nothing on this site is financial advice.
Roadmap & status
Live status
Phase 1 is live. In Phase 2, the Connex agent bot for Telegram is complete, and more high-quality official APIs are in progress.
7 official APIs are live and payable in $CONNEX: Token Price, New Launches, Risk Checker, Token Lookup, Tx Explainer, Wallet Portfolio, Page Reader. Try them in the Agent Playground.
Phase 1
Live- Hosted x402 gateways for any APILaunch from the dashboard, get paid per call
- Pay per call in USDG or $CONNEXOn Robinhood Chain, settled by Connex's own facilitator
- Owner dashboard and on-chain receiptsPaid calls, earnings and tx links
- AI agents paying liveCodex demo and the agent payment example
- Agent PlaygroundAsk a question, watch an agent pay in $CONNEX
- Official Connex APIs$CONNEX price, New Launches and Risk Checker
Phase 2
Building now- Connex agent bot for Telegram✓ CompleteLive at t.me/connexagentbot: ask in a DM or a group, with free daily answers
- More high-quality official APIsIn progressIdeas: wallet portfolio, transaction explainer, page to clean text
- Connex MCP serverUp nextClaude, Codex and other agents find and pay APIs natively
- Agent SDK and CLIUp nextWith spend limits built in
- Webhooks and payout analyticsUp nextFor API owners
Later
Later- Base and Solana supportLaunch and pay for APIs on more chains, beyond Robinhood Chain
- APIs from other platformsThe agent uses and pays x402 APIs from platforms like PayAI and Coinbase
- Verified API listings and reputation
Plans can change as we learn what agents and builders need. Follow along on X and Telegram.
FAQ
- Does Connex take a cut of payments?
- No. Agents pay your
payTowallet directly through the facilitator; Connex never holds or routes payments for listed APIs. The only payments Connex receives are for its own Pro API. - Does Connex host my API?
- No. Your API runs wherever it runs today. Connex lists it so agents can find it, with its price, network and usage.
- How much does it cost to launch?
- Nothing. Listing is free, whether your API is picked up from a facilitator catalog or launched through the form.
- Is the discovery API free?
- Yes, with no key. The Pro API adds paid, endpoint-level search, paid per call with x402.
- My listing is wrong or out of date. How do I fix it?
- Open your project page and use Suggest an edit, or send the details through the launch form. Edits are reviewed by hand.
- Which networks are supported?
- Whatever your facilitator supports. Most listed endpoints settle on Base, followed by Solana, Polygon, Arbitrum and others. Testnet-only services are hidden.