# Need some idea  to automate work in dynatrace

**URL:** <https://community.dynatrace.com/t/need-some-idea-to-automate-work-in-dynatrace/11702>\
**Category:** Container platforms\
**Tags:** kubernetes, automation\
**Created:** [February 18, 2021, 2:12am UTC](https://community.dynatrace.com/t/need-some-idea-to-automate-work-in-dynatrace/11702 "2021-02-18T02:12:53Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![shriniwasmundli](https://avatars.discourse-cdn.com/v4/letter/s/e19adc/32.png) [@shriniwasmundli](https://community.dynatrace.com/u/shriniwasmundli)\
**Post date:** [February 18, 2021, 2:12am UTC](https://community.dynatrace.com/t/need-some-idea-to-automate-work-in-dynatrace/11702/1 "2021-02-18T02:12:53Z")

</div>

We want to automate the pod restart in dynatrace if there is a performance issue with one of the pod like there is high cpu etc etc and we want to restart that pod, in that case we want dynatrace to come into the picture and call our api to either restart or scale the pods. Please kindly provide some insight to work on this. We need to achieve with with our api.

---

<div class="post-metadata">

**Author:** ![pahofmann](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/pahofmann/32/17076_2.png) [@pahofmann](https://community.dynatrace.com/u/pahofmann)\
**Post date:** [February 18, 2021, 9:49am UTC](https://community.dynatrace.com/t/need-some-idea-to-automate-work-in-dynatrace/11702/2 "2021-02-18T09:49:13Z")

</div>

You can use [Webhook integrations](https://www.dynatrace.com/support/help/setup-and-configuration/integrations/third-party-integrations/problem-notification-systems/webhook-integration/) for Problems detected by Dynatrace to call you API.

You could restart pods as soon as they are affected by a problem, or define [Metric events for alerting](https://www.dynatrace.com/support/help/shortlink/metric-events-for-alerting) to specify triggers for problems that you want to use for the restart, like high CPU consumption.

---

<div class="post-metadata">

**Author:** ![shriniwasmundli](https://avatars.discourse-cdn.com/v4/letter/s/e19adc/32.png) [@shriniwasmundli](https://community.dynatrace.com/u/shriniwasmundli)\
**Post date:** [February 18, 2021, 9:24pm UTC](https://community.dynatrace.com/t/need-some-idea-to-automate-work-in-dynatrace/11702/3 "2021-02-18T21:24:00Z")

</div>

Hi Patrick Thank a lot for you input. I am new to automation.. is that possible any sample test code which I use for reference purpose that can help me to do more research as per my project requirement. Thanks again.
