Skip to content

Commit e006bf4

Browse files
committed
update readme , improve test examples
1 parent 4bd87cf commit e006bf4

21 files changed

Lines changed: 2015 additions & 255 deletions

README.md

Lines changed: 184 additions & 56 deletions
Large diffs are not rendered by default.

docs/CCTP_USAGE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ sim = await client.simulate(
4848
- Cross-chain flows depend on the source and destination networks being supported by the configured gateway/CCTP path.
4949
- Same-chain transfers should not specify a different `destination_chain`.
5050
- Use `wait_for_completion=True` only when the caller is prepared to block for provider-side polling.
51-
- For launch usage, verify network support with Circle’s current chain support before relying on a pair in production.
51+
- Before production use, verify network support with Circle’s current chain support before relying on a pair in production.
5252

5353
## Result Metadata
5454

docs/FEATURES.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -78,9 +78,9 @@ Supported deployment modes:
7878
- Circle Gateway `GatewayWalletBatched` for gasless nanopayment settlement
7979
- self-hosted OmniClaw exact facilitator, started with `omniclaw facilitator exact`
8080

81-
Thirdweb is a priority external integration path because it provides broad EVM facilitator coverage and gas-sponsored settlement. OmniClaw adds buyer-side policy, route selection, SDK/CLI execution surfaces, and operator visibility.
81+
Thirdweb is one supported external integration path for teams that want broad EVM facilitator coverage and gas-sponsored settlement. OmniClaw adds buyer-side policy, route selection, SDK and CLI execution surfaces, and payment visibility on top.
8282

83-
OmniClaw added the self-hosted exact facilitator so teams can support networks and proof environments before they are available through their selected hosted facilitator. This is how Arc Testnet is handled: it remains standard x402 `exact` settlement, with OmniClaw providing the network profile, asset metadata, RPC, and facilitator runtime.
83+
The self-hosted exact facilitator exists so teams can support networks and deployments before they are available through a hosted provider. Arc Testnet is the clearest example: it remains standard x402 `exact` settlement, with OmniClaw providing the network profile, asset metadata, RPC, and facilitator runtime.
8484

8585
See [facilitators.md](facilitators.md) for deployment details.
8686

@@ -116,10 +116,10 @@ The ledger in [ledger/](../src/omniclaw/ledger) tracks payment records and statu
116116

117117
Typical use cases:
118118

119-
- internal observability
119+
- payment observability
120120
- transaction lookup
121121
- reconciliation
122-
- launch debugging
122+
- operational debugging
123123

124124
### Payment Intents
125125

docs/PRODUCTION_HARDENING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,9 +53,9 @@ OmniClaw is facilitator-agnostic. Production deployments should choose the settl
5353
- Thirdweb-backed x402 facilitator for managed gas-sponsored exact settlement across broad EVM coverage
5454
- Circle Gateway `GatewayWalletBatched` for gasless batched nanopayments
5555
- external standard x402 facilitator where the seller already uses one
56-
- self-hosted OmniClaw exact facilitator only when local proof, custom network support, or enterprise self-hosting is required
56+
- self-hosted OmniClaw exact facilitator when local proof, custom network support, or enterprise self-hosting is required
5757

58-
Do not run a self-hosted facilitator by default if a managed facilitator already supports the target flow. The self-hosted path is operational infrastructure, not the primary product wedge.
58+
Use a self-hosted facilitator when it fits the network and operational model. Use a managed facilitator when it already cleanly supports the target flow.
5959

6060
Before production traffic, validate the exact seller path with:
6161

docs/README.md

Lines changed: 26 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ Use this index to choose the right integration path.
1111
| Agent buyer | [Agent Getting Started](agent-getting-started.md) | An agent that pays through `omniclaw-cli` |
1212
| Python buyer | [Developer Guide](developer-guide.md) | A backend service that pays programmatically |
1313
| Vendor / enterprise seller | [Developer Guide](developer-guide.md) | A FastAPI service with paid endpoints through the SDK |
14-
| Operator | [Operator CLI](operator-cli.md) | Financial Policy Engine, policies, and facilitators |
15-
| Release owner | [Production Readiness](production-readiness.md) | Proof checklist and ship status |
14+
| Infrastructure team | [Operator CLI](operator-cli.md) | Financial Policy Engine, policies, and facilitators |
15+
| Maintainer | [Production Readiness](production-readiness.md) | Proof checklist and ship status |
1616

1717
## Buyer Guides
1818

@@ -31,7 +31,7 @@ Use this index to choose the right integration path.
3131
| [B2B SDK Integration](../examples/b2b-sdk-integration/README.md) | Enterprise SDK deployment with Circle, Thirdweb, or self-hosted exact |
3232
| [Vendor Integration](../examples/vendor-integration/README.md) | Production-style vendor API integration |
3333
| [Business Compute](../examples/business-compute/README.md) | Payment-gated compute service |
34-
| [CLI Reference](cli-reference.md) | Agent-owned local service flow with `omniclaw-cli serve` |
34+
| [CLI Reference](cli-reference.md) | Agent-facing paid service flow with `omniclaw-cli serve` |
3535

3636
## Machine Payment Examples
3737

@@ -45,6 +45,29 @@ Use this index to choose the right integration path.
4545
| [Thirdweb HTTP Facilitator](../examples/thirdweb-http-facilitator/README.md) | Thirdweb HTTP facilitator integration |
4646
| [Arc Marketplace Showcase](../examples/arc-marketplace-showcase/README.md) | Visual vendor kiosk with Arc Testnet x402 exact settlement |
4747

48+
## Arc Testnet Quickstart
49+
50+
Run the full Arc marketplace showcase with Docker-reachable service IPs:
51+
52+
```bash
53+
bash scripts/start_arc_marketplace_showcase_docker.sh
54+
```
55+
56+
The buyer key must hold Arc Testnet USDC for the selected paid product, and the seller/facilitator key must hold Arc Testnet gas. The launcher prints balances, product URLs, the exact OmniClaw config, and a lower-cost `$0.10` proof endpoint when the buyer wallet is not funded for the `$0.25` product.
57+
58+
The showcase UI also has a built-in mini buyer agent, so the full demo can run directly from the browser. The kiosk backend proxies inspect/pay actions into the buyer Financial Policy Engine while keeping the policy token server-side.
59+
60+
Defaults:
61+
62+
| Service | URL |
63+
| --- | --- |
64+
| Browser UI | `http://127.0.0.1:8020` |
65+
| Vendor kiosk | `http://172.18.0.51:8020` |
66+
| Buyer policy engine | `http://172.18.0.52:8080` |
67+
| Exact facilitator | `http://172.18.0.50:4022` |
68+
69+
For setup details and ArcLens submission notes, see [Arc Marketplace Showcase](../examples/arc-marketplace-showcase/README.md).
70+
4871
## Operator and Production Docs
4972

5073
| Document | Covers |

docs/agent-getting-started.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@ In that system:
88
- the owner runs the **Financial Policy Engine**
99
- the agent uses `omniclaw-cli` as the **zero-trust execution layer**
1010
- buyers pay with `omniclaw-cli pay`
11-
- agents can expose temporary local paid services with `omniclaw-cli serve`
11+
- agents can expose paid services for other agents or automation with `omniclaw-cli serve`
1212

13-
For vendor, SaaS, or enterprise APIs, use the Python SDK seller middleware instead of `omniclaw-cli serve`. See the [Developer Guide](developer-guide.md).
13+
For vendor, SaaS, or enterprise APIs embedded directly in an application, use the Python SDK seller middleware instead of `omniclaw-cli serve`. See the [Developer Guide](developer-guide.md).
1414

1515
---
1616

@@ -218,7 +218,7 @@ omniclaw-cli serve \
218218

219219
This opens `http://localhost:8000/api/data` that requires a USDC payment to execute `my_service.py` and return its output.
220220

221-
> **Web developer or vendor:** For real API or SaaS products, use the Python SDK inside your FastAPI application instead of `omniclaw-cli serve`. See the [Developer Guide](developer-guide.md).
221+
> **Web developer or vendor:** If the paid route lives inside your application, use the Python SDK inside your FastAPI application instead of `omniclaw-cli serve`. Use `serve` when the seller surface itself is agent-run. See the [Developer Guide](developer-guide.md).
222222
223223
---
224224

docs/agent-skills.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ That full system is larger than the CLI alone:
1919
It is the same CLI for agent-side economic execution:
2020

2121
- buyer side: `omniclaw-cli pay`
22-
- temporary/local seller side: `omniclaw-cli serve`
22+
- seller side for agent-run paid endpoints: `omniclaw-cli serve`
2323

2424
Vendor and enterprise seller APIs should use the Python SDK with `client.sell(...)`.
2525

docs/erc_804_spec.md

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,39 @@
11
# ERC-8004 Trust Notes
22

3-
This file is a historical design note for OmniClaw's trust-layer direction. It is not the canonical API reference and should not be treated as a precise description of the current Financial Policy Engine implementation.
3+
This document explains how ERC-8004 concepts show up in OmniClaw today.
44

5-
Use these docs for the current product surface instead:
5+
It is a trust-layer overview, not the canonical SDK or API reference. For the main product surface, use:
66

77
- [README](../README.md)
8-
- [Developer Guide (SDK)](developer-guide.md)
8+
- [Developer Guide](developer-guide.md)
99
- [API Reference](API_REFERENCE.md)
1010
- [Architecture and Features](FEATURES.md)
1111

12-
## Current Reality
12+
## How OmniClaw Uses ERC-8004
1313

14-
OmniClaw already exposes a trust layer through the Financial Policy Engine:
14+
OmniClaw exposes trust evaluation through the Financial Policy Engine:
1515

1616
- trust checks can run during `pay()` and `simulate()`
1717
- trust behavior is controlled by `check_trust`
1818
- explicit trust checks require a real `OMNICLAW_RPC_URL`
1919
- trust evaluation can approve, hold, or block payment execution
2020

21-
## What This Note Represents
21+
## What The Trust Layer Covers
2222

23-
The earlier internal design work explored:
23+
The trust system is built around:
2424

2525
- ERC-8004 identity lookup
2626
- reputation scoring and weighted trust signals
2727
- policy-based approval, hold, and block behavior
2828
- trust-aware payment execution
2929
- auditability of trust decisions
3030

31-
Those themes still matter, but the exact content of the original internal draft no longer maps cleanly to the current codebase.
31+
## Practical Guidance
3232

33-
## Recommendation
33+
Treat this file as conceptual background.
3434

35-
If this repo keeps evolving quickly, treat trust docs the same way as the rest of the Financial Policy Engine docs:
35+
Use:
3636

37-
- keep implementation details in code and tests
38-
- keep user-facing behavior in the API reference and usage guide
39-
- keep speculative product thinking in the roadmap, not in protocol documentation
37+
- the SDK and API docs for integration details
38+
- the code and tests for implementation behavior
39+
- the roadmap for future trust-layer expansion

docs/facilitators.md

Lines changed: 63 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ OmniClaw's product responsibility:
4848
- enforce buyer policy before money moves
4949
- choose a fundable route
5050
- sign only the allowed action
51-
- preserve logs, limits, and operator visibility
51+
- preserve logs, limits, and payment visibility
5252

5353
That means a seller can use managed facilitator coverage, while the buyer still uses OmniClaw as the policy-controlled execution layer.
5454

@@ -120,6 +120,7 @@ Current route priority:
120120
- use `exact` when the seller supports standard x402 exact settlement
121121
- if the seller supports both and Gateway is not ready, use `exact`
122122
- if no supported route is available, fail clearly before spending
123+
- for direct exact payments, inspect checks the buyer's direct-wallet token balance when the selected EVM network and RPC are known
123124

124125
## Self-Host An Exact Facilitator
125126

@@ -298,14 +299,74 @@ So the operational requirement for an already configured profile is only:
298299

299300
That is a deployment requirement, not a missing architecture requirement.
300301

302+
For Arc Testnet, the buyer key must hold Arc Testnet USDC. The seller/facilitator key must hold Arc Testnet gas because it submits the x402 exact settlement transaction to the USDC contract.
303+
304+
To run only the Arc self-hosted exact facilitator:
305+
306+
```bash
307+
export OMNICLAW_X402_FACILITATOR_PRIVATE_KEY="0xFacilitatorKeyWithArcGas"
308+
bash scripts/start_arc_exact_facilitator.sh
309+
```
310+
311+
Equivalent installed CLI:
312+
313+
```bash
314+
omniclaw facilitator exact \
315+
--network-profile ARC-TESTNET \
316+
--network eip155:5042002 \
317+
--rpc-url https://rpc.testnet.arc.network \
318+
--port 4022
319+
```
320+
321+
The facilitator exposes:
322+
323+
| Endpoint | Purpose |
324+
| --- | --- |
325+
| `GET /supported` | Advertise supported x402 schemes and networks |
326+
| `POST /verify` | Verify a signed x402 payment payload |
327+
| `POST /settle` | Submit settlement on Arc Testnet |
328+
301329
For a visual Arc vendor demo, use the Arc marketplace showcase:
302330

303331
```bash
304-
bash scripts/start_arc_marketplace_showcase.sh
332+
bash scripts/start_arc_marketplace_showcase_docker.sh
305333
```
306334

307335
Runbook: [../examples/arc-marketplace-showcase/README.md](../examples/arc-marketplace-showcase/README.md).
308336

337+
The showcase includes a browser mini buyer agent. It calls the kiosk backend, and the kiosk backend calls the buyer Financial Policy Engine using `ARC_MARKETPLACE_BUYER_ENGINE_URL` and `ARC_MARKETPLACE_BUYER_TOKEN`. This keeps the browser flow simple while the Financial Policy Engine remains the payment authority boundary.
338+
339+
The Docker launcher starts:
340+
341+
| Service | URL |
342+
| --- | --- |
343+
| Browser UI | `http://127.0.0.1:8020` |
344+
| Vendor kiosk | `http://172.18.0.51:8020` |
345+
| Buyer policy engine | `http://172.18.0.52:8080` |
346+
| Exact facilitator | `http://172.18.0.50:4022` |
347+
348+
It also prints the buyer Arc USDC balance, seller Arc gas balance, and the paid product URLs:
349+
350+
| Product | Price | URL |
351+
| --- | --- | --- |
352+
| Prime Market Scan | `$0.25` | `http://172.18.0.51:8020/buy/prime-market-scan` |
353+
| Risk Oracle Brief | `$0.15` | `http://172.18.0.51:8020/buy/risk-oracle-brief` |
354+
| Settlement Receipt Kit | `$0.10` | `http://172.18.0.51:8020/buy/settlement-receipt-kit` |
355+
356+
For ecosystem forms that require a contract address, use the Arc Testnet USDC contract used by x402 exact settlement:
357+
358+
```text
359+
0x3600000000000000000000000000000000000000
360+
```
361+
362+
OmniClaw does not require a custom application contract for this flow. The settlement transaction calls `transferWithAuthorization` on Arc Testnet USDC.
363+
364+
Latest public proof transaction:
365+
366+
```text
367+
https://testnet.arcscan.app/tx/0xd40dc800a54bee4ff80da4709e65cfd3d0346eb1995ebc34fba433a6306b9219
368+
```
369+
309370
## External Facilitators
310371

311372
External facilitators remain first-class. If a seller advertises an `exact` payment requirement using another facilitator, OmniClaw's buyer flow can still pay through the standard x402 SDK path as long as:

docs/omniclaw-cli-skill/SKILL.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name: omniclaw
33
description: >
44
Use this skill whenever an agent needs to pay for an x402 URL, transfer USDC
55
to an address, inspect OmniClaw balances or ledger entries, or expose a
6-
temporary agent-owned paid service with omniclaw-cli serve. OmniClaw is the
6+
paid endpoint for other agents or automation with omniclaw-cli serve. OmniClaw is the
77
Economic Execution and Control Layer for Agentic Systems. The CLI is the
88
zero-trust execution layer for agents. Use this skill for the CLI execution
99
path only, not for vendor SDK integration, owner setup, policy editing, wallet
@@ -31,7 +31,7 @@ Use `omniclaw-cli` only when the task is directly about one of these actions:
3131
- transfer USDC to an address
3232
- inspect wallet, Gateway, or Circle balances
3333
- inspect transaction history
34-
- expose a temporary agent-owned paid endpoint with `serve`
34+
- expose a paid endpoint for other agents or automation with `serve`
3535

3636
Do not use this skill for:
3737

@@ -55,7 +55,7 @@ This skill is specifically about the CLI execution surface.
5555
The same CLI has two agent-side economic roles:
5656

5757
- buyer role: `omniclaw-cli pay`
58-
- temporary/local seller role: `omniclaw-cli serve`
58+
- seller role for agent-run paid endpoints: `omniclaw-cli serve`
5959

6060
Vendor and enterprise seller APIs should use the Python SDK with `client.sell(...)`, not this CLI skill.
6161

@@ -105,7 +105,7 @@ Do not invent or search for them yourself.
105105
1. Use `omniclaw-cli pay --recipient <0xaddress> --amount <usdc>`.
106106
2. Always include `--purpose`.
107107

108-
### For agent-owned local seller tasks
108+
### For agent-run seller tasks
109109

110110
1. Inspect current state with `balance-detail`.
111111
2. Start the paid endpoint with `omniclaw-cli serve`.

0 commit comments

Comments
 (0)