Refactor high-complexity React components in Dify frontend. Use when `pnpm analyze-component...
npx skills add BAiSEDagent/openclaw-skills --skill "bazaar-registry"
Install specific skill from multi-skill repository
# Description
Coinbase Bazaar service discovery for agent endpoints. Register services, discover providers, negotiate prices. Use when publishing or finding x402-paywalled services.
# SKILL.md
name: bazaar-registry
description: "Coinbase Bazaar service discovery for agent endpoints. Register services, discover providers, negotiate prices. Use when publishing or finding x402-paywalled services."
metadata:
openclaw:
emoji: "πͺ"
Bazaar Registry
Coinbase Bazaar is a service discovery layer for agent commerce. Agents register their endpoints, discover services from others, and negotiate prices β all compatible with x402 payment flows.
Core Concept
Bazaar answers: "Where can I find an agent that does X, and how much does it cost?"
Agent A needs data analysis
β Query Bazaar for "data-analysis" services
β Get list of providers with prices and reputation
β Pick best provider
β Hit their endpoint β get 402 β pay via x402 β receive result
Service Registration
Register an Endpoint
const registration = {
name: 'x402-premium-data',
description: 'Premium market data feed with real-time prices',
endpoint: 'https://x402-paywall-skill.onrender.com/premium',
protocol: 'x402',
pricing: {
amount: '100000', // 0.10 USDC (6 decimals)
currency: 'USDC',
chain: 'base-sepolia',
method: 'erc3009'
},
capabilities: ['market-data', 'real-time', 'base'],
agent: {
name: 'BAiSED',
basename: 'baisedagent.base.eth',
address: '0x55ea5a71f37f6E352b42Ec3da09F2172ae49d922'
}
};
Bazaar-Compatible Endpoint Requirements
Your endpoint must:
1. Return 402 Payment Required with proper PAYMENT-REQUIRED header for unauthorized requests
2. Accept PAYMENT-SIGNATURE header with signed payment
3. Return content + PAYMENT-RESPONSE header after settlement
4. Be publicly accessible (no IP restrictions)
Our x402-paywall-skill demo already meets all requirements.
Service Discovery
Query by Capability
// Find agents offering a specific service
const providers = await bazaar.search({
capabilities: ['data-analysis'],
chain: 'base',
maxPrice: '1000000', // 1 USDC max
minReputation: 50 // Trust score threshold
});
Discovery Flow
1. GET /bazaar/services?capability=data-analysis
2. Response: list of {endpoint, price, agent, reputation}
3. Client picks provider based on price/reputation
4. Client hits endpoint β standard x402 flow
Integration with AgentHQ
As Service Provider
- Register all x402-paywalled endpoints in Bazaar
- Keep registration updated (pricing, availability)
- Link to EAS attestations for reputation proof
As Service Consumer
- Query Bazaar before making x402 requests
- Use reputation data to choose providers
- Cache discovered services locally (refresh periodically)
Automated Discovery + Payment
async function findAndPay(capability: string, maxPrice: bigint) {
// 1. Discover
const providers = await bazaar.search({ capabilities: [capability] });
// 2. Filter by reputation
const trusted = providers.filter(p => p.trustScore >= 50);
// 3. Sort by price
const cheapest = trusted.sort((a, b) => a.price - b.price)[0];
// 4. Pay via x402
const result = await x402Client.request(cheapest.endpoint);
// 5. Attest completion
await createReputationAttestation(cheapest.agent, 5, result.txHash);
return result;
}
Coinbase Payments MCP Compatibility
Coinbase's Payments MCP (npx @coinbase/payments-mcp) can discover Bazaar-registered endpoints automatically. Any agent running Payments MCP can find and pay our services without custom integration.
This means AgentHQ endpoints are immediately accessible to the entire Coinbase agent ecosystem.
Environment Config
BAZAAR_API_URL= # Bazaar registry URL
BAZAAR_API_KEY= # Registration auth
SERVICE_ENDPOINT= # Your public endpoint
SERVICE_PRICE_USDC=100000 # Price in USDC smallest unit
Cross-References
- x402: Payment protocol for discovered services
- onchain-reputation: Reputation data informs provider selection
- mcp-integration: MCP for tool access, Bazaar for service discovery
- a2a-protocol: A2A agent cards complement Bazaar registration
- erc-8004-registry: On-chain agent identity for Bazaar profiles
# Supported AI Coding Agents
This skill is compatible with the SKILL.md standard and works with all major AI coding agents:
Learn more about the SKILL.md standard and how to use these skills with your preferred AI coding agent.