Skip to main content

CRM integration webhooks

Aventora-Assistant pushes engagement updates to one or more CRM systems when a call linked to an engagement completes. The same payload is sent to every configured webhook URL (Salesforce, Dynamics, HubSpot, Zoho, Twenty).

Environment variables

Set these in Aventora-Assistant to enable push (optional; if none are set, CRMs can still poll GET /integration/engagement/{id}).

VariableDescription
SALESFORCE_WEBHOOK_URLFull URL for Salesforce (e.g. https://.../services/apexrest/aventora/v1/engagement).
SALESFORCE_WEBHOOK_SECRETSent as header X-Aventora-Webhook-Secret.
DYNAMICS_WEBHOOK_URLFull URL for aventora-dynamics webhook.
DYNAMICS_WEBHOOK_SECRETSent as header X-Aventora-Webhook-Secret.
HUBSPOT_WEBHOOK_URLFull URL for aventora-hubspot webhook.
HUBSPOT_WEBHOOK_SECRETSent as header X-Aventora-Webhook-Secret.
ZOHO_WEBHOOK_URLFull URL for aventora-zoho webhook.
ZOHO_WEBHOOK_SECRETSent as header X-Aventora-Webhook-Secret.
TWENTY_WEBHOOK_URLFull URL for Twenty CRM webhook (e.g. https://your-twenty-server/rest/aventora/webhook).
TWENTY_WEBHOOK_SECRETSent as header X-Aventora-Webhook-Secret. Must match AVENTORA_WEBHOOK_SECRET in Twenty server .env if Twenty validates the secret.
CRM_WEBHOOK_DEBOUNCE_SECONDSDebounce window for all CRMs (default from SALESFORCE_WEBHOOK_DEBOUNCE_SECONDS, or 2.0).
CRM_WEBHOOK_RETRY_COUNTMax attempts (first try + retries) when a webhook POST fails with 5xx or connection error (default 3). 4xx responses are not retried.
CRM_WEBHOOK_RETRY_DELAY_SECONDSSeconds to wait between attempts (default 5).

Payload is built once per call and POSTed to each configured URL in parallel. Failed POSTs (5xx or network error) are retried according to CRM_WEBHOOK_RETRY_COUNT and CRM_WEBHOOK_RETRY_DELAY_SECONDS. See services/crm_webhooks/dispatcher.py and services/salesforce_integration/service.py.

Twenty CRM

When using Twenty CRM, set TWENTY_WEBHOOK_URL to your Twenty server’s webhook endpoint (e.g. https://your-twenty.example.com/rest/aventora/webhook). Optionally set TWENTY_WEBHOOK_SECRET; if set, Twenty must have the same value in AVENTORA_WEBHOOK_SECRET in its server .env or the webhook will be rejected with 401. The payload is the same engagement payload (engagement_id, status, outcome, summary, started_at, completed_at, history, transcript, sent_at, etc.). Twenty looks up the engagement by engagement_id (stored when the engagement was started from Twenty) and updates the corresponding Aventora engagement record.