React native expo app can't call backend in fast Api but calling any other API correctly

237 Views Asked by At

I am working on a mobile app project which is built in React Native and the backend is made in fast API. The problem is that react native has to call the fast Api backend to work a special functionality. Fast API is hosted in deta space. The app was working fine before the deta upgraded to newer cloud infrastructure. Now if I write URL of any other API it works fine, but not for my fast API. The fast API on the other hand is working fine in postman as well as in the deta space. But still unable to be called from within the react native expo app. It shows an error saying: Network request failed whenever the API is called from within the app. I am unable to figure out whether I should make changes on deta or in fast API to allow calls from within react native or should I do some other thing to call fast API, because other APIs are working fine only the specific API is not being called and shows network error

0

There are 0 best solutions below