# AliceHub API: full description > AliceHub sells AI services as outcomes (documents, audits, reviews, research, scans) to people and to AI agents, and runs a marketplace for digital goods and agent products. Per-call payments in USDC (x402) are open to any agent with no account: menu and prices at https://api.alicehub.app/x402/catalog. Purchases by people are paused. The agent-to-agent marketplace is for buying and needs a credential created from an existing account (https://alicehub.app/auth.md). This file is the whole machine-readable description of what an agent can do here, how it authenticates, what it costs and what the limits are. The short index is https://api.alicehub.app/llms.txt. ## Identity - Site: https://alicehub.app - API: https://api.alicehub.app - Health: `GET https://api.alicehub.app/health` - Vulnerability disclosure: https://alicehub.app/.well-known/security.txt ## Authentication - Public reads need no credential: service catalog, pricing policy, health, the read-only MCP server and every discovery document. - Marketplace purchases by an agent use a bearer credential `a2a__` created from an existing account for the agent (scopes `browse` and `buy`; per-order and per-day caps are set by the account's owner). Step by step: https://api.alicehub.app/auth.md - Account-plane device login (RFC 8628 style): `POST https://api.alicehub.app/auth/device/start`, a human approves the code in a browser, the agent polls `GET https://api.alicehub.app/auth/device/poll`. The device token is least-privilege and is not accepted on the marketplace agent plane. - Agents never send or receive private keys. A human approves every credential and can revoke it at any time. - Pay-per-call data routes need no account and no credential: the payment itself authorizes the call (see Paid routes). ## What an agent can buy or use - Outcome services (docs, decks, audits, reviews, research, scans): live list with prices `GET https://api.alicehub.app/services`. A credential holder can buy an item marked agent-buyable (ordering direct; quote-only, brief and card-only items are not) through AP2 (intent, cart mandate, signed payment mandate, receipt). Manifest and exact format: https://alicehub.app/.well-known/ap2 - Marketplace listings (digital goods, tokens, agent products): `GET https://api.alicehub.app/a2a/marketplace/listings` (scope `browse`); buy or offer with scope `buy`; the funds are held in escrow until delivery is confirmed. Reference: marketplace API described in https://api.alicehub.app/openapi.json - The marketplace's internal credit (CDT) is spent inside AliceHub and cannot be cashed out or bridged out. Reference price 1 CDT = EUR 0.01. - Read-only MCP server: `POST https://api.alicehub.app/mcp` (streamable HTTP, JSON-RPC, no auth). Tools: catalog_search, service_status, marketplace_listings. Card: https://api.alicehub.app/.well-known/mcp/server-card.json ## Paid routes (x402, USDC on Base) Pay per call in USDC. Network `base`, asset `0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913`, pay to `0x8E0014b38f3300f922100F2973b1bC749A626841`, scheme `exact`. Prices below are read live from the service; the free menu with input and output schemas is `GET https://api.alicehub.app/x402/catalog`. | Route | Method | Price (USDC) | Calls/min per payer | What you get | |---|---|---|---|---| | `/x402/scan` | GET/POST | 0.35 | 10 | Returns one JSON audit of a public https URL made of three reports, security (TLS, headers, cookies, exposed paths), SEO and API hardening, each with score, grade and findings with fixes. Input: url (public https, port 443 or 8443). Example: GET /x402/scan?url=https://example.com | | `/x402/agent-ready` | GET | 0.10 | 6 | Returns a JSON agent-readiness report for one public https site: pass/fail checks with evidence and a fix for each (robots.txt, sitemap, llms.txt, markdown negotiation, A2A agent card, agent skills, MCP server card, OAuth metadata, Web Bot Auth, API catalog, OpenAPI, auth.md, DNS-AID, x402), plus score and grade. Input: url (site origin, port 443). Example: GET /x402/agent-ready?url=https://example.com | | `/x402/headers` | GET/POST | 0.01 | 20 | Returns a JSON security-headers report for one public https page: score, grade, findings with fixes (HSTS, CSP, framing, referrer, version disclosure). Input: url (public https page). Example: GET /x402/headers?url=https://example.com | | `/x402/tls` | GET/POST | 0.01 | 20 | Returns a JSON TLS report for one public https host: certificate trust and expiry, protocol version, handshake; score, grade, findings with fixes. Input: url (public https page on the host). Example: GET /x402/tls?url=https://example.com | | `/x402/privacy` | GET/POST | 0.20 | 10 | Returns a JSON privacy and compliance report for one public https page: third-party trackers, cookie flags, consent tooling, privacy and legal policy links, forms; score, grade, findings with fixes. Input: url (public https page). Example: GET /x402/privacy?url=https://example.com | | `/x402/seo` | GET/POST | 0.10 | 10 | Returns a JSON SEO audit of one public https page: title, description, headings, canonical, robots, structured data, response time; score, grade, findings with fixes. Input: url (public https page). Example: GET /x402/seo?url=https://example.com | | `/x402/deps` | GET/POST | 0.25 | 6 | Returns a JSON list of known vulnerabilities in the dependencies of one public GitHub repository (package-lock.json, package.json, requirements.txt, go.mod, Cargo.lock), checked against the public OSV database and ranked by severity, with the fixed version when one exists. Input: url (https://github.com/owner/repo). Example: GET /x402/deps?url=https://github.com/owner/repo | | `/x402/pkg-vulns` | GET/POST | 0.01 | 20 | Known vulnerabilities of one exact package version from the public OSV database: advisory id, summary, severity when stated, fixed versions, reference URLs, plus the source and retrieval time. Input: ?ecosystem=PyPI/npm/crates.io/Go/RubyGems (aliases python, javascript)&name=requests&version=2.19.0. Not charged if the source is unreachable. | | `/x402/dns-posture` | GET/POST | 0.02 | 20 | DNS and e-mail posture of one public domain: MX, SPF (mechanisms and DNS-lookup count), DMARC policy and tags, DKIM for a selector you supply, name servers, CAA and DNSSEC. Each record comes with the raw text, a parsed form and a pass, warn or absent status with the reason, plus the retrieval time. Input: ?domain=example.com[&dkim_selector=s1] | | `/x402/url-preflight` | GET/POST | 0.01 | 20 | Returns a JSON preflight of one public https URL for an agent about to fetch or cite it: the redirect chain hop by hop (status, location, ms), the final status, content type and declared size, and whether the host's robots.txt (RFC 9309) allows one named crawler to fetch that path. The page body is never returned. Input: url (public https, port 443), optional crawler (product token, default *). Example: GET /x402/url-preflight?url=https://example.com/docs&crawler=GPTBot | | `/x402/ai-policy` | GET/POST | 0.02 | 20 | Returns what one site declares about AI use of a page: the robots.txt verdict per crawler (12 AI crawlers by default), the TDMRep reservation and policy, noai or noimageai in meta robots or X-Robots-Tag, and the raw Content-Signal lines. Per page, unlike the site-wide /x402/agent-ready scan; declared signals, not legal advice. Input: url (public https page, port 443), crawlers (optional, max 12). Example: GET /x402/ai-policy?url=https://example.com/blog/post-1&crawlers=GPTBot,CCBot | | `/x402/pay-check` | GET/POST | 0.01 | 20 | Pre-payment facts about one x402 seller URL: one unpaid GET, the PAYMENT-REQUIRED header and the 402 body decoded, every offer checked against the x402 v2 fields (price in USD, network, asset, payTo format, timeout, resource match, discovery metadata). Facts, not a verdict. Never pays or signs. Port 443 and GET only. Input: ?url=https://seller.example/resource[&max_usd=0.05]. Not charged if the seller cannot be read. | | `/x402/jsonld` | GET/POST | 0.01 | 20 | Structured data of one public https page as clean JSON: every JSON-LD block parsed, @graph flattened, schema.org types counted, nodes for Product, Offer, Article, Organization, Event, BreadcrumbList, FAQPage and more, plus parse errors, missing @context or @type warnings and the OpenGraph keys. Personal data is redacted. Input: ?url= (public https page). Not charged if the page cannot be fetched. | | `/x402/intel` | GET | 0.02 | 30 | Returns one JSON snapshot of the public AliceHub catalogue (up to 50 services with prices) and marketplace listings (up to 60). Input: none. Example: GET /x402/intel. Public data only. | | `/x402/crypto` | GET | 0.02 | 60 | Returns the chain id (0) and head block of AliceHub's own ledger, which is not a public network such as Base or Ethereum, and, when an address is given, the CDT, POC, TKN and CPT balances of that address on it, as JSON. Read-only, no market prices. Input: address (optional, 0x followed by 40 hex characters). Example: GET /x402/crypto?address=0x0000000000000000000000000000000000000000 | Flow: 1. `GET https://api.alicehub.app?` with a valid input and no payment answers HTTP 402: the body lists `accepts[]` (amount, payTo, asset, network) and the `PAYMENT-REQUIRED` header carries the same offer. 2. Sign the payment with a standard x402 client and retry the same request with the `X-PAYMENT` header (the body is x402 version 1). A version 2 client reads its requirement in the `PAYMENT-REQUIRED` response header and uses `PAYMENT-SIGNATURE` only where the rails line below lists it. 3. The service verifies the payment, builds the result, and only then settles. HTTP 200 returns the result and an `X-PAYMENT-RESPONSE` header with the receipt (transaction hash). If the result cannot be built you get 503 and nothing is charged. - Free sample of any priced route: add `?preview=1` (no payment, registry example only). - Every input is read and checked in full before the payment is looked at, so a bad input is never charged: a missing, invalid or out-of-range input, a parameter the route does not read or one given twice, a query string over 2048 characters or a body that is not one JSON object is a free 400 `{error: bad_input, detail (what to fix), code, note}`; a body over 4096 bytes is a free 413. Only a request with no input at all and no payment (how x402 directories probe a route) gets the 402, with `required_parameters` listing each input and its example. - The same authorization sent twice while one is in flight answers 409. A rate limit answers 429 with `retry-after`; nothing is charged. - Aliases of /x402/intel at the same price: `https://api.alicehub.app/api/v1` and `https://api.alicehub.app/api`. - x402 v2: the 402 `PAYMENT-REQUIRED` header lists every enabled rail; retry with `PAYMENT-SIGNATURE`. Rails: base-usdc. Limits and rules specific to the data routes: - `https://api.alicehub.app/x402/scan` and the other URL routes accept public https URLs only (ports 443 and 8443, no credentials, no local or private targets); at most 3 scans run at once (busy answers 503, not charged); `/x402/scan` answers within 50 s (its engines run in parallel, 45 s per engine) and the single-engine URL routes have a 60 s budget; POST bodies are limited to 4096 bytes. - `/x402/crypto` is a read-only chain snapshot (chain id, head block, optional balances of one 0x address); it carries no market prices. ## Limits - Public reads and the MCP server are rate limited per client IP (429 with `retry-after`). - Agent credentials are limited per agent and per client IP; failed credentials are throttled. - During a planned maintenance any route may answer 503 `{error: maintenance, until, message, retry_in_s}` with a `Retry-After` header; `GET /health` stays 200 and carries a `maintenance` field. ## Discovery documents - OpenAPI: https://api.alicehub.app/openapi.json - API catalog: https://api.alicehub.app/.well-known/api-catalog - AI catalog: https://api.alicehub.app/.well-known/ai-catalog.json - A2A agent card: https://alicehub.app/.well-known/agent-card.json - MCP server card: https://api.alicehub.app/.well-known/mcp/server-card.json - MCP registry manifest: https://api.alicehub.app/.well-known/mcp/server.json - Agent skills: https://api.alicehub.app/.well-known/agent-skills/index.json - Auth guide: https://api.alicehub.app/auth.md