Debug output keyword. PRINT is an alias for TALK - both send messages to the current conversation.
Note:
TALKare equivalent. UseTALKfor user-facing messages andTALKfor clarity.
Syntax
PRINT expression
Parameters
| Parameter | Type | Description |
|---|---|---|
| expression | Any | The value to output (string, number, or any expression) |
Description
PRINT outputs a message to the current conversation. It is functionally identical to TALK but conventionally used for debugging and logging purposes.
For sending messages to specific recipients on other channels, use:
TALK TO- Send to a specific recipient (WhatsApp, Teams, etc.)SEND FILE TO- Send files to a specific recipient
Examples
Basic Debug Output
x = 10
y = 20
PRINT "Debug: x = " + x + ", y = " + y
result = x + y
PRINT "Result: " + result
Logging During Processing
WEBHOOK "process-order"
order_id = body.order_id
PRINT "Processing order: " + order_id
' Process the order
customer = FIND "customers", "id=" + body.customer_id
PRINT "Found customer: " + customer.name
' More processing...
PRINT "Order processing complete"
result_status = "ok"
Variable Inspection
data = GET "https://api.example.com/data"
PRINT "API Response: " + data
items = FIND "products", "stock < 10"
PRINT "Low stock items count: " + UBOUND(items)
Equivalent Keywords
| Keyword | Description |
|---|---|
TALK | Same as PRINT - send message to conversation |
TALK TO | Send message to specific recipient |
Example: PRINT vs TALK TO
' Debug output (goes to current conversation)
PRINT "Starting order notification..."
' User-facing message to specific WhatsApp number
TALK TO "whatsapp:+5511999887766", "Your order is confirmed!"
' More debug output
PRINT "Notification sent successfully"
Best Practices
- Use TALK for production - More readable for user-facing messages
- Use PRINT for debugging - Makes it clear this is debug/log output
- Use TALK TO for channels - When sending to specific recipients
' Good: Clear intent
PRINT "Debug: Processing started"
TALK "Welcome! How can I help you?"
TALK TO "whatsapp:" + phone, "Your order is ready!"
' Also valid but less clear:
PRINT "Welcome! How can I help you?" ' Works but TALK is clearer
See Also
- TALK - Primary message output keyword
- TALK TO - Send to specific recipients
- SEND FILE TO - Send files to recipients