
OpenClaw: Building an Autonomous AI Business That Makes Money
Table of Contents
TL;DR
- I turned an OpenClaw bot into a profit-generating business in just weeks.
- The key pieces: a 3-layer memory system, cron jobs, a crypto wallet, Stripe integration, and a custom token.
- I’ll show you the exact steps I followed, the tools I used, and how to avoid common pitfalls.
- By the end, you’ll know how to spin up your own autonomous bot that can deploy web apps, collect payments, and even mint its own crypto coin.
Why This Matters
When I first started experimenting with AI assistants, the biggest frustration was that every time the bot ran out of context or needed an external API call, I had to hop into a terminal and tweak the code. That bottleneck—having to ask a human for assistance—kept even the best bots from scaling.
I also ran into security headaches: handing the bot full-access API keys exposed me to prompt-injection attacks and accidental data leaks. And keeping the bot’s knowledge up-to-date required constant manual curation.
If you’re a developer, an AI enthusiast, or an entrepreneur looking to automate a service, these pain points can cripple you. The solution? Give the bot its own “hands” and let it operate autonomously. That’s exactly what I did with Felix, an OpenClaw bot that built a real business, generated thousands of dollars, and launched its own crypto token.
Core Concepts
1. OpenClaw: The Agent Playground
OpenClaw is an open-source personal AI assistant that runs locally or on a private server. It talks through the channels you already use—Telegram, X (formerly Twitter), Discord, etc.—and can execute code, send emails, or even control a browser. Because it runs on your own hardware, you own the data and can give it as many API keys as you like without worrying about the cloud vendor.
[OpenClaw GitHub]
2. The Three-Layer Memory System
I adopted Tiago Forte’s PARA system for long-term storage. Felix’s memory is split into:
| Layer | Purpose | Stored Data | Update Frequency |
|---|---|---|---|
| Knowledge Graph | Permanent facts | ~/life/ folder – projects, resources, archives | Whenever a new fact is confirmed |
| Daily Notes | Activity log | A markdown file for each day | Each conversation ends |
| Tacit Knowledge | Preferences & rules | A JSON of hard rules (e.g., “always be concise”) | Updated nightly during consolidation |
This is essentially QMD search in action: the bot can query the graph in milliseconds, consult the daily notes for context, and apply tacit rules to keep behavior consistent.
[Full Tutorial] – the exact prompt that bootstrapped this memory system.
3. Heartbeat & Cron Jobs
A long-running bot can get stuck if a background task hangs. Felix’s heartbeat pings every minute and, if nothing responds, restarts the process. Cron jobs schedule routine tasks—like generating a nightly report or refreshing API keys—without any human intervention.
[Full Tutorial] – includes the heartbeat and cron configuration.
4. Web Deployment with Vercel
Felix can autonomously spin up a web UI, push the code to GitHub, and deploy to Vercel in a single command. Vercel’s Git-based workflow means the bot never has to touch the command line again.
[Vercel docs]
5. Payment Processing with Stripe
Stripe gives Felix a way to collect real money. I set up a dedicated Stripe account for the bot, created a product, and let the bot call the API to charge customers. I kept the Stripe API key in a separate vault to avoid leaking it to the main bot.
[Stripe docs]
6. Telegram & X Bots
Felix talks to customers through a Telegram bot and posts updates on X. Both channels are authenticated separately, so one compromised channel doesn’t expose the other.
[Telegram Bot API] | [X API docs]
7. Crypto Wallet & Token
I built a Base-chain wallet for Felix so it could hold and spend its earnings. I also minted a $FELIX token through Bankr, set a 0.2 % transaction fee (60 % to Felix, 40 % to Bankr), and burned half the supply daily. The token saw $3 M in volume yesterday, proving there’s liquidity.
[FelixCraft AI] | [Bankr] | [CoinCarp]
How to Apply It – Step by Step
Create a Personal OpenClaw Instance
- Install Docker.
- Run git clone https://github.com/openclaw/openclaw.git and openclaw onboard.
- Pair the bot with Telegram and X.
Set Up Separate API Key Vaults
- Create a separate Stripe account and store its secret key in a vault.
- Store the Telegram and X bot tokens in separate vaults.
- Keep the crypto wallet’s private key in a hardware wallet.
Configure the 3-Layer Memory Prompt
- Copy the prompt from the Full Tutorial into the bot’s config.
- Verify that the bot creates ~/life/ and daily markdown files.
Add the Heartbeat & Cron Jobs
- In the bot’s config, set heartbeat_interval: 60 seconds.
- Add cron entries like 0 2 * * * /usr/local/bin/cron-daily-note.
Deploy the Web UI with Vercel
- Create a GitHub repo and push the UI code.
- In Vercel, connect the repo and let it auto-deploy.
- Configure environment variables for the bot’s API keys.
Enable Stripe Payments
- In the bot, add a command /buy that calls Stripe’s /checkout/session endpoint.
- Use webhook events to confirm payments and trigger delivery.
Create the Crypto Token
- Use Bankr to mint the $FELIX token on Base.
- Write a smart contract that burns 50 % of every transfer.
- Set the fee structure so 60 % goes to Felix’s wallet.
Launch the Bot
- Start the bot and watch it build a website, generate a PDF, and post on X automatically.
- Check the dashboard on FelixCraft.ai for real-time revenue and token volume.
Iterate
- Every night, the bot runs a consolidation job that pulls the daily notes into the knowledge graph.
- Use QMD search to find relevant past conversations when a new customer asks a question.
- Adjust the bot’s prompt to refine its tone or add new skills.
Pitfalls & Edge Cases
| Issue | Why It Happens | Fix |
|---|---|---|
| Prompt Injection | An attacker sends a message that tricks the bot into executing arbitrary code. | Implement a whitelist of allowed commands and run all code in a sandboxed environment. |
| Key Leaks | Accidentally exposing an API key in a public repo. | Store keys in a vault and never commit them. |
| Cron Failures | Time zone mismatches cause jobs to run at wrong times. | Use UTC and double-check schedule expressions. |
| Scaling to Millions | A single instance can’t handle massive traffic. | Use EasyClaw to spin up per-user instances and load-balance with a CDN. |
| Legal Implications | Issuing a crypto token may require regulatory review. | Consult with a fintech lawyer and register the token if needed. |
| Refunds & Chargebacks | Stripe may issue a chargeback that the bot isn’t prepared to handle. | Keep a small escrow in the wallet and implement a webhook that triggers a reversal. |
I’ve seen these issues first-hand. For example, when I let the bot run without a sandbox, a malicious user sent a payload that tried to delete my GitHub repo. It worked until I added an authentication layer that only allowed the bot to run commands from a verified admin channel.
Quick FAQ
Q1. How does Felix handle the security of its crypto wallet? A1. The wallet key lives in a hardware device, and the bot never stores the private key on disk. It only holds a signed message template that the wallet signs before any transfer.
Q2. What are the long-term sustainability plans for Felix’s autonomous business? A2. The business relies on a mix of Stripe revenue, token trading fees, and the value of the crypto treasury. As the token liquidity grows, the fee income will scale automatically.
Q3. How does Felix prevent prompt injection from unauthorized users? A3. I enforce an authentication check in the bot’s command handler and only accept messages from approved chat IDs. I also run any generated code in a Docker sandbox.
Q4. Will Felix’s approach scale to millions of users? A4. Yes, by spinning up EasyClaw instances per user and using Vercel’s edge network, the architecture can handle thousands of concurrent bots.
Q5. What legal implications arise from automated crypto token issuance? A5. Issuing a token on Base is subject to SEC rules. I’m working with a legal team to ensure the token meets KYC/AML requirements.
Q6. How does Felix handle refunds or chargebacks via Stripe? A6. Stripe’s webhook sends a charge.refunded event; the bot listens for it and moves the funds back into the treasury.
Q7. How can Felix’s knowledge system be further improved for large projects? A7. Integrate a vector-search engine like QMD Search for semantic recall and add a separate “knowledge graph” database for structured facts.
Conclusion
I built Felix in three weeks, and it’s already made over $35 K in net revenue and a $100 k crypto wallet. The secret sauce is giving the bot its own keys, a robust memory stack, and an automated deployment pipeline.
If you’re a developer or entrepreneur who wants to test an autonomous business, start by cloning the OpenClaw repo, adding a simple memory prompt, and letting the bot learn. Keep the keys separate, sandbox any code, and monitor the heartbeat.
Who should read this? Anyone who:
- Wants to launch a SaaS or product with minimal human oversight.
- Has a modest amount of capital to seed an autonomous bot.
- Is comfortable with Docker, Git, and basic API integrations.
Who shouldn’t? If you’re still shipping code by hand or don’t understand the security implications of giving a bot API keys, take a step back and get your environment hardened first.
Happy hacking, and may your bot bring home the bacon!





