Obolus is a testnet research product that lets AI agents buy creator-owned context, cite it with verified quotes, and pay the creators whose work grounds the answer.
A user asks a question and sets a USDC atom budget. The agent discovers priced assets, decides which assets are worth paying to read, buys selected assets through x402/Circle Gateway on Arc Testnet, synthesizes a grounded answer, verifies quote-level attribution, computes contribution weights in code, and pays citation royalties through the same x402 path.
This repository is a fork of Circle's arc-nanopayments reference app. Obolus keeps the proven x402/Gateway payment path and adds the context-asset registry, pay/skip reasoning, acquire pipeline, attribution gate, royalty settlement, public receipts, creator pages, creator studio, and real-content ingestion.
Links:
- App: https://obolus-web-production.up.railway.app
- Repository: https://github.com/winsznx/obolus
- X: https://x.com/obolusxyz
- Public research front door at
/and/research. - Public demo video page at
/demovideo, driven byOBOLUS_DEMO_VIDEO_URL. - Live run trace: discovery, pay/skip reasons, tolls, synthesis, attribution, royalties, and receipt link.
- Creator studio at
/studiofor testnet creator onboarding, wallet setup, context-asset registration, and URL ingestion. - Public receipts at
/receipt/[queryId]. - Public creator earning pages at
/creator/[wallet]. - Real x402 toll payments and citation-license royalty payments on Arc Testnet using
@circle-fin/x402-batching. - Live Circle Gateway balance display for creators.
- One real Arc Testnet withdrawal proof path for creator earnings.
- Chunked ingestion for long creator-owned articles, briefs, benchmarks, datasets, checklists, transcripts, API results, and security notes.
- A broader context-asset model that is not limited to articles: protocol notes, implementation checklists, benchmark tables, security memos, market/research briefs, community transcripts, API snapshots, and other niche expert material can all be priced if the creator owns the rights.
- Not mainnet software.
- Not a custody product.
- Not a general web crawler.
- Not a paywall bypass.
- Not a claim that every internet topic is covered. The agent can only answer from registered sources it can discover and afford.
If a query is off-topic for the current corpus, the correct behavior is to skip sources and refuse to synthesize an ungrounded answer.
- Open
/. - Try an on-topic query for the registered corpus, for example an x402, Gateway, EIP-3009, Arc, or agent-payment question.
- Watch the live trace. The important artifact is not only the answer; it is the visible decision ledger.
- Open the receipt and verify:
- skipped assets include specific reasons;
- paid assets have toll settlement ids;
- claims include verbatim supporting quotes;
- contribution weights produce royalty amounts;
- creator pages show live Gateway balances and withdrawal proof where available.
- Try an off-topic query. The correct behavior is to skip irrelevant assets and refuse to synthesize.
- Open
/. - Enter a question and a budget in USDC atoms.
- Choose the funding mode:
- Sponsored testnet mode uses the server-side buyer Gateway wallet.
- Test wallet mode creates a disposable testnet buyer wallet in the browser and funds/deposits it through the local testnet flow.
- Watch the live trace.
- Open the public receipt.
Researchers do not need a wallet in sponsored mode. That is intentional for the hackathon demo: fewer steps creates more real testnet demand. Rate limits and spend caps protect the shared buyer wallet.
- Open
/studio. - Create or connect a testnet creator wallet.
- Register an owned URL or paste owned content.
- Set an x402 toll price in USDC atoms.
- Share
/creator/[wallet]. - Earn:
- a toll when the source is paid to be read;
- a royalty when verified claims in an answer are grounded in that source.
Creator ownership is currently cohort/admin/self-attested. Production would require stronger domain or account verification before opening registration broadly.
Most AI-agent payment demos stop at "an article costs money." Obolus deliberately treats the paid unit as a context asset, because agents need more than prose:
- a benchmark row can decide which protocol stack an agent chooses;
- a security checklist can stop a bad integration;
- a transcript can preserve hard-to-search community knowledge;
- an API snapshot can document behavior before official docs catch up;
- a niche research brief can make an agent useful in markets that general search does not cover.
The product is reusable only when each asset has four properties: the creator opted in, the free metadata is enough for pay/skip reasoning, the paid content can ground claims, and the receipt can show who got paid.
The in-app reader docs live at /docs.
Requirements:
- Node.js 22+
- npm
- Supabase CLI
- Docker Desktop for local Supabase
- Arc Testnet USDC from the Circle faucet
- Groq API key for the LLM calls used by pay/skip, synthesis, attribution, and ingestion summaries
Install dependencies:
npm installCreate environment:
cp .env.example .env.localGenerate base buyer and seller wallets:
npm run generate-walletsStart local Supabase:
npx supabase start
npx supabase migration up
npm run sync:supabase-envFund the buyer wallet on Arc Testnet through the Circle faucet, then deposit USDC into Gateway using the app or scripts.
Run the app:
npm run devOpen:
http://localhost:3000/for research.http://localhost:3000/studiofor creator onboarding.http://localhost:3000/docsfor product docs.
| Variable | Scope | Purpose |
|---|---|---|
NEXT_PUBLIC_SUPABASE_URL |
Public | Supabase project URL. |
NEXT_PUBLIC_SUPABASE_PUBLISHABLE_KEY |
Public | Supabase browser key. |
SUPABASE_SERVICE_ROLE_KEY |
Server only | Server writes for runs, payments, sources, and withdrawals. |
BUYER_ADDRESS |
Server only | Shared testnet buyer wallet address for sponsored research mode. |
BUYER_PRIVATE_KEY |
Server only | Signs x402 payment authorizations in sponsored mode. Testnet only. |
SELLER_ADDRESS |
Server only | Upstream demo seller wallet. Obolus sources use per-source creator wallets. |
SELLER_PRIVATE_KEY |
Server only | Upstream demo seller key. Testnet only. |
GROQ_API_KEY |
Server only | LLM calls through the OpenAI-compatible Groq API. |
OBOLUS_DEMO_VIDEO_URL |
Server/public content | Optional YouTube URL embedded on /demovideo. |
Do not commit .env.local.
Railway production should receive the same server-side secrets through Railway variables, not through committed files. Keep BUYER_PRIVATE_KEY, creator private keys, Supabase service-role keys, and GROQ_API_KEY out of Git history.
Core checks:
npm run lint
npm run build
npm run obolus:test:attributionUseful Obolus scripts:
npm run obolus:discover
npm run obolus:plan
npm run obolus:acquire
npm run obolus:synthesize
npm run obolus:settle
npm run obolus:ingest
npm run obolus:gateway-balance
npm run obolus:withdraw-creator- USDC is handled in integer atomic units.
- x402 tolls and royalties both settle through Circle Gateway.
- The model never computes payout amounts.
- Royalty amounts come from server-side persisted contribution weights.
- Quotes must be verbatim substrings of paid source content before a claim can count toward a royalty.
- Payments are idempotent by
(query_id, source_id, kind). - Per-payment and per-run caps are enforced before signing.
Obolus is strongest when the corpus contains creator-owned, on-topic technical sources. A question like "what do you know about RWA on Mantle" should not pay an x402/EIP-3009 article just because budget is available. It should skip the source, explain why, and avoid inventing an answer.
That behavior is not a failure. It is the product refusing to spend money on irrelevant sources.
This fork preserves the upstream Apache 2.0 license. See LICENSE and NOTICE.