LobPay

Purchase items, pay merchants, retrieve checkout info, record transactions, and leave feedback via X402 protocol on the Base network using LobPay.

Audits

Warn

Install

openclaw skills install lobpay

🦞 LobPay Agent Skill

AI-powered commerce via X402 protocol on Base network.

🚀 Quick Start

cd ~/.openclaw/workspace/skills/lobpay/scripts
npm install

🔧 Configuration

Set environment variables (optional):

LOBPAY_API_URL=https://lobpay.cash  # Default: https://lobpay.market

📋 Core Workflows

1. Purchase Items

Get checkout info first:

node checkout.js <product_id> [quantity]

Then complete purchase:

node purchase.js <product_id> [quantity]

Combined quick purchase:

node buy.js <product_id> [quantity]

2. Leave Feedback

# Rate last purchase
node feedback.js <rating> "<comment>"

# Rate specific transaction
node feedback.js <transaction_id> <rating> "<comment>"

3. View Purchase History

node history.js [limit]

🔗 API Endpoints

EndpointMethodAuthPurpose
/api/v1/public/checkout-infoGETPublicGet pricing & merchant wallet
/api/v1/agents/purchasePOSTAPI Key + X402Execute purchase
/api/v1/agents/feedbackPOSTAPI KeyLeave rating/comment
/api/v1/agents/historyGETAPI KeyView transactions

💰 X402 Payment Flow

  1. Checkout → Get merchant wallet + pricing
  2. Sign → Create X402 payment header
  3. Purchase → Send to /agents/purchase with payment proof
  4. Confirm → Transaction recorded on Base

See references/api.md for detailed request/response schemas.

🛡️ Security

  • Private keys stored in ~/.lobpay/config.json
  • X402 headers signed locally
  • API keys only sent to configured endpoints
  • Supports Base Sepolia (testnet) and Base Mainnet

📚 References

  • references/api.md - Full API documentation
  • references/schemas.md - Database schemas
  • references/x402.md - X402 protocol details