Peach icon

Peach

Interact with the Peach WhatsApp Platform API

Actions17

AI Agent → Connect

AI-generated

Summary

Connects a contact to a Peach AI Agent by sending a WhatsApp template message to the contact's phone number. The agent is attached to the conversation, so it handles replies. This sends a POST to /api/v1/events with event_type "connect_to_ai_agent".

Inputs

  • Phone Number (required) — Contact's phone number including country code.
  • AI Agent ID (required) — ID of the Peach AI Agent to connect; sent as ai_agent.id.
  • Template ID (required) — ID of the WhatsApp template to send; sent as template_message.whats_app_template_id.
  • Liquid Values — JSON object of template variables (e.g. {"name": "John"}). Defaults to {}.
  • Additional Fields — Optional Contact Name, Email, Retry Until (ISO 8601 datetime to keep retrying delivery), and Retry Window (start HH:MM, end HH:MM, timezone; defaults 08:00, 20:00, Asia/Kolkata). Unset fields are omitted from the request.
  • Request Options — Node settings for batching (items per batch, interval), ignoring SSL issues, proxy, and timeout (default 10000 ms).

Output shape

The JSON response from the Peach events API for the submitted event, one result per input item.

The source doesn't define the response fields. Authentication uses the peachApi credential against https://app.trypeach.ai. The event ID may be usable for status lookups, but this isn't confirmed here.

Examples

Example 1: Start an AI Agent conversation with a new lead from a form submission.

Phone Number = {{$json.phone}}, AI Agent ID = agent ID, Template ID = welcome template, Liquid Values = {"name": "{{$json.name}}"}.

Example 2: Retry delivery only during business hours for a few days.

Additional Fields: Retry Until = a datetime 3 days out; Retry Window = 09:00 to 18:00, Timezone Europe/London.

Links

Discussion