catr007.
08/18/2025, 4:46 AMAI Evy
08/18/2025, 4:46 AMAI Evy
08/18/2025, 4:46 AM{
"event_type": "call_analysis",
"call_analysis": {
// Analysis results object
}
}
The call_analysis object in the API response contains a custom_analysis_data field where your custom variables should appear [(3) ]() [(4) ]() :
"call_analysis": {
"call_summary": "The agent called the user to ask question about his purchase inquiry. The agent asked several questions regarding his preference and asked if user would like to book an appointment. The user happily agreed and scheduled an appointment next Monday 10am.",
"in_voicemail": false,
"user_sentiment": "Positive",
"call_successful": true,
"custom_analysis_data": {}
}AI Evy
08/18/2025, 4:46 AMAI Evy
08/18/2025, 4:46 AMAI Evy
08/18/2025, 4:46 AMcatr007.
08/18/2025, 4:49 AMcatr007.
08/18/2025, 4:51 AMAI Evy
08/18/2025, 4:51 AMAI Evy
08/18/2025, 4:52 AMcall_analyzed webhook event, not other webhook events [(1) ]() . You need to ensure your webhook is configured to receive this specific event type.
## Data Location
The custom variables appear in the custom_analysis_data field within the call_analysis object [(2) ]() [(3) ]() [(4) ]() . The structure looks like this:
json
"call_analysis": {
"call_summary": "The agent called the user to ask question about his purchase inquiry...",
"in_voicemail": false,
"user_sentiment": "Positive",
"call_successful": true,
"custom_analysis_data": {}
}AI Evy
08/18/2025, 4:52 AMopt_out_sensitive_data_storage set to true, the call_analysis object will not be populated in webhooks [(5) ]() . This is intentional functionality - there is no post call analysis if you opt out of data storage .
2. **Connected Calls Only**: Custom post call analysis fields are not populated for non-connected calls and calls where no conversation happened [(6) ]() . You should check the field existence before using it .
3. **Multiple Webhooks**: Retell sends 3 webhooks during/after a call, and post call analysis results come with the third one (call_analyzed) [(1) ]() . Make sure you're listening for the correct webhook event.
Since you can see the data on the Retell platform but not in your webhook, the most likely issue is that you have opted out of sensitive data storage, which prevents the call_analysis object from being sent via webhooks.AI Evy
08/18/2025, 4:52 AMAI Evy
08/18/2025, 4:52 AMcatr007.
08/18/2025, 5:06 AMAI Evy
08/18/2025, 5:06 AMAI Evy
08/18/2025, 5:06 AMcall_analyzed webhook event specifically. Make sure your webhook endpoint is still configured to receive this event type [(1) ]() .
## Verify Webhook Payload Structure
The custom variables should appear in the custom_analysis_data field within the call_analysis object [(2) ]() [(3) ]() [(4) ]() . The structure looks like this:
json
"call_analysis": {
"call_summary": "The agent called the user to ask question about his purchase inquiry. The agent asked several questions regarding his preference and asked if user would like to book an appointment. The user happily agreed and scheduled an appointment next Monday 10am.",
"in_voicemail": false,
"user_sentiment": "Positive",
"call_successful": true,
"custom_analysis_data": {}
}AI Evy
08/18/2025, 5:07 AMopt_out_sensitive_data_storage in your call creation. This setting prevents call_analysis data from being sent via webhooks [(5) ]() [(3) ]() [(6) ]() [(7) ]() .
2. **Webhook Size Limits**: For longer calls, the webhook payload can become too large. One user reported receiving a "413 request entity too large" error for calls longer than 5 minutes [(8) ]() . If you modified your server configuration, check your request size limits.
3. **Call Requirements**: Custom post call analysis fields are only populated for connected calls where conversation happened [(1) ]() . Verify your test calls meet these criteria.
Since it was working before your script changes, review what you modified - particularly any settings related to data storage, webhook configuration, or server request limits.AI Evy
08/18/2025, 5:07 AMAI Evy
08/18/2025, 5:07 AMcatr007.
08/18/2025, 5:35 AMAI Evy
08/18/2025, 5:35 AMAI Evy
08/18/2025, 5:36 AMcall_analysis might appear intermittently in your webhook data:
## Key Factors Affecting call_analysis Availability
**Opt-out of Personal Data Storage**: If you have opt_out_sensitive_data_storage set to true, the call_analysis object will not be populated in webhooks [(1) ]() . This is intentional functionality - there is no post call analysis if you opt out of data storage .
**Webhook Payload Size Limits**: For longer calls, webhooks can fail due to payload size. One documented case shows a "413 request entity too large" error for calls longer than 5 minutes [(2) ]() . The error log shows:
2025-07-30 17:30:23.102 call_89b9c83bce9588096a3bbd74505 info: Webhook triggered for call_analyzed
2025-07-30 17:30:24.120 call_89b9c83bce9588096a3bbd74505 error: Error triggering webhook for call_analyzed Axios Error: error code: ERR_BAD_REQUEST, error message: Request failed with status code 413
response status: 413
response data: [{"message":"1"},"request entity too large"]
## Expected Webhook Structure
The call_analysis object should appear in the webhook with this structure [(3) ]() :
json
"call_analysis": {
"call_summary": "The agent called the user to ask question about his purchase inquiry. The agent asked several questions regarding his preference and asked if user would like to book an appointment. The user happily agreed and scheduled an appointment next Monday 10am.",
"in_voicemail": false,
"user_sentiment": "Positive",
"call_successful": true,
"custom_analysis_data": {}
}AI Evy
08/18/2025, 5:36 AMopt_out_sensitive_data_storage is set to false in your call configuration [(1) ]()
3. Ensure your webhook responds with a 2xx status code [(4) ]()
4. Confirm you're listening for the call_analyzed webhook event specifically [(5) ]()
Since it worked once and then stopped, the most likely cause is either the opt-out setting was changed or your server's request size limit is being exceeded for larger webhook payloads.AI Evy
08/18/2025, 5:36 AMAI Evy
08/18/2025, 5:36 AM