Skip to main content

Code

basic.py

Usage

1

Set up your virtual environment

2

Set Environment Variables

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

Install dependencies

4

Run Example

Set WHATSAPP_SKIP_SIGNATURE_VALIDATION=true only for local payload tests that are not reachable from the public internet. Public webhook endpoints should validate signatures with WHATSAPP_APP_SECRET.

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