# Dynatrace API to fetch configured(custom) quotas / limits for HUs, DDUs and other license info

**URL:** <https://community.dynatrace.com/t/dynatrace-api-to-fetch-configured-custom-quotas-limits-for-hus-ddus-and-other-license-info/42161>\
**Category:** Open Q&A\
**Tags:** licensing, dynatrace-api\
**Created:** [October 18, 2023, 3:03pm UTC](https://community.dynatrace.com/t/dynatrace-api-to-fetch-configured-custom-quotas-limits-for-hus-ddus-and-other-license-info/42161 "2023-10-18T15:03:38Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![lakshay345](https://avatars.discourse-cdn.com/v4/letter/l/6a8cbe/32.png) [@lakshay345](https://community.dynatrace.com/u/lakshay345)\
**Post date:** [October 18, 2023, 3:03pm UTC](https://community.dynatrace.com/t/dynatrace-api-to-fetch-configured-custom-quotas-limits-for-hus-ddus-and-other-license-info/42161/1 "2023-10-18T15:03:38Z")

</div>

Hello everyone,

Is there any dynatrace API which we can utilise to fetch the configured quotas / limits (which we have configured on our own ) for Host units, DDUs and other license info?  
So, what we see in the dynatrace UI (called as max limits / quotas), I NEED TO FETCH THAT INFO USING THE API and then calculate how much DDUs/HUs quota is left in my dynatrace environment.&nbsp; (after subtracting it from the consumed DDUs/HUs)

Thank you in advance !!

---

<div class="post-metadata">

**Author:** ![radek\_jasinski](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/radek_jasinski/32/10432_2.png) [@radek\_jasinski](https://community.dynatrace.com/u/radek_jasinski)\
**Post date:** [October 18, 2023, 9:25pm UTC](https://community.dynatrace.com/t/dynatrace-api-to-fetch-configured-custom-quotas-limits-for-hus-ddus-and-other-license-info/42161/2 "2023-10-18T21:25:30Z")

</div>

Hi&nbsp;[@lakshay345](https://community.dynatrace.com/user/67916)

I&nbsp;think this is what you are looking for

> **[Export license data for 1 hour](https://docs.dynatrace.com/managed/dynatrace-api/cluster-api/cluster-api-v2/export-license-data/get-export-license-data-hour)**
>
> Learn how to export aggregated hourly license usage as a ZIP file for an hour.

Radek

---

<div class="post-metadata">

**Author:** ![lakshay345](https://avatars.discourse-cdn.com/v4/letter/l/6a8cbe/32.png) [@lakshay345](https://community.dynatrace.com/u/lakshay345)\
**Post date:** [October 19, 2023, 7:15am UTC](https://community.dynatrace.com/t/dynatrace-api-to-fetch-configured-custom-quotas-limits-for-hus-ddus-and-other-license-info/42161/3 "2023-10-19T07:15:44Z")

</div>

Hi&nbsp;[@radek\_jasinski](https://community.dynatrace.com/user/16832)&nbsp;  
I am NOT looking for license consumption data. This I already know. 🙂  
I am looking for an api which could fetch me the configured quotas / (max) limits for license consumption / HU / DDU.  
Thanks

---

<div class="post-metadata">

**Author:** ![radek\_jasinski](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/radek_jasinski/32/10432_2.png) [@radek\_jasinski](https://community.dynatrace.com/u/radek_jasinski)\
**Post date:** [October 19, 2023, 7:30am UTC](https://community.dynatrace.com/t/dynatrace-api-to-fetch-configured-custom-quotas-limits-for-hus-ddus-and-other-license-info/42161/4 "2023-10-19T07:30:20Z")

</div>

Hi,

I would use the settings API for this, as each configuration variable is reflected in a parameter object: [Settings API — Dynatrace Docs](https://www.dynatrace.com/support/help/shortlink/api-v2-settings)

Here is a more comprehensive description:

> **[Dynatrace settings framework](https://docs.dynatrace.com/docs/manage/settings/settings-20)**
>
> Introduction to the Settings 2.0 framework

However, these settings only apply to a specific environment and not to the entire Dynatrace Managed (or SaaS) cluster. If you want to get the information from the CMC, you have to use the cluster API (I don’t know if such detailed license consumption limit settings are available).

> **[Cluster API v2](https://docs.dynatrace.com/managed/dynatrace-api/cluster-api/cluster-api-v2)**
>
> Find out about managing environments, network zones, Synthetic locations, nodes, and tokens in Dynatrace Managed using the Cluster API v2.

Radek

---

<div class="post-metadata">

**Author:** ![lakshay345](https://avatars.discourse-cdn.com/v4/letter/l/6a8cbe/32.png) [@lakshay345](https://community.dynatrace.com/u/lakshay345)\
**Post date:** [October 19, 2023, 12:05pm UTC](https://community.dynatrace.com/t/dynatrace-api-to-fetch-configured-custom-quotas-limits-for-hus-ddus-and-other-license-info/42161/5 "2023-10-19T12:05:46Z")

</div>

Thanks&nbsp;[@radek\_jasinski](https://community.dynatrace.com/user/16832)&nbsp;.  
I used this api&nbsp;[Cluster API v2 — Dynatrace Managed Docs](https://www.dynatrace.com/support/help/managed-cluster/cluster-api/cluster-api-v2)&nbsp;and is able to fetch the quotas.  
However, the values are coming different from the ones which I see the dynatrace console. For some environments, the values are correct (HU/DDU and other values) & for some environments, the values are wrong.  
This is an unexpected bahavior.&nbsp;  
I don’t understand which one is correct?  
the api call or the dynatrace console

---

<div class="post-metadata">

**Author:** ![radek\_jasinski](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/radek_jasinski/32/10432_2.png) [@radek\_jasinski](https://community.dynatrace.com/u/radek_jasinski)\
**Post date:** [October 19, 2023, 12:11pm UTC](https://community.dynatrace.com/t/dynatrace-api-to-fetch-configured-custom-quotas-limits-for-hus-ddus-and-other-license-info/42161/6 "2023-10-19T12:11:51Z")

</div>

In my experience, the data in the DT GUI can refresh with a slight delay.  
Can you show an example? Perhaps you have chosen a different data range:)

---

<div class="post-metadata">

**Author:** ![lakshay345](https://avatars.discourse-cdn.com/v4/letter/l/6a8cbe/32.png) [@lakshay345](https://community.dynatrace.com/u/lakshay345)\
**Post date:** [October 19, 2023, 1:38pm UTC](https://community.dynatrace.com/t/dynatrace-api-to-fetch-configured-custom-quotas-limits-for-hus-ddus-and-other-license-info/42161/7 "2023-10-19T13:38:12Z")

</div>

Yes, I am now able to see the correct data. It was an issue from my end.  
Thank you so much for your help 🙂

---

<div class="post-metadata">

**Author:** ![radek\_jasinski](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/radek_jasinski/32/10432_2.png) [@radek\_jasinski](https://community.dynatrace.com/u/radek_jasinski)\
**Post date:** [October 19, 2023, 1:39pm UTC](https://community.dynatrace.com/t/dynatrace-api-to-fetch-configured-custom-quotas-limits-for-hus-ddus-and-other-license-info/42161/8 "2023-10-19T13:39:55Z")

</div>

Great 👍
