# How to create custom error rule using request attribute value from API

**URL:** <https://community.dynatrace.com/t/how-to-create-custom-error-rule-using-request-attribute-value-from-api/33377>\
**Category:** Alerting\
**Tags:** problem-detection, request-attributes, dynatrace-api\
**Created:** [November 25, 2021, 9:05am UTC](https://community.dynatrace.com/t/how-to-create-custom-error-rule-using-request-attribute-value-from-api/33377 "2021-11-25T09:05:39Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![ChadTurner](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/chadturner/32/161_2.png) [@ChadTurner](https://community.dynatrace.com/u/ChadTurner)\
**Post date:** [December 8, 2021, 2:42am UTC](https://community.dynatrace.com/t/how-to-create-custom-error-rule-using-request-attribute-value-from-api/33377/2 "2021-12-08T02:42:53Z")

</div>

Thats a really good question. If you can use the API you might still end up hitting a limitation where you need to provide the entity ID, but granted that would cut down the workload.

You can create a global rule as well:

 ![ChadTurner_0-1638930705160.png](https://global.discourse-cdn.com/dynatrace/original/2X/1/1f0a58fb26c1337147aed4a82bd4b26506ce7f7f.png)

Ill see if Dynatrace is aware of a way to leverage the API for this

---

_[View the full topic](https://community.dynatrace.com/t/how-to-create-custom-error-rule-using-request-attribute-value-from-api/33377)._
