Inspiration
64 million+ UMKM in Indonesia manage orders through WhatsApp and Telegram chats — manually parsing messages, checking stock, calculating totals, and sending payment instructions. Each order takes 3–5 minutes of manual processing. We wanted to build an autonomous AI agent that does all of this instantly.
What it does
WarungPilot AI is an autonomous commerce operations agent. It reads customer chat messages and processes them end-to-end using a ReAct-style autonomous loop: the LLM reasons about what to do, selects from 11 available tools, executes them, observes the results, and loops until all tasks are complete.
The agent handles: message parsing, intent classification (buy, price inquiry, complaint), order extraction with inventory validation, invoice generation, payment task creation (DOKU QRIS), and owner approval gating — all without manual intervention.
How we built it
- Agent Loop: Custom ReAct engine (
agent/loop.ts) that sends tool descriptions to the LLM, parses JSON responses, executes tools, and feeds observations back - Tool Registry: 11 tools registered with descriptions and parameter schemas for LLM selection
- AI Routing: Supports Kiro/Claude Sonnet 4.5 via 9Router, Ollama, and OpenAI-compatible providers
- Payment: Full DOKU Checkout integration with HMAC-SHA256 signing, webhook verification, and payment ledger
- Approval Gate: Telegram Bot API integration for owner approval before any customer-facing action
- Fallback: Deterministic sequential pipeline when AI is unavailable
Challenges we ran into
- Making the LLM reliably output structured JSON for tool selection across different providers
- Handling edge cases autonomously (complaints vs orders vs price inquiries)
- DOKU sandbox limitations with Virtual Account payments
- Balancing autonomy with safety — the agent must never bypass the owner approval gate
What we learned
- ReAct-style loops are powerful but require careful prompt engineering
- Deterministic tools + LLM reasoning = reliable autonomous systems
- Real payment integration adds significant complexity but proves real-world viability
What's next for WarungPilot AI
- WhatsApp Business API integration
- Multi-store support with centralized dashboard
- Customer relationship memory (repeat order recognition)
- Production DOKU deployment with real transactions
- Financial reporting and analytics
Built With
- 9router
- claude-sonnet-4.5
- doku-checkout-api
- kiro
- next.js
- ollama
- openclaw
- react
- tailwind-css
- telegram-bot-api
- typescript
Log in or sign up for Devpost to join the conversation.