| name | monetize-guide |
| description | End-to-end guide for monetizing GPU resources or HTTP services through obol-stack. Covers pre-flight checks, model detection, pricing research, selling via x402, ERC-8004 registration, and verification. Use when the user says 'monetize my machine', 'sell my GPU', or 'expose a paid API' — i.e. selling raw inference or a plain HTTP service. For selling a specialised agent's replies (the higher-margin path), use sub-agent-business instead. |
| metadata | {"openclaw":{"emoji":"🚀","requires":{"bins":["python3"]}}} |
Monetize Guide
Step-by-step guide to expose local GPU resources or HTTP services as x402 payment-gated endpoints with on-chain discovery via ERC-8004.
When to Use
- User says "monetize my machine", "sell my GPU", or "expose my service for payments"
- Setting up a new paid endpoint from scratch
- Need to figure out what to sell and at what price
When NOT to Use
- Managing existing offers (list/status/delete) — use
sell directly
- Buying inference from others — use
buy-x402
- Cluster diagnostics — use
obol-stack
Workflow
Follow these phases in order. Stop and ask the user for confirmation before executing phase 4.
Phase 1: Pre-flight Checks
Verify the environment is ready before proceeding.
obol kubectl get nodes
obol kubectl get clusterrolebinding openclaw-monetize-read-binding -o jsonpath='{.subjects}'
python3 ${OBOL_SKILLS_DIR:-/data/.openclaw/skills}/ethereum-local-wallet/scripts/signer.py accounts
If cluster is not running: Tell the user to run obol stack up first. Do NOT run it yourself — it takes several minutes and changes system state.
If agent has no RBAC subjects: Tell the user to run obol agent init.
If no wallet address: The wallet is created during obol stack up. If missing, the stack may not have completed setup.
Phase 2: Detect What Can Be Sold
For GPU / Inference
curl -s http://localhost:11434/api/tags | python3 -c "
import json, sys
data = json.load(sys.stdin)
for m in data.get('models', []):
size_gb = m.get('size', 0) / 1e9
print(f\" {m['name']:30s} {size_gb:.1f} GB\")
"
Report the available models to the user. If no models are found, suggest they pull one:
ollama pull qwen3.5:4b
ollama pull qwen3.5:9b
ollama pull qwen3.6:27b
For External LAN Resources (GPU servers, vLLM, etc.)
Ask the user if they have a GPU server or inference endpoint on their local network. If yes, get:
- The endpoint URL (e.g.,
http://192.168.0.202:8000/v1)
- The model name served at that endpoint
Verify it's reachable and OpenAI-compatible:
curl -s <ENDPOINT_URL>/models | python3 -c "
import json, sys
data = json.load(sys.stdin)
for m in data.get('data', []):
print(f\" {m['id']}\")
"
If reachable, this endpoint can be sold by bridging it through LiteLLM (see Phase 4).
For HTTP Services (in-cluster)
obol kubectl get svc -A --no-headers | grep -v 'kube-system\|traefik\|x402\|monitoring\|erpc\|obol-frontend'
Ask the user which service they want to expose and on which port.
Phase 3: Research Pricing
Query the ERC-8004 registry to see what comparable services charge.
python3 ${OBOL_SKILLS_DIR:-/data/.openclaw/skills}/discovery/scripts/discovery.py search --limit 10
python3 ${OBOL_SKILLS_DIR:-/data/.openclaw/skills}/discovery/scripts/discovery.py uri <agent_id>
Pricing guidelines (present these to the user with your research):
| Service Type | Typical Range | Notes |
|---|
| LLM inference (small, <4B) | 0.0005–0.002 USDC/req | Fast, low compute |
| LLM inference (medium, 4-14B) | 0.001–0.005 USDC/req | Good quality/cost balance |
| LLM inference (large, >14B) | 0.005–0.02 USDC/req | High quality, slower |
| Data API / indexer | 0.0001–0.001 USDC/req | Depends on query complexity |
| Compute-heavy (GPU hours) | 0.10–1.00 USDC/hour | Fine-tuning, training |
Always present your research and recommendation to the user and ask them to confirm the price before proceeding.
Phase 4: Sell the Service
Only proceed after the user has confirmed the price.
Inference (Ollama model)
obol sell inference <name> \
--model <model_name> \
--price <confirmed_price> \
--register-name "<descriptive name>" \
--register-description "<what the model does>" \
--register-skills natural_language_processing/natural_language_generation/text_completion \
--register-domains technology/data_science
The --wallet and --chain will be auto-resolved (remote-signer wallet, base-sepolia default).
External LAN Resource (GPU server, vLLM, etc.)
Two steps: first bridge the endpoint into LiteLLM, then sell LiteLLM.
obol model setup custom \
--endpoint <full_url_with_v1> \
--model "<model_name_at_endpoint>"
obol sell http <name> \
--upstream litellm \
--port 4000 \
--namespace llm \
--per-request <confirmed_price> \
--wallet <wallet_address> \
--chain base-sepolia \
--health-path /health/liveliness \
--register-name "<descriptive name>" \
--register-description "<what the service does>" \
--register-skills natural_language_processing/natural_language_generation/text_completion \
--register-domains technology/data_science
The --endpoint must include /v1 if the upstream is an OpenAI-compatible server (vLLM, TGI, etc.) — LiteLLM does not append it automatically.
LAN IPs (e.g., http://192.168.0.202:8000/v1) are reachable from inside the k3d cluster without any additional network configuration.
HTTP Service (in-cluster)
obol sell http <name> \
--upstream <service_name> \
--namespace <namespace> \
--port <port> \
--per-request <confirmed_price> \
--chain base-sepolia \
--health-path <health_endpoint> \
--register-name "<descriptive name>" \
--register-description "<what the service does>" \
--register-skills <oasf_skill_path> \
--register-domains <oasf_domain_path>
Phase 5: Wait for Reconciliation
obol sell http now registers by default. Use --no-register only for local
or private-only flows where on-chain discovery is intentionally skipped.
The agent reconciler automatically processes the ServiceOffer through 6 stages.
for i in $(seq 1 8); do
echo "--- Attempt $i ---"
obol sell status <name> -n <namespace> 2>&1 | grep -A1 'type:\|status:\|reason:\|message:'
sleep 15
done
Expected progression:
- ModelReady → True (instant for HTTP, may take minutes if pulling a model)
- UpstreamHealthy → True
- PaymentGateReady → True
- RoutePublished → True
- Registered → True (best-effort, non-blocking)
- Ready → True
If a stage is stuck, check:
obol kubectl logs -l app.kubernetes.io/name=hermes -n hermes-obol-agent --tail=50
obol kubectl get pods -n x402
Phase 6: Verify the Endpoint
obol tunnel status
obol sell test <name> -n <namespace>
TUNNEL_URL=$(obol tunnel status 2>&1 | grep -o 'https://[^ ]*')
curl -s -o /dev/null -w "%{http_code}" "$TUNNEL_URL/services/<name>/health"
curl -s "$TUNNEL_URL/services/<name>/health" | python3 -m json.tool
A 402 response with x402Version: 1 and an accepts array confirms the endpoint is live and payment-gated.
Phase 7: Report to User
Present a summary:
Service monetized successfully!
Name: <name>
Model: <model> (if inference)
Price: <price> USDC per request
Chain: base-sepolia
Wallet: <wallet_address>
Endpoint: <tunnel_url>/services/<name>/v1/chat/completions
Registry: Agent #<id> on ERC-8004 (Base Sepolia)
Buyers can discover this service at:
<tunnel_url>/.well-known/agent-registration.json
To check status: obol sell status <name> -n <namespace>
To stop selling: obol sell stop <name> -n <namespace>
To delete: obol sell delete <name> -n <namespace>
OASF Skills & Domains Reference
Use these when registering for on-chain discovery:
Common skills:
natural_language_processing/natural_language_generation/text_completion — LLM chat
natural_language_processing/text_generation — general text generation
data_management/indexing — data indexing services
data_management/search — search services
devops_mlops/model_versioning — training/fine-tuning
Common domains:
technology/data_science — AI services
research_and_development/scientific_research — ML research
technology/blockchain — blockchain data services
Constraints
- Always confirm pricing with the user — never set a price autonomously
- Do NOT run
obol stack up without explicit user request — it's a long-running infra change
- Do NOT run
obol stack down or obol stack purge — destructive operations
- Registration is best-effort — services become Ready even if on-chain mint fails (wallet may lack gas funds)
- Tunnel URL changes on restart — registration docs auto-update on next reconcile