Introduction
This document describes how to configure custom events in AppDynamics using the REST API and connect them to health rules for automated alerting.
Prerequisites
- Access to an AppDynamics SaaS or on-premises Controller instance
- Permissions to create and manage events, health rules, and policies
- Controller version 21.x or later
- Notification channels (email, SMS, or third-party integrations) configured
- Basic understanding of REST APIs and the AppDynamics user interface
Requirements
Ensure you meet these requirements before starting:
- AppDynamics Controller version 21.x or later (for the latest event and alert features)
- REST API access enabled for your Controller
- Notification channels (email, sms, or integrations) configured for alert delivery
Components Used
- AppDynamics Controller
- AppDynamics Agents
- Notification Channels
The information in this document was created from the devices in a specific lab environment. All of the devices used in this document started with a cleared (default) configuration. If your network is live, ensure that you understand the potential impact of any command.
Background Information
In a world of increasingly dynamic cloud-native architectures, proactive monitoring is essential to ensure system resilience and reduce mean time to resolution (MTTR). AppDynamics offers robust observability capabilities, including the ability to create custom events and alerts that help operations teams detect anomalies faster and respond with precision.
Out-of-the-box metrics are critical but modern systems often require context-specific observability. Whether you are integrating CI/CD pipelines, custom automation tools, or external systems, injecting custom events into AppDynamics ensures:
- Unified visibility across system and business metrics
- Real-time detection of application-specific anomalies
- Reduced manual intervention through automated actions
Sometimes it make sense to create custom events to monitor specific aspects of your application. This article is to guide you on how to create custom events via REST API in AppDynamics controller and how to set up an alert based on the custom event.
Configure
This section covers the step-by-step process to create custom events and configure alerts in AppDynamics Controller.
Configurations
Step 1: Create Custom Events via REST API
Custom events can be generated using the AppDynamics REST API. This is useful for integrating external systems, custom scripts, automation framework, or third-party tool:
Example API Call:
POST https://<controller-url>/controller/rest/applications/<application_id>/events?severity=ERROR&summary=Application+Stopped&eventtype=CUSTOM&customeventtype=App_Stop&comment=Please_start_application
Key Parameters:
- Replace <controller-url> and <application_id> with your Controller details.
- Required parameters:
- severity (INFO, WARN, ERROR)
- summary (short description)
- eventtype (must be CUSTOM)
- customeventtype (your custom event type label)
- comment (optional detailed message)
A successful request returns an event ID confirming creation
Example : "Successfully created the event id:550346816"
Visibility Tip: Do not forget to enable the Custom filter in the Events UI to view your injected events.

Step 2: Filtering and Monitoring Custom Events
- In the Controller UI, navigate to the Events section.
- Use Filter by Custom Events to add your event type or properties.
- You can specify key/value pairs for more granular filtering.
- Use All for AND logic (all properties must match), or Any for OR logic (at least one property matches)
This allows targeted tracking and investigation of injected events across your application.
Step 3: Configuring Alerts: Actions, and Policies
Actions:
- Specify what happens when a custom event is triggered (such as send email, sms, or invokes a webhook):

Policies:
- Create a new policy or edit an existing one:

- In the policy, configure the custom event filter to match the custom event you defined.


- In the policy Actions tab, add a new action and select the custom action you created:

- Save the alert: After you have configured the alert, click Save to create it:

Once you have created the alert, it triggers whenever a custom event matching the specified criteria is generated in the controller.
Verify
- Post a test custom event via REST API:

- Confirm visibility in the Events UI (check filters):

- Validate that Action is triggered for the custom Event:

- Validate delivery through the configured notification channel:


Troubleshoot
Issue |
Troubleshooting Steps |
Event Not Visible
|
- Ensure the Custom filter is eventtype enabled in the Events UI
- Double-check eventtype and customeventtype parameters in your API call.
|
API Errors
|
- Common error: “Event summary is not specified.” Always provide a summary in your request
- Verify authentication and application ID in the API call.
|
Alert Not Triggered
|
- Confirm the health rule and policy are correctly configured.
- Check notification channel setup (email/sms server configuration).
|
Custom Event Limits
|
- Controller has limits on custom event schema count and event size.
- Review documentation if posting large volumes or complex schemas
|
Conclusion
Custom events and alerting in AppDynamics offer a powerful way to enrich your observability strategy. Whether you are integrating with CI/CD tools, external services, or just extending visibility into key workflows, these capabilities ensure faster detection and resolution of issues before they impact users. Start leveraging custom observability intelligence to elevate your monitoring from reactive to predictive.
Need Further Assistance
If you have a question or are experiencing issues, please reach out to AppDynamics Support and include details such as error messages, configuration information, or relevant logs to help expedite troubleshooting.
Related Information