Bodega Skill

Give your AI coding agent the power to accept payments. One prompt is all it takes — your agent handles the rest: creates products, builds checkout flows, and processes USDC payments on Base.

How It Works
01

Copy the prompt

Copy the agent prompt below with your email or wallet address. That's your merchant identifier — no API keys needed.

02

Paste into your agent

Give it to Cursor, Claude, Windsurf, or any AI coding agent. The agent reads the skill and knows exactly what to do.

03

Start accepting payments

Your agent installs the SDK, creates products, builds checkout UI, and handles webhooks. You get paid in USDC on Base.

What Your Agent Can Do

Create Products

Your agent can create digital products with names, descriptions, images, and USDC pricing — perpetual or time-limited access.

Build Checkout Flows

Creates hosted checkout sessions with success/cancel URLs. Opens a popup for buyers — no crypto wallet or gas needed.

Generate Payment Links

Create one-time payment links valid for up to 7 days. Perfect for invoices, tips, or ad-hoc payments.

Handle Webhooks

Sets up webhook handlers with signature verification to track payments and grant access automatically.

Verify Access

Check if a wallet has purchased access to a product — built-in gating for your app's premium features.

Upload Images

Upload product images and get hosted URLs back. Your agent can create fully visual product listings.

Agent-Native Payments (x402)

AI agents can autonomously browse and buy products using the x402 protocol. One HTTP request with USDC on Base — no checkout UI needed. See the x402 skill for full docs.

MCP Tools

Connect via MCP to browse products, create checkouts, and verify access directly from Cursor, Claude Desktop, or any MCP-compatible agent. See the MCP skill for setup.

Get Started

Enter your email or 0x wallet address to personalize the prompt below.

Agent Prompt

Paste this into your AI agent

Integrate Bodega payments into this app. Follow these steps exactly in order.

IMPORTANT: Read the full SDK integration guide FIRST before writing any code: /skill.md

Step 0: My merchant identifier: your-email@example.com

Steps:
1. Run: npm install bodega-checkout
2. Add BODEGA_MERCHANT="your-email@example.com" to the .env file
3. Create a server-side API route (e.g. /api/checkout) that:
   a. Imports createClient from "bodega-checkout"
   b. Creates a client: const bodega = createClient({ merchant: process.env.BODEGA_MERCHANT! })
   c. Accepts a productId from the request body
   d. Calls bodega.checkout.create({ productId, successUrl, cancelUrl }) to get a session
   e. Returns session.url to the frontend
4. Create a client-side checkout button that:
   a. Calls your /api/checkout route to get the session URL
   b. Imports openPopup from "bodega-checkout"
   c. Opens the checkout: openPopup(url, { onSuccess, onError, onClose })
5. To create products, use bodega.products.create({ name, priceUsdc, accessType: "perpetual" }) server-side
6. For payment links: create a product, then create a session with expiresIn: 1440 (24 hours) — share session.url

The checkout is a hosted popup — do NOT build any payment UI. Just open the popup with the session URL and handle the callbacks.
npm install bodega-checkout
Works With
CursorClaude CodeWindsurfGitHub CopilotClineAiderAny MCP-compatible agent