Skip to main content

Code

cookbook/05_agent_os/interfaces/whatsapp/basic.py

Usage

1

Set up your virtual environment

2

Set Environment Variables

See the WhatsApp Bot setup guide for how to get these values from the Meta Developer Dashboard.
3

Install dependencies

4

Run Example

Key Features

  • WhatsApp Integration: Responds to messages via the WhatsApp Business API
  • Conversation History: Maintains context with last 3 interactions
  • Persistent Memory: SQLite database for session storage
  • Session Reset: Users can send /new to start a fresh conversation
  • Markdown Support: Rich text formatting in messages