Sends text messages to users via WhatsApp.

Configuration

  • whatsapp_config_id: WhatsApp connection to use
  • message: Text content (string or AIField)
  • provider_model_name: Required when using AIField

Examples

Static message
from kapso.builder.flows.nodes import SendTextNode

node = SendTextNode(
    id="send_text_1234",
    whatsapp_config_id="config_123",
    message="Hello! How can I help you today?"
)
AI-generated message
from kapso.builder.flows.nodes import SendTextNode
from kapso.builder.ai.field import AIField

node = SendTextNode(
    id="send_text_5678", 
    whatsapp_config_id="config_123",
    message=AIField("Personalize greeting based on customer history"),
    provider_model_name="claude-3-5-sonnet-20241022"
)

Variable interpolation

Use variables in messages:
message="Hi {{customer_name}}, your order {{order_id}} is ready!"

Usage patterns

Welcome message Response after decision