# POST call failing in zoom-apps

**URL:** <https://devforum.zoom.us/t/post-call-failing-in-zoom-apps/76609>\
**Category:** Zoom Apps\
**Created:** [September 28, 2022, 6:21am UTC](https://devforum.zoom.us/t/post-call-failing-in-zoom-apps/76609 "2022-09-28T06:21:08Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![sanket.benade](https://avatars.discourse-cdn.com/v4/letter/s/c89c15/32.png) [@sanket.benade](https://devforum.zoom.us/u/sanket.benade)\
**Post date:** [September 28, 2022, 6:21am UTC](https://devforum.zoom.us/t/post-call-failing-in-zoom-apps/76609/1 "2022-09-28T06:21:08Z")

</div>

I am trying to build a Zoom-Apps application where I want to integrate POST api call.  
But it is failing.

---

<div class="post-metadata">

**Author:** ![brandtley.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/brandtley.zoom/32/40274_2.png) [@brandtley.zoom](https://devforum.zoom.us/u/brandtley.zoom)\
**Post date:** [September 30, 2022, 6:08pm UTC](https://devforum.zoom.us/t/post-call-failing-in-zoom-apps/76609/2 "2022-09-30T18:08:01Z")

</div>

Hello Sanket,

Can you provide more context around what API endpoint you are trying to POST?

A code snippet of the API call and the console error or response message would help diagnose the issue.

---

<div class="post-metadata">

**Author:** ![sanket.benade](https://avatars.discourse-cdn.com/v4/letter/s/c89c15/32.png) [@sanket.benade](https://devforum.zoom.us/u/sanket.benade)\
**Post date:** [October 3, 2022, 6:44am UTC](https://devforum.zoom.us/t/post-call-failing-in-zoom-apps/76609/4 "2022-10-03T06:44:31Z")

</div>

Hi @brandtley.zoom ,

```auto
axios.get('https://jsonplaceholder.typicode.com/posts/1')
      .then((response) => {
        console.log(response)
        setField(response.data.id)
      }).catch((err) => {
        console.log(err)
        setError(err. Message)
      })

```

Even this simple jsonPlaceholder api is failing.

---

<div class="post-metadata">

**Author:** ![brandtley.zoom](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/brandtley.zoom/32/40274_2.png) [@brandtley.zoom](https://devforum.zoom.us/u/brandtley.zoom)\
**Post date:** [October 4, 2022, 11:58pm UTC](https://devforum.zoom.us/t/post-call-failing-in-zoom-apps/76609/5 "2022-10-04T23:58:06Z")

</div>

Hello Sanket,

I tested the snippet you provided, in addition to a similar service for API testing:

```javascript
fetch('https://reqres.in/api/users')
  .then((response) => response.json())
  .then((json) => console.log(json));

```

In testing this I discovered a few possible issues:

- Content Security Policy violations: specifically relating to `connect-src` definitions
- Missing CORS headers for the given target domain

In testing my CSP and CORS settings for my local app, localhost was able to query the resources just fine, however my ngrok instance was not.

So in this particular case, I believe these services may be blocking ngrok requests, and possibly other local proxies to prevent spammers from abusing their services.

* * *

Testing another proxy tool called `localtunnel` ([localtunnel - npm](https://www.npmjs.com/package/localtunnel)) and updating my app config and local app settings did work for me.

Give this a shot and see if that helps.

---

<div class="post-metadata">

**Author:** ![sanket.benade](https://avatars.discourse-cdn.com/v4/letter/s/c89c15/32.png) [@sanket.benade](https://devforum.zoom.us/u/sanket.benade)\
**Post date:** [October 6, 2022, 3:48am UTC](https://devforum.zoom.us/t/post-call-failing-in-zoom-apps/76609/6 "2022-10-06T03:48:42Z")

</div>

Thank you Brandtley,  
I will check for the solution your solution.

---

<div class="post-metadata">

**Author:** ![sanket.benade](https://avatars.discourse-cdn.com/v4/letter/s/c89c15/32.png) [@sanket.benade](https://devforum.zoom.us/u/sanket.benade)\
**Post date:** [October 6, 2022, 4:50am UTC](https://devforum.zoom.us/t/post-call-failing-in-zoom-apps/76609/7 "2022-10-06T04:50:07Z")

</div>

> [@brandtley.zoom](#):
>
> Content Security Policy violations: specifically relating to `connect-src` definitions

I am facing these issues on zoom desktop client only.

---

<div class="post-metadata">

**Author:** ![sanket.benade](https://avatars.discourse-cdn.com/v4/letter/s/c89c15/32.png) [@sanket.benade](https://devforum.zoom.us/u/sanket.benade)\
**Post date:** [October 6, 2022, 10:03am UTC](https://devforum.zoom.us/t/post-call-failing-in-zoom-apps/76609/8 "2022-10-06T10:03:40Z")

</div>

I tried adding specified CORS domain configs & disabled CSP but still it’s getting failed in Desktop Client.

---

<div class="post-metadata">

**Author:** ![13javig](https://sea2.discourse-cdn.com/flex016/user_avatar/devforum.zoom.us/13javig/32/52235_2.png) [@13javig](https://devforum.zoom.us/u/13javig)\
**Post date:** [September 20, 2023, 5:55pm UTC](https://devforum.zoom.us/t/post-call-failing-in-zoom-apps/76609/9 "2023-09-20T17:55:16Z")

</div>

Hi! Did you find the solution? I’m trying to make an axios request to my backend and I get an Axios Error, with no information. I used the cors package as middleware in the backend aswell.
