Tool Gateway API
The Tool Gateway is a paid tool marketplace for agents. It fronts Apify’s actor ecosystem as an x402 merchant: your agent pays the gateway in USDC on Avalanche (settled gaslessly by the 0xGasless facilitator), and the gateway runs the actor and returns its output.
Base URL: https://dashboard.0xgasless.com — no API key. Discovery is
free; payment is the auth for runs.
If you use Agentkit, you don’t call this API directly — the
search_tools, call_tool, and browse_web actions wrap it. With
@0xgasless/agent, a single client.x402.payFetch(url) handles
the whole flow. This page is for anyone integrating at the HTTP level.
GET /tools/search — free
Section titled “GET /tools/search — free”Find tools for a task.
curl "https://dashboard.0xgasless.com/tools/search?q=read+web+page&limit=5"| Query param | Description |
|---|---|
q | What you need done. |
limit | Max results (default 10, max 50). |
{ "query": "read web page", "count": 1, "tools": [{ "id": "apify~rag-web-browser", "title": "RAG Web Browser", "description": "…", "stats": { "totalRuns": 1234567 } }]}GET /tools/{id} — free
Section titled “GET /tools/{id} — free”A tool’s detail and this gateway’s price for one run.
curl "https://dashboard.0xgasless.com/tools/apify~rag-web-browser"{ "id": "apify~rag-web-browser", "title": "RAG Web Browser", "price": { "network": "avalanche", "token": "USDC", "atomicUnits": "65000", "usd": 0.065 }}POST /tools/{id}/run — paid (x402)
Section titled “POST /tools/{id}/run — paid (x402)”The paid call, in the standard two-step x402 handshake:
1. Call without payment → 402 with payment requirements:
curl -X POST "https://dashboard.0xgasless.com/tools/apify~rag-web-browser/run" \ -H "Content-Type: application/json" \ -d '{"input": {"query": "https://example.com"}}'{ "x402Version": 1, "accepts": [{ "scheme": "exact", "network": "avalanche", "maxAmountRequired": "65000", "payTo": "0x36C0bae1De4508f657cE59a73386472160142606", "asset": "0xb97ef9ef8734c71904d8002f8b6bc66dd9c48a6e", "resource": "/tools/apify~rag-web-browser/run", "maxTimeoutSeconds": 300 }]}2. Retry with an X-PAYMENT header — the base64-encoded signed x402
envelope (an EIP-3009 transferWithAuthorization signature for the amount).
The gateway settles it via the facilitator, runs the tool, and returns the
dataset:
{ "actor": "apify~rag-web-browser", "transaction": "0x5421c1d0…", "network": "avalanche", "items": [ … ]}The request body’s input object is passed to the tool as-is (shape is
tool-specific — e.g. a crawler wants { "startUrls": [{ "url": "…" }] }).
Networks & pricing
Section titled “Networks & pricing”| Payment networks | avalanche mainnet (default) · avalanche-fuji for testing via ?network=avalanche-fuji |
| Token | USDC (6 decimals) |
| Pricing | The tool’s own marketplace price × a small gateway margin; always visible upfront via GET /tools/{id} |
| Settlement | 0xGasless facilitator — gasless for the payer |
Errors
Section titled “Errors”| Status | Meaning |
|---|---|
402 | No/invalid payment — body contains paymentRequirements (or settlement failed detail). |
403 | The tool is not on the gateway’s curated allowlist. |
404 | Unknown tool id. |
502 | The tool run failed after settlement — the response includes your transaction for support. |