https://retellai.com/?utm_source=discord&utm_medium=seo logo
g
@AI Evy Hi..! I need to customize the webhook payload format for post-call data to match this structure? { "caller_phone_number": "+1234567890", "transcript": "Full call transcript...", "call_status": "completed", "duration_seconds": 120, "order": { "customer_name": "John Doe", "items": [ { "name": "Pizza", "quantity": 2 }, { "name": "Salad", "quantity": 1 } ], "total": 35.50, "order_type": "pickup", "status": "green" } } The webhook URL we are sending this to is: https://ptfjluovpaqohnomzuhs.supabase.co/functions/v1/retell-webhook Please let me know what’s possible
a
Thanks for tagging me @garcjaa. I'll look through relevant sources and get back to you shortly.
### Answer Based on the documentation, Retell AI webhooks send data in a predefined format that cannot be customized to match your desired structure [(1) ]() . The webhook payload follows this structure:
Copy code
json
{
 "event_type": "call_analysis",
 "call_analysis": {
 // Analysis results object
 }
}
[(2) ]() For post-call analysis, you can extract custom data using these analysis categories [(3) ]() : - Boolean (True/False) - Simple yes/no determinations - Text (String) - Detailed textual information - Number (Numerical value) - Quantitative measurements - Selector (Enum) - Categorization from a fixed list The webhook events include
call_started
,
call_ended
, and
call_analyzed
[(1) ]() . The
call_analyzed
event contains the full call data including the
call_analysis
object . To achieve your desired format, you'll need to: 1. Configure post-call analysis fields in your agent to extract the order details, customer name, and other custom data [(4) ]() 2. Process the incoming webhook payload at your endpoint to transform it into your required structure 3. The webhook will POST to your specified URL with a 10-second timeout and up to 3 retries [(1) ]() Your webhook endpoint at ` will receive the standard Retell AI format and need to handle the transformation to your custom structure.
​ To learn more, see the sources I considered: [[1] Webhook Overview](https://docs.retellai.com/features/webhook-overview) [[2] Consume the analysis data](https://docs.retellai.com/features/post-call-analysis-consumption) [[3] Post Call Analysis Overview](https://docs.retellai.com/features/post-call-analysis-overview) [[4] Create Agent](https://docs.retellai.com/api-references/create-agent) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
g
trigger a test webhook so you can verify it appears correctly in your Lovable dashboard
@AI Evy trigger a test webhook so you can verify it appears correctly in your Lovable dashboard
a
Thanks for the follow-up, @garcjaa. I'll get back to you soon.
### Answer To trigger a test webhook in Retell AI, you can start a web call in the dashboard to verify the webhook is triggered correctly [(1) ]() . The webhook events that will be triggered include [(2) ]() : -
call_started
- Triggered when a new call begins -
call_ended
- Triggered when a call completes, transfers, or encounters an error -
call_analyzed
- Triggered when call analysis is complete The webhook will POST the payload to your endpoint at ` . The webhook has a timeout of 10 seconds and will be retried up to 3 times if no success status (2xx) is received . Once you start a test call in the dashboard, you should see the webhook events appear in your Lovable dashboard where you can verify the payload structure and ensure your endpoint is receiving the data correctly.
​ To learn more, see the sources I considered: [[1] Setup guide](https://docs.retellai.com/features/register-webhook) [[2] Webhook Overview](https://docs.retellai.com/features/webhook-overview) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.