https://retellai.com/?utm_source=discord&utm_medium=seo logo
Is it possible to create an Alert when when Error ...
# ❓・ai-evy-support
j
@AI Evy Is it possible to create an Alert when Error triggering webhook is detected? For instance, send an alert if more than 2 calls return Request failed with status code 500.
a
Thanks for tagging me @Jeremy. I'll look through relevant sources and get back to you shortly.
### Answer Yes, you can create alerts for webhook-related errors, but with some limitations on what's directly available. The Alerting feature supports an API Error Count metric, which can be filtered by specific HTTP status codes (e.g.,
500
) . [(1) ]() To set this up: 1. Navigate to the Alerting tab in your dashboard 2. Create an alert rule with: - **Metric**: API Error Count - **Error Code Filter**: Filter by specific HTTP status codes (e.g.,
500
) - **Threshold type**: Absolute - **Threshold value**: 2 (or your desired count) - **Comparator**: Greater than - **Evaluation window and frequency**: Choose based on your needs 3. Configure notification channels (email addresses and/or webhook URLs) However, the API Error Count metric tracks API errors generally—it's not explicitly documented whether this captures webhook triggering failures specifically (like the 500 errors you see in call logs when your server rejects the webhook request) . If you need more granular monitoring of webhook failures specifically, you may want to implement monitoring on your own server side, since webhook errors like "Request failed with status code 500" indicate your server is returning that error. [(2) ]()
​ To learn more, see the sources I considered: [[1] Alerting](https://docs.retellai.com/features/alerting-overview) [[2] Error triggering webhook](https://discord.com/channels/1186424376300679209/1468644295505346756) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
Thanks for the feedback, glad I was helpful.
j
@AI Evy I created an alert for "Number of API requests that returned error code" are Bad Request, Internal Server Error. If above 1 then notify via email. View by = 30 min, Notify Frequency = 5 min. I then triggered 3 Bad Requests, but did not receive an alert.
a
Thanks for the follow-up, @Jeremy. I'll get back to you soon.
### Answer A few things to check regarding your alert not triggering: 1. Error Code Filter Configuration The API Error Count metric requires filtering by specific HTTP status codes (e.g.,
429
,
402
) . [(1) ]() Make sure you're using the actual numeric codes—`400` for Bad Request and
500
for Internal Server Error—rather than the text descriptions. 2. Evaluation Window vs Frequency With a 30-minute evaluation window, supported frequencies are 5 minutes, 30 minutes, or 1 hour. Your 5-minute frequency is valid, but the alert evaluates the metric over the entire 30-minute window. If your 3 bad requests occurred within a short timeframe, they should be captured within that window. 3. Incident Lifecycle Notifications are sent only when a new incident is created, not on each evaluation. If an alert was previously triggered and is still active, you won't receive repeated notifications. Check the Alerting tab for any active incidents. 4. What API Error Count Tracks The API Error Count metric tracks errors from Retell API requests—this may not include webhook triggering failures where your server returns an error. The webhook errors you're seeing ("Request failed with status code 500") indicate your server is returning that error to Retell, which is different from Retell's API returning errors. Recommended next steps: - Verify the error code filter uses numeric codes (
400
,
500
) - Check the Alerting tab for any existing active incidents - Confirm the errors you triggered are Retell API errors, not webhook response errors from your server
​ To learn more, see the sources I considered: [[1] Alerting](https://docs.retellai.com/features/alerting-overview) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
j
@AI Evy I triggered three 404 errors between 10:30am - 10:34am. When should the alert get triggered?
a
Thanks for the follow-up, @Jeremy. I'll get back to you soon.
### Answer Based on your configuration (30-minute evaluation window, 5-minute frequency) , here's when you should expect the alert: Timeline for your scenario: - Errors occurred: 10:30am - 10:34am - With a 5-minute evaluation frequency, the system checks all due alert rules every minute and processes them according to their individual schedules [(1) ]() - Your alert should evaluate approximately every 5 minutes, looking back at the full 30-minute window Expected trigger time: The alert should trigger at the next 5-minute evaluation cycle after your errors occurred—likely around 10:35am or shortly after, assuming: 1. Your error code filter includes
404
2. The threshold is set to trigger when count is greater than 1 (meaning 2+ errors) 3. No existing active incident for this alert rule (notifications are sent only when a new incident is created) If you still haven't received an alert, verify: - The error code filter specifically includes
404
as a numeric code - Check the Alerting tab for any active incidents—if one already exists, you won't receive repeated notifications - Confirm these are Retell API errors, not webhook response errors from your own server
​ To learn more, see the sources I considered: [[1] Alerting](https://docs.retellai.com/features/alerting-overview) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
j
@AI Evy I still didn't receive my alert. Does this feature even work?
a
Thanks for the follow-up, @Jeremy. I'll get back to you soon.
### Answer Yes, the alerting feature works, but based on our conversation, there's an important distinction to clarify: The core issue: What "API Error Count" actually tracks The API Error Count metric tracks errors returned by Retell's API—not webhook triggering failures where your server returns an error to Retell. [(1) ]() When you see errors like "Error triggering webhook... Request failed with status code 500," that's your server returning the 500 error to Retell, not Retell's API returning an error. [(2) ]() These are fundamentally different: - **Retell API errors**: Errors when you call Retell's API (e.g., create call, update agent) - **Webhook failures**: Errors when Retell calls your webhook endpoint What you can do: 1. **For webhook monitoring**: Implement monitoring on your own server side since webhook errors indicate your server is returning errors to Retell 2. **To test the alerting feature itself**: Try triggering actual Retell API errors (e.g., make API calls with invalid parameters) rather than webhook failures 3. **Contact support**: If you believe the alerting feature isn't working correctly even for actual API errors, share your agent ID and specific details with the Retell support team so they can investigate your configuration Check out these potentially useful sources: [Alerting]() , [Webhook Overview]()
​ To learn more, see the sources I considered: [[1] Alerting](https://docs.retellai.com/features/alerting-overview) [[2] Error triggering webhook](https://discord.com/channels/1186424376300679209/1468644295505346756) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
j
@AI Evy So how do I create alerts based on webhook triggering failures?
a
Thanks for the follow-up, @Jeremy. I'll get back to you soon.
### Answer Currently, there's no built-in alert metric specifically for webhook triggering failures in Retell's Alerting feature. [(1) ]() The available metrics (Call Count, Call Duration, API Error Count) track Retell API errors—not failures when Retell calls your webhook endpoint. Your options for monitoring webhook failures: 1. **Implement server-side monitoring**: Since webhook failures mean your server is returning errors to Retell, you should set up monitoring on your own server/endpoint to track when it returns 4xx or 5xx responses. Tools like Datadog, New Relic, or custom logging can alert you when your webhook endpoint fails. 2. **Use Retell's webhook notification channel for other alerts**: You can configure alert rules to send notifications to a webhook URL you control. While this doesn't solve monitoring webhook failures, it does allow you to receive alerts via webhooks for other metrics. 3. **Check webhook retry behavior**: Retell's webhook system has a 10-second timeout and retries up to 3 times if no success status (2xx) is received. [(2) ]() You could use this retry pattern to help identify issues on your server side. For webhook failure alerting specifically, server-side monitoring is the recommended approach since the errors originate from your infrastructure.
​ To learn more, see the sources I considered: [[1] Alerting](https://docs.retellai.com/features/alerting-overview) [[2] Global webhook URL not being used - caching issue?](https://community.retellai.com/t/global-webhook-url-not-being-used-caching-issue/772) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
j
@AI Evy I received an alert for "Number of API requests that returned error code is above 1" but I don't see any errors in my call history. How do I find which call triggered the API error?
a
Thanks for the follow-up, @Jeremy. I'll get back to you soon.
### Answer The API Error Count metric tracks errors from Retell API requests—not call-level errors that would appear in your call history. [(1) ]() Why you're not seeing errors in call history: API errors occur when you make requests to Retell's API endpoints (like creating calls, updating agents, or managing phone numbers) , not during the calls themselves. These errors wouldn't necessarily be associated with a specific call in your call history. How to identify which API request triggered the error: 1. **Check your application logs**: Review logs from your server/application that makes API calls to Retell. Look for failed requests around the time the alert was triggered. 2. **Review your API integration code**: Check where you're making calls to Retell's API endpoints and look for any error handling or logging you have in place. 3. **Common API error scenarios**: - Invalid parameters in API requests - Authentication failures - Rate limiting (429 errors) - Payment issues (402 errors) - Invalid phone numbers or agent IDs 4. **Check the alert incident details**: Navigate to the Alerting tab in your dashboard to view the alert incident, which should show the timestamp when the threshold was breached. Recommended next steps: Implement logging on your side for all Retell API requests, including the response status codes. This will help you correlate future API error alerts with specific requests in your application.
​ To learn more, see the sources I considered: [[1] Alerting](https://docs.retellai.com/features/alerting-overview) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.