# Is HTTP API call allowed?

**URL:** <https://community.dynatrace.com/t/is-http-api-call-allowed/37708>\
**Category:** Developer Q&A Forum\
**Tags:** data-privacy-and-product-security, custom-app, app-functions\
**Created:** [December 15, 2022, 7:10am UTC](https://community.dynatrace.com/t/is-http-api-call-allowed/37708 "2022-12-15T07:10:05Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![s\_eilmsteiner](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/s_eilmsteiner/32/32799_2.png) [@s\_eilmsteiner](https://community.dynatrace.com/u/s_eilmsteiner)\
**Post date:** [December 15, 2022, 7:10am UTC](https://community.dynatrace.com/t/is-http-api-call-allowed/37708/1 "2022-12-15T07:10:05Z")

</div>

Is it allows to call an API with HTTP and not HTTPS within an app function? My function works locally, but not when I deploy it. The URL is registered in the allow list of the outbound connection.

---

<div class="post-metadata">

**Author:** ![dirk\_wall](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/dirk_wall/32/4849_2.png) [@dirk\_wall](https://community.dynatrace.com/u/dirk_wall)\
**Post date:** [December 15, 2022, 7:30am UTC](https://community.dynatrace.com/t/is-http-api-call-allowed/37708/2 "2022-12-15T07:30:24Z")

</div>

Hi Simon,

I’ve just tried it out myself in Notebooks to confirm. If the domain matches an entry in the allowed list of outbound connections, also HTTP connections work. However, it’s not recommended to do that, but I assume you know.

Cheers,  
Dirk

 ![2022-12-15 08_27_22-Dynatrace - Notebooks und 6 weitere Seiten - Geschäftlich – Microsoft​ Edge.png](https://global.discourse-cdn.com/dynatrace/original/3X/1/2/1288e423257a7cd8f5e411051f6afccae6839326.png)  
 ![2022-12-15 08_29_21-Clipboard.png](https://global.discourse-cdn.com/dynatrace/original/2X/9/9a84c756cea0224b3e2db3abc16efb2d9969371e.png)

---

<div class="post-metadata">

**Author:** ![s\_eilmsteiner](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/s_eilmsteiner/32/32799_2.png) [@s\_eilmsteiner](https://community.dynatrace.com/u/s_eilmsteiner)\
**Post date:** [December 15, 2022, 9:17am UTC](https://community.dynatrace.com/t/is-http-api-call-allowed/37708/3 "2022-12-15T09:17:42Z")

</div>

I tried the same as you did, but I get the following error:  
When I copy/paste the same url in the browser the call works and returns the correct result.

 ![simon_eilmstei2_0-1671095762900.png](https://global.discourse-cdn.com/dynatrace/original/2X/1/1b21472fc1854bc29ab127b3c54bbd1eb339d12f.png)

---

<div class="post-metadata">

**Author:** ![dirk\_wall](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/dirk_wall/32/4849_2.png) [@dirk\_wall](https://community.dynatrace.com/u/dirk_wall)\
**Post date:** [December 15, 2022, 9:31am UTC](https://community.dynatrace.com/t/is-http-api-call-allowed/37708/4 "2022-12-15T09:31:50Z")

</div>

Could you please double check if you’ve entered the endpoint in the right list? The error message in your screenshot talks about “edge requests” which lets me believe you’ve entered the URL in the wrong list.

---

<div class="post-metadata">

**Author:** ![michal\_zawislak](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/michal_zawislak/32/13613_2.png) [@michal\_zawislak](https://community.dynatrace.com/u/michal_zawislak)\
**Post date:** [December 15, 2022, 9:43am UTC](https://community.dynatrace.com/t/is-http-api-call-allowed/37708/5 "2022-12-15T09:43:58Z")

</div>

If the URL you’re using is located in a private network, you should check if the correct host-to-locations mappings are defined in the settings for EdgeConnect.

You can find it under _Settings → Preferences → Data Gateway Locations._

---

<div class="post-metadata">

**Author:** ![s\_eilmsteiner](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/s_eilmsteiner/32/32799_2.png) [@s\_eilmsteiner](https://community.dynatrace.com/u/s_eilmsteiner)\
**Post date:** [December 15, 2022, 11:22am UTC](https://community.dynatrace.com/t/is-http-api-call-allowed/37708/6 "2022-12-15T11:22:53Z")

</div>

Thanks that solved it for notebooks.

But in the app I still get an error. Do I need to set something in my app?

---

<div class="post-metadata">

**Author:** ![christoph\_b](https://avatars.discourse-cdn.com/v4/letter/c/5f8ce5/32.png) [@christoph\_b](https://community.dynatrace.com/u/christoph_b)\
**Post date:** [December 15, 2022, 12:28pm UTC](https://community.dynatrace.com/t/is-http-api-call-allowed/37708/7 "2022-12-15T12:28:05Z")

</div>

It turned out that this was a misconfiguration where the error message was not helpful at all to resolve the issue. I will create the necessary issues to improve the error message.

---

<div class="post-metadata">

**Author:** ![s\_eilmsteiner](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/s_eilmsteiner/32/32799_2.png) [@s\_eilmsteiner](https://community.dynatrace.com/u/s_eilmsteiner)\
**Post date:** [December 15, 2022, 2:50pm UTC](https://community.dynatrace.com/t/is-http-api-call-allowed/37708/8 "2022-12-15T14:50:15Z")

</div>

Scope:

```auto
edge-executor:http-requests:execute

```

was needed.
