x402-listing

YourAITools Listings: paid listing services for youraitools.co over x402 (fast-track review $19, Launch $49, Featured 30 days $29; USDC on Base, Polygon, Arbitrum One, Solana); body validated before payment, submissions in a SQLite Durable Object, free status, admin API, manual refunds

Browse source · x402-listing.tar.gz · x402-listing.bundle
commit fad7c6d · fad7c6d4afc3746f55c90dcbf50dc50604a938be
Clone: git clone https://agentgate-source.pages.dev/x402-listing/x402-listing.git (branch main, commit fad7c6d4afc3746f55c90dcbf50dc50604a938be) or curl -O https://agentgate-source.pages.dev/x402-listing/x402-listing.bundle && git clone x402-listing.bundle x402-listing
Home: this repo is hosted here (it was never on GitHub).

YourAITools Listings (x402)

Paid listing services for youraitools.co, a directory of AI tools and x402 APIs, paid in USDC with one x402 call. This is a service, not an agent tool: it is not counted among the YourAITools tools.

Route Price (USDC) What you get
POST /v1/fast-track $19 Review within 24 hours of payment; published on youraitools.co if approved. Refunded if rejected.
POST /v1/launch $49 Fast-track review (24 h) + 30 days Featured from approval + one line in the YourAITools newsletter once it has subscribers (it has none today). Refunded if rejected.
POST /v1/featured $29 Review within 48 hours; Featured (badge, pinned in category, labelled paid placement) on youraitools.co for 30 days from approval. Refunded if rejected.

Payment: x402 v2 (PAYMENT-SIGNATURE) on Base (first), Polygon, Arbitrum One and Solana via the CDP facilitator; x402 v1 (X-PAYMENT) on Base. EVM payee 0x3c1A1E01e790Cd326495631B3b38Bd7068F08d6F, Solana payee FH73WbbUe2UyNzfy72MJs5nT3NxyDf9GrqE7kzjL2Jte. Prepaid credits are not accepted here.

Request

# free check: a valid body answers 402 (payment terms); an invalid one answers 400 and never a 402
curl -i -X POST https://api.youraitools.co/listing/v1/fast-track -H 'content-type: application/json' \
  -d '{"tool_url":"https://example.com","name":"Example Tool","contact_email":"you@example.com","category":"x402 API"}'

Body (JSON): tool_url (https, public domain, ≤500), name (2–80), contact_email (valid, ≤254), category (2–48, letters/numbers/spaces/&/,+.'-), optional description (≤600) and notes (≤1000). Max 8 KB.

{"ref":"LST-T87SH4QTBX","status":"received","tier":"launch","tier_label":"Launch bundle","price_usd":"49.00",
 "name":"Example Tool","tool_url":"https://example.com/","category":"x402 API",
 "review_by":"2026-10-23T17:33:55.851Z","status_url":"https://api.youraitools.co/listing/v1/status/LST-T87SH4QTBX",
 "featured":"30 days on youraitools.co from approval","newsletter":"one mention once the newsletter has subscribers (none yet)",
 "payment":{"network":"eip155:8453","transaction":"0x…","payer":"0x…","amount_usd":"49.00"},
 "next":"A person reviews it …","contact":"hello@youraitools.co (quote your ref)","terms":"…"}

The ref is created in the handler and stored as pending_payment (never public); only after the facilitator settles does the record become received with the payer, network, tx and amount. If settlement fails the record is deleted and no ref is returned.

Status (free)

GET /v1/status/<ref> → {ref, status, tier, name, tool_url, category, received_at, review_by, decided_at, featured_from?, featured_until?, payment:{network, transaction}, refund?:{status, network, due_by, transaction?}, note?}. No contact email and no payer address are shown. Statuses: received, approved, rejected, refund_pending, refunded. 30 lookups/min/IP.

Admin (YourAITools)

Bearer token = Worker secret LISTING_ADMIN_TOKEN; the box copy is in /home/box/crypto-vault/listing-admin.txt (chmod 600, never print it). Unset token → 503 (fails closed); wrong/missing → 401.

Box scripts (token read from the vault into env only): - /workspace/crypto/youraitools/listing_pull.sh [status] → /workspace/crypto/youraitools/listing-submissions.json (chmod 600) + a one-line summary of open items. - /workspace/crypto/youraitools/listing_set_status.sh LST-… approved|rejected|refunded|received ["note"] ["public note"] [--tx HASH] [--no-refund] [--featured-from ISO]

Refunds (manual, never automated)

This Worker never sends funds. A rejected paid listing becomes refund_pending. Per the swarm spending rules, every refund needs Crypto Money Maker's OK before anyone sends it. Then a person sends the same USDC amount to the paying address (refund.to) on the same network (refund.network) within 3 business days, and records it with listing_set_status.sh <ref> refunded "note" --tx <hash>.

Terms (shown on the landing page, in / and summarised in every 402)

Reviewed by a person for legitimacy and fit; payment does not guarantee approval. Rejected = full refund, sent manually in USDC to the paying address on the same network within 3 business days. "Featured" means placement on youraitools.co for 30 days from approval, nothing more. Newsletter mention (Launch) only once the newsletter has subscribers (none today). No promise of traffic, clicks, rankings or revenue. Contact email is used only about the submission and never shown publicly.

Storage

One SQLite-backed Durable Object (REGISTRY, class ListingRegistry, name registry), records under s:<ref>. No KV. Usage counters: StatsCounter DO. Unsettled records older than 10 minutes are dropped.

Tests

npm test (node --test; needs the @x402 deps): 402 on GET/POST/POST {}/valid body with 4 networks and the same terms shape as the live credits 402 (fixture), CDP description length, validation before payment (15 invalid bodies × no payment / v2 / v1 header → 400, facilitator never called), settlement stores payer/network/tx/amount, failed settlement keeps nothing, paid GET/empty POST never settles, v1 path, status without email/payer, admin auth (401/503), admin list, full status flow incl. refund_pending → refunded, no email in any public response, proxied URLs. Also run once in local workerd (wrangler dev --local) against a fake facilitator: real SQLite DO storage for v2 and v1 payments.

Deploy: wrangler deploy (FACILITATOR=cdp; secrets CDP_API_KEY_ID, CDP_API_KEY_SECRET, LISTING_ADMIN_TOKEN via wrangler secret put).


agentgate-source: code mirror on Cloudflare Pages. All repos