·4 min read

How to Use AgentCard with OpenClaw to Buy Anything Online

A step-by-step guide to giving your OpenClaw agent a virtual card to make purchases. Set up an AgentCard skill, configure spending limits, and let your agent buy things autonomously.

OpenClaw blew up fast — 247,000+ GitHub stars and a skills marketplace (ClawHub) with 13,700+ community skills. We've been watching the OpenClaw ecosystem closely because these agents run locally, accept natural-language instructions, and execute tasks through modular plugins. That's a perfect fit for what we built.

Here's how to give your OpenClaw agent a virtual card to buy things online.

What you need

  • OpenClaw installed and running locally
  • Node.js 18+ for the AgentCard CLI
  • An email address for AgentCard sign-up
  • A payment method (credit card, debit card, or USDC) for buying virtual cards

Step 1: Install the AgentCard CLI

OpenClaw agents execute shell commands through their built-in skill system, so this is straightforward. Install the AgentCard CLI globally:

npm install -g agentcard

Now your OpenClaw agent can call agentcard from its shell.

Step 2: Sign up via the CLI

Your OpenClaw agent can run this command directly, or you can do it yourself:

agentcard signup --email you@example.com

Click the magic link in your inbox. Done. The session token lands at ~/.agentcard/config.json, which your OpenClaw agent can read automatically.

Step 3: Create a virtual card

Tell your OpenClaw agent what you need, and it can handle the card creation:

"I need to buy a domain name. Create an AgentCard with $15 for the purchase."

Your agent will run:

agentcard create --amount 15

This opens a Stripe Checkout page. Pay with a credit card or USDC, and the card is ready in about 4 seconds.

Step 4: Let OpenClaw retrieve the card details

Once the card is provisioned, your agent retrieves the details:

agentcard details <card-id>

OpenClaw gets the 16-digit card number, CVV, and expiry — everything needed for checkout.

Step 5: OpenClaw makes the purchase

This is where it gets fun. OpenClaw's browser automation takes over:

  1. Navigate to the merchant website
  2. Add the item to the cart
  3. Proceed to checkout
  4. Fill in the card details automatically
  5. Complete the purchase

The whole checkout flow, handled. You just watch.

Setting up an OpenClaw skill for AgentCard

If you're going to do this regularly (and honestly, once you try it you will), create a dedicated AgentCard skill in your OpenClaw configuration. Add it to your agent's SOUL.md or skill config:

Skill: AgentCard Purchase
Description: Buy things online using AgentCard virtual cards
Steps:
1. Create a card with the appropriate amount: agentcard create --amount <n>
2. Wait for checkout completion
3. Retrieve card details: agentcard details <card-id>
4. Use card details to complete the purchase at checkout
5. After purchase, check remaining balance: agentcard balance <card-id>

This way, you can simply tell your OpenClaw agent "buy X" and it knows the full workflow.

Security considerations

OpenClaw agents run locally with broad system access. That's powerful, but it means you should be deliberate about spending limits. Our advice:

  • One card per task. A $15 card for a domain. A $25 card for lunch. Don't share cards across purchases.
  • Start small. Test the workflow with $5 before going bigger.
  • Check the balanceagentcard balance <card-id> tells you exactly what was charged.
  • Freeze after use — once the purchase lands, freeze the card.

We built AgentCard around fixed-balance virtual cards specifically for this reason. If your OpenClaw agent hits a prompt injection or goes off the rails, the blast radius is capped at whatever you loaded onto that card. Not your bank account.

Example: buying API credits with OpenClaw

This is one we've actually tested ourselves:

"I need $50 in OpenAI API credits. Create an AgentCard, go to platform.openai.com, and buy credits for my account."

Your OpenClaw agent will:

  1. Run agentcard create --amount 50
  2. Wait for you to complete checkout (or pay with USDC)
  3. Run agentcard details <card-id> to get the virtual card
  4. Navigate to OpenAI's billing page
  5. Enter the card details
  6. Purchase $50 in credits
  7. Report back with confirmation

Get started

Install AgentCard and let your OpenClaw agent buy things:

npm install -g agentcard
agentcard signup --email you@example.com

Tell your OpenClaw agent what you want to buy. It handles the rest. We've processed thousands of agent purchases this way — it works.

Ready to try AgentCard?

Give your AI agent a virtual card in under 60 seconds.

npm install -g agentcard